web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Large AX Database Log File

(0) ShareShare
ReportReport
Posted on by 2,259

Hello!

we had an AX database with the size of 27 GB.

but the log file is growing to around 1.5 TB, shrinking the log file will make its size around 5 GB

but again within 2 day it back to around 1.4 TB.

we have 5 retail store and normal transactions.

is there is some way to make the growth of the log file less.

SQL Server 2016 SP2.

AX 2012 R3 CU 12.

Thanks

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Community Member Profile Picture
    on at
  • Suggested answer
    Hassan_rulz Profile Picture
    3,801 on at

    Hi Wasim,

    Can you please tell me about recovery model setting on AX DB?

    Regards,

    Hassan

  • Suggested answer
    guk1964 Profile Picture
    10,888 on at

    I assume you mean the SQL transaction log - in general its bad practise to shrink this other than for a special situation. If it needs to be that size then as you have found it will quickly grow back. Never schedule regular DBCC SHRINKFILE tasks as a means of controlling the size of the log -  it can cause terrible log fragmentation.

    You can however back it up more frequently e.g. every 30 minutes instead of daily, in which case any individual log will be much smaller. 

    Truncation does not affect the physical size of the log; it will still take up the same physical space on the drive. Truncation is the act of marking VLFs in the log file as available for reuse, in the recording of subsequent transactions. The only correct way to force log truncation is to temporarily switch the database to 
    SIMPLE recovery.

    You might also look at compression for both your log and database.

    All databases where log backups are required should be operating in the FULL recovery model,. However, a database operating in FULL recovery can
    be switched temporarily to the BULK LOGGED model in order to maximize performance, and minimize the growth of the transaction log, during bulk operations, such as bulk data loads or certain index maintenance operations. When a database is operating in BULK LOGGED model, such operations are only minimally logged, and so require less space in  the log file. BULK LOGGED has implications that make it unsuitable for long-term use in a database where point-in-time restore is required, since it is not possible to restore a database to a point in time within a log file that contains minimally logged operations.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 2

#2
Henrik Nordlöf Profile Picture

Henrik Nordlöf 2 User Group Leader

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans