In this article in the series on Exchange Server 2016 backup and recovery we’ll look at backing up Exchange Server 2016 using Windows Server Backup.

For this scenario I’m using a single Exchange 2016 Mailbox server that is not a member of a database availability group. The server hosts a single mailbox database, with the database file on D: drive and the transaction logs on E: drive. An additional volume has been created for the server to host the backup files.

[PS] C:\>Get-ExchangeServer

Name                Site                 ServerRole  Edition     AdminDisplayVersion
----                ----                 ----------  -------     -------------------
EXSERVER            exchange2016demo.... Mailbox,... Standard... Version 15.1 (Bu...

[PS] C:\>Get-MailboxDatabase | Select Name,EdbFilePath,LogFolderPath


Name          : DB01
EdbFilePath   : D:DB01DB01.edb
LogFolderPath : E:DB01

The Windows Server Backup feature is not installed by default so the first step we need to perform is to install it on the server.

PS C:\> Install-WindowsFeature Windows-Server-Backup

Success Restart Needed Exit Code      Feature Result
------- -------------- ---------      --------------
True    No             Success        {Windows Server Backup}

Now we can launch Windows Server Backup and configure the scheduled backup job.

exchange-server-2016-backup-01

After launching Windows Server Backup select Local Backup from the left side and then click Backup Schedule in the Actions pane on the right side.

exchange-server-2016-backup-02

When the Backup Schedule Wizard launches you have the choice to create a full server backup, or a custom backup.

exchange-server-2016-backup-03

Creating a Full Server Backup of Exchange Server 2016

Select Full server from the backup configuration choice and then click Next. Choose the backup time and frequency you need for your environment.

exchange-server-2016-backup-04

Choose your backup destination. I’m backing up to a hard disk that is dedicated for Windows Server Backup to use.

exchange-server-2016-backup-05

Click Show All Available Disks and add the volume you’re using for backups, then select it before you continue to the next step.

exchange-server-2016-backup-06

At the confirmation screen verify that all your selections are correct. Note that VSS Full Backup is automatically chosen as the backup type, which is correct for this scenario.

exchange-server-2016-backup-07

Click Finish to create the backup job. It will run at the next scheduled time.

Creating a Custom Backup of Exchange Server 2016

In some situations you may want to create a custom backup selection for Windows Server Backup to use when backing up Exchange Server 2016. I recommend that you only do this if you understand what you’re excluding from the backup.

At the beginning of the Backup Schedule Wizard choose Custom instead of Full server. Add the items you want to back up. If you’re backing up Exchange databases you must select the entire volume, not just the folders containing the database and transaction log files.

exchange-server-2016-backup-08

After adding your selections click the Advanced Settings button.

exchange-server-2016-backup-09

On the VSS Settings tab select VSS full backup. If you do not make this change the backup will not truncate the transaction logs for the databases.

exchange-server-2016-backup-10

Set the scheduled time and frequency for your backup job to run.

exchange-server-2016-backup-04

Set the destination to store the backups. I’m using a dedicated hard disk for this demonstration.

exchange-server-2016-backup-05

Click Show Available Disks and add the volume that you will be backing up to, and then select it for this backup job.

exchange-server-2016-backup-06

Confirm your selections and that you have chosen VSS Full Backup, then click Finish to create the scheduled backup job.

exchange-server-2016-backup-11

Monitoring Backup Results for Exchange Server 2016

When you’re backing up Exchange Server 2016 there’s two places to look when checking the results of your backup jobs:

  • The backup software’s logs or reports
  • The Exchange server’s database backup timestamps

Since I’ve used Windows Server Backup in this example I can check the status of the last backup job in the console and confirm that it ran successfully.

exchange-server-2016-backup-12

However I don’t recommend that you rely solely on the backup software to confirm that your backups are running successfully. You should also check it on the Exchange databases themselves.

To check the Exchange server’s database backup timestamps use the Get-MailboxDatabase cmdlet.

[PS] C:\>Get-MailboxDatabase -Status | Select Name,*backup*


Name                           : DB01
BackupInProgress               : False
SnapshotLastFullBackup         : True
SnapshotLastIncrementalBackup  :
SnapshotLastDifferentialBackup :
SnapshotLastCopyBackup         :
LastFullBackup                 : 28/10/2015 4:24:34 PM
LastIncrementalBackup          :
LastDifferentialBackup         :
LastCopyBackup                 :
RetainDeletedItemsUntilBackup  : False

For an automated, daily check of your Exchange Server 2016 backups I recommend using my Get-DailyBackupAlerts.ps1 script.

About the Author

Paul Cunningham

Paul is a former Microsoft MVP for Office Apps and Services. He works as a consultant, writer, and trainer specializing in Office 365 and Exchange Server. Paul no longer writes for Practical365.com.

Comments

  1. Penny Wendt

    Im installing Exchange backup to fix a space issue with transaction logging. However it seems to be stuck at 24% (over 30 minutes now) which makes me suspect its stuck. Im concerned its diskspace causing it. Can you tell me how much space I need to recoup before I can install the backup software? OR is there some other reason I would be stuck you can think of?

  2. Robert Se

    Hi I did exactly what was stated but it came back with the below error

    Writer Failures
    Writer Id: {76FE1AC4-15F7-4BCD-987E-8E1ACB462FB7}
    Instance Id: {5F35F80F-B590-4A56-BEB7-2A9BA7C2E631}
    Writer Name: Microsoft Exchange Writer
    Writer State: 5
    Failure Result: 800423F3
    Application Message: (null)
    Logical Path: Microsoft Exchange Server\Microsoft Information Store\xxxxxxxxxxxxxxxx
    Component Result: 800423F3
    Component Message: (null)
    File Spec: M:\Program Files\Microsoft\Exchange Server\V15\Mailbox\Mailbox Database 1801403271\Mailbox Database 1801403271.edb Recursive: 0
    Logical Path: Microsoft Exchange Server\Microsoft Information Store\xxxxxxx
    ————————–*

  3. Anthony

    Hi Paul,

    I have set up a DAG in Exchange 2016. Server 1 has copied to Server 2 and appears healthy. When i run an Exchange aware backup on Server 1, the logs for the active copy on Server 1 truncate but the logs for the passive copy of this DB on Server 2 are not purged.

    Should they be or do i need to run an Exchange aware backup against the passive copy of the DB on Server 2?

    Thanks

  4. John

    Great article. I see that you only backup database and logs. What is the best recommended practice for Exchange servers’s backup?. For an example, we have servers in DAG and something went wrong with the servers when we apply CU and windows updates, in this case ,DBs and logs are good, only issue with OS or Exchange programs files.

  5. Fried Bacon

    Thanks for your articles man, helped me out a lot in managing my exchange server. Self thought here, really need all the help I can get

  6. Peter Atkin

    Great Article, I have come across an issue with restoring exchange that you might be able to help with?

    1- DC server Windows 2012R2
    2- Exchange 2016 cu6 installed onto Windows 2012R2 joined to domain but not a DC
    — 3 drives (not partitions) OS, data, backup, C: D: and E: respectively
    —OS drive has all the normal stuff +exchange, data Drive has the Exchange databases, and backup drive is for the backups.
    3- OOS installed onto Windows 2012R2 joined to domain but not a DC
    – All on separate vm machines

    Backup seems to work fine but when I get to restore I get an error:

    1. When run directly a restore via shadow copies: A volume that contains the operating system files or resides on a cluster shared disk cannot be reverted?
    2. When running via the backup app in restore mode, I can only restore the OS to another drive? not the current OS drive.

    I sure there is a reason, but no idea what I am doing wrong?

    Possible for any advice in this matter.

  7. Martin

    I got the same issue like other people with Windows Backup not truncating the logs. I have selected the volumes during backup schedule and I selected VSS Full Backup to truncate the logs. The backup is successfull and also this command: Get-MailboxDatabase -Server -Status | fl Name,*FullBackup
    shows a date and timestamp for “LastFullBackup” for all databases. However, all the logs are still there.

    Any ideas?

  8. Shimon Adimor

    Hi Paul,
    So for a few months, my backups ran fine and the transaction logs were truncating. I usually run the backup of one Exchange server on a Friday night and the other on a Saturday night. I backup the two volumes, and specify VSS Full backup.
    This worked fine after I added local drives on each server to store the backup.

    Not sure what happened, but the last two backups did not truncate the transaction log, and I get the following messages in the event viewer:
    Event ID 2048, Error:
    Microsoft Exchange VSS Writer instance 394ad043-848a-4b34-b788-294f557a1880 failed with error 8007064A. No log files were truncated for database ‘MBDB03’.
    Event ID 2046, Info:
    The Microsoft Exchange Replication service VSS Writer instance 394ad043-848a-4b34-b788-294f557a1880 has successfully completed the backup of database ‘MBDB03’.

    Database log truncation has been requested for this database. Log truncation will occur on the active copy after the next log generation is created. Log truncation will occur automatically on the passive copies after that log file is copied.
    Event ID 2034, Error:
    The Microsoft Exchange Replication service VSS Writer (Instance 394ad043-848a-4b34-b788-294f557a1880) failed with error 8007064A when processing the backup completion event.
    Event ID 16389, SPP Error:
    Writer Microsoft Exchange Writer experienced retryable error during shadow copy creation. Retrying… More info: .
    Microsoft Exchange Writer

    The writer experienced a transient error. If the backup process is retried, the error may not reoccur. (0x800423F3)

    I hope there is some fix for this behavior…

  9. John Tseung

    Hi Paul,
    Any advise for full backup failed with exchange 2016 + server 2016?

    Writer name: ‘Microsoft Exchange Writer’
    Writer Id: {76fe1ac4-15f7-4bcd-987e-8e1acb462fb7}
    Writer Instance Id: {411d9000-c4b6-45e2-81dd-a96e8c331da5}
    State: [1] Stable
    Last error: Retryable error

    Restart Microsoft exchange replication and reboot doesn’t help.

    1. Aleks Stolevski

      Hi John,

      Were you able to resolve this? I’m having the same issue 🙁

      Thanks!
      Aleks

  10. Donnei Tsai

    Greate Article!!

    One Question. Can we use WSB to Backup Exchange 2016, and performance setting use Faster backup performance?

    Thanks

  11. Tariq Nabi

    Hi Paul
    Thanks for the guide.
    On a Microsoft Exchange 2016 course I attended, the trainer suggested, the whole point for DAG was to not have a need to backup the databases just backup the server. Once you have multiple DAG servers placed in several sites, the DAG copies are your backups. Then it would be a matter of implementing a good retention policy.
    What are your thoughts on this idea?

    1. Avatar photo

      That sounds like a slightly distorted description of what Microsoft refers to as Native Data Protection. Brian Reid and I discussed NDP on a podcast here (https://www.practical365.com/podcasts/podcast-episode-24/).

      Yes, it’s possible to go backup-less with Exchange, but there’s more to it than just deploying a DAG. A lot of organizations lack the technical and operational maturity to rely on Native Data Protection, but it is always worth considering.

      1. Tariq Nabi

        That was a great podcast, really helped.
        Thanks.

  12. Prakash

    Hi Paul,

    Thanks for the excellent guide.

    We have two exchange server 2013 in two different sites. We have DAG enabled and have two active and two passive copies on each server.

    For Windows Server Backup, I have added a new local disk with 5TB storage on both servers. The first backup was successful with about 2TB in size and it truncated all the logs. My question is:

    1) Is it okay to run Windows Server Backup simultaneously on both the servers?
    2) As I only have 5TB of storage limit, what will happen to the third backup? Will it fail because of less storage or will it remove/overwrite the first backup to make space for the third one?

    Thanks!

  13. JohnP

    This worked out great. I am doing a full to a dedicated drive. How do I offsite a backup? Do I run a separate backup or can can I get at the ones on the dedicated drive somehow?

  14. Ryan

    Hi Paul

    Great article! I do have one question:

    Suppose an Exchange server has multiple databases each in their own volumes – is it possible to backup the databases in two separate backup jobs that take place at staggered times, or is it required for all databases to be backed up at the same time? Many thanks

      1. Ryan

        Ok, perfect. They are on separate volumes and I just wasn’t sure if Exchange would complain about having them backed up at different times. Based on your response, it sounds like it’s not a problem to do it that way.

        Thank you!

  15. Erika K

    Hi,

    I’m the same problem of Shimon Adimor.
    In my case, the database is not par of DAG.

    I hope the help.

  16. Rommel

    Hi paul,

    I hope you do great.

    I have a question.

    1. Its okay to create a backup (full backup) in a remote shared location?

    2. I have 3 dag server and all dag servers was backup every day for full server backup. It is redundant? Or it is ok?

    Hope you reply.

    Thank you and best regards,

      1. Rommel

        Thank you so much paul.

        Have a great day

      2. Rommel Francisco

        Hi Paul,

        I was noticed that the backup type of 2 DAG Members show as Incremental, Although it is configured as Full Server Backup. The incremental backup type show in the database volume. Logs volume and other system was Full.

        I have you reply for my concern,

        Thank you

  17. Shimon Adimor

    Full server backup to a local volume on each DAG member, and still – logs are not truncating –
    not sure what to do next…

  18. Shimon Adimor

    It looks like on of the databases went into “mounting” state but a little while ago users were able to use email again…
    Not 100% sure what the cause was but I did find a few errors in the event viewer.

  19. Shimon Adimor

    Everyone says it’s not recommended to use circular logging, but the transaction logs keep growing and I don’t see a way to truncate them.
    I started a full server backup to a local volume on each server, and it’s taking forever, plus users can’t login to their email – something I didn’t expect to happen.
    Is this by design, or I’m doing something wrong ?
    I have two servers (DAG), each one has one active DB and one passive (copy of the other) as recommended by Microsoft, and I started the backup on both.

  20. Shimon Adimor

    Is it possible to set the transaction logs to be circular, and if yes – how, and what’s the disadvantage of doing that ?

  21. Shimon Adimor

    The problem is that both active and passive DBs reside on the same volume on each server, and for truncate to work it is a must to backup the whole volume…

  22. Shimon Adimor

    Circular logging is disabled
    I have two databases, each server has one active and one passive (copy of the other DB), and they are all healthy.
    I ran the backup on each server, and included both the active and passive DBs, maybe this is causing the problem ?
    should I backup only the active DB on each server for the truncation to run ?

  23. Shimon Adimor

    Yes

  24. Shimon Adimor

    In the event log it is showing Event 2230:
    A backup (components: registry, sysq, mapping, queue, storage) was completed successfully.

    But then I found the following errors:
    Event ID 2140 –
    The Microsoft Exchange Replication service VSS Writer encountered an exception in function Microsoft::Exchange::Cluster::ReplicaVssWriter::CReplicaVssWriterInterop::BackupCompleteTruncateLogsComponents. HResult -3. Exception Microsoft.Mapi.MapiExceptionCallFailed: MapiExceptionCallFailed: Unable execute Truncate on snapshot. (hr=0x80004005, ec=1295)
    Diagnostic context:
    … all the rest of the diagnostic details come here.

    And then
    Event ID 2034 –
    The Microsoft Exchange Replication service VSS Writer (Instance d2629a42-7565-4bda-88d2-150a6359ad57) failed with error FFFFFFFD when processing the backup completion event.

    Any idea how to fix this ?

  25. Shimon Adimor

    Yes I did – exactly as you instructed.

    1. Avatar photo

      It could be one of two things. Either you hadn’t waited long enough to allow ESE to complete its log truncation and update the database backup timestamp (so just look again, to see if it’s there now). Or, there’s a problem, in which case the event log should contain some info.

      If it’s a replicated database (ie in a DAG) then log truncation won’t occur if the log files haven’t successfully copied and replayed into other copies of that DB.

      1. Shimon Adimor

        Well – it seems like the Exchange Server is not aware of the backup.
        I ran the backup again on 7/3 and it completed successfully (according to the Windows server backup application) , but when I run Get-MailboxDatabase -Status | FL – all the backup fields are empty.
        Not really sure how to try and fix it.
        Tried to look into the EventViewer of the Exchnage, and although there were a few warnings and errors about the indexing – I didn’t see anything related to the transaction logs or the backup.
        Thanks !

  26. Shimon Adimor

    Hi Paul,
    I made a backup of two volumes, D: and E: where D: holds the database and E: holds the logs., and according to the backup console message it completed successfully.
    Still, when I run this command
    Get-MailboxDatabase -Status | Select Name,*backup*
    I don’t see the date of the last backup, plus the logs are not being truncated.
    Any idea why ?

  27. Oleg

    Couple of quick questions:

    1) Will this work in a DAG setup? If so, do I just take a backup from one servers?
    2) Will this flush the logs after a full backup? If not any other suggestions as far as flushing the logs?

  28. Edmunds

    Standard backup is as ugly as one can think of. Thank, you Microsoft!

    1) Intall, using command prompt, great, what a nice feature to copy from penguin guys !

    2) No archiving option (OK, never been for Exchange, but it’s 2015 and you did it for SQL Server, so why not here ?)

    3) only full backup, not incremental (log) backup, WTF ? You had this in Exchange 2003…..

    4) backup frequency – only once per day ? Are you crazy ? Will burn my HDDs in a month time.

    Great product, many thanks! How many analysts did work on the product requirements ? 😀

    1. Avatar photo

      You can install via the graphical server manager if you prefer to do it in a lot more steps. The PowerShell method is much faster.

      As for the rest of your complaints, it’s a free backup utility built in to the OS, and it’s compatible with Exchange. You get what you pay for. Want more features? Buy a third party product that has what you need.

  29. Shannon Duffy

    I have set this up and the logs don’t truncate for some reason. I checked that VSS Full backup was picked but for three days the backups complete successfully but the logs are not removed. What to try?

  30. Brian

    What is the recommended practice for backing up members of a DAG? Dont the backups fail on passive nodes? What if you have your stores split between DAG members so that each one always has an active and passive store?

    1. Brian

      Apparently I’m the only one with this problem?

Leave a Reply