Share via


Log files not truncating with Windows Server Backup

Question

Tuesday, September 9, 2014 3:41 AM

Hi all

I'm in the middle of an Exchange 2013 deployment (CU5) on Windows Server 2012 R2.  Currently a two-node DAG, but will eventually be 3-node.

The DAG is working fine and the passive copy is healthy.

I'm backing up the databases with Windows Server Backup.  The backups complete successfully, but the transaction log files are not truncated. 

Running "Get-MailboxDatabase DB1 -status | fl *backup*" shows the correct date/time stamp under LastFullBackup.  The backup is healthy as I am successfully able to restore to the Recovery Database.

Things I've tried so far to clear down the transaction logs:

  1. Backing up from active and passive DAG node.  Same result either way.
  2. Setting the EnableVSSWriter registry value to 1 (and 0) and then rebooting.  I've read that this value is not relevant for Exchange 2013 anyway.
  3. Changed the backup options to remove the System State.  Someone indicated this helped them (no idea why).
  4. Enabling circular logging, letting the logs clear down, disabling circular logging and then re-running the backup job.
  5. Cranking up the event log level for "MS Exchange Repl\Exchange VSS Writer" to "Expert".  The only additional information this revealed was an ESE event 225 indicating "No log files can be truncated".
  6. Several reboots of both DAG nodes.
  7. Swearing a lot (didn't help, but it made me feel better).

Any thoughts on what next to try or how to get further information?  I have no hair left to pull out.

Thanks

Tony www.activedir.org Blog: www.open-a-socket.com

All replies (6)

Wednesday, September 10, 2014 2:35 AM ✅Answered

Ok, so it looks like the problem was that there was not sufficient transaction log churn to exceed the threshold at which truncation is triggered when a passive copy is involved.  When I moved a large mailbox to the E2013 mailbox database (and consequently generated a large number of transaction logs), Windows Server Backup cleared the logs as expected.

The checkpoint depth for passive copies in E2013 is 100MB.  A good description of this here:



http://thoughtsofanidlemind.com/2013/03/15/exchange-2013-log-truncation/

Tony www.activedir.org Blog: www.open-a-socket.com


Tuesday, September 9, 2014 3:53 AM

Hi Tony 

Please ensure that we are not taking backup with "VSS Copy Backup" option  as copy backup never purges the log files.
We can select VSS Full Backup option from the advanced settings.

If it is happening for one storage group we can try below steps 
Dismount the affected storage groups's mailbox store.
Move all the log files manually including last log and check point file
Mount the store.
Start the backup and see the results.

Good Luck Tony :)

Remember to mark as helpful if you find my contribution useful or as an answer if it does answer your question.That will encourage me - and others - to take time out to help you Check out my latest blog posts on http://exchangequery.com


Tuesday, September 9, 2014 4:03 AM

Thanks for the response Sathish.

Definitely not "VSS Copy Backup" option.  As mentioned, the mailbox database status shows the LastFullBackup with the date/time of the last backup.

Also, no storage groups (this is Exchange 2013). :-)

Tony www.activedir.org Blog: www.open-a-socket.com


Tuesday, September 9, 2014 12:47 PM

They're not 'orphaned' logs are they? Once they've missed their deletion, they will never be deleted, even by a successful future backup.

OWA For SmartPhone


Tuesday, September 9, 2014 10:46 PM

Hi Lee

No, not orphaned. 

I can reproduce the problem as follows:

  1. Remove the passive database copy.
  2. Dismount the active (now only remaining) database copy.
  3. Clear the transaction logs and checkpoint file from the folders on the active copy.
  4. Mount the database.
  5. Generate some transaction logs (via mailbox move).
  6. Run a backup.  This completes successfully and clears transaction logs.
  7. Add the passive copy.
  8. Confirm passive copy healthy (db + index).
  9. Generate some transaction logs (via mailbox move).
  10. Run a backup.  This completes successfully, but the transaction logs do not truncate.

So, the problem appears to be related in some way to the passive copy.  There is nothing wrong with the passive copy as far as I can tell.  It reports as being healthy and I can switchover to it.

It would be really good to find out why the logs are not truncating. Is there really no way to do this?

Tony www.activedir.org Blog: www.open-a-socket.com


Thursday, January 23, 2020 8:36 PM

Wow I just wasted a lot of time on this non issue. Once I had over 100MB of logs it truncated successfully.