Task – When Was The Last Database Backup Run?…

I know that almost all companies will be using a backup software, cheaper or expensive and it will give you information regarding everything related to the backup. What if you are in a large company and have a dedicated backup team and you don’t have access to any of the backup information?

As an exchange administrator, let’s say that you want to know when the last full backup was run on all your mailbox databases. The task becomes really simple with Powershell. Run

Get-MailboxDatabase –status | fl name, lastfullbackup, lastincrementalbackup

4

You can further target the databases on a particular server with the –server parameter.

Get-MailboxDatabase –Server “server name” –status | fl name, lastfullbackup, lastincrementalbackup

If you have a large number of mailbox servers or want to run it as a scheduled task & have the details emailed to you (I will cover how to use powershell to send emails in a later article), run

Get-ExchangeServer | Where-Object {$_.IsMailboxServer –eq $true} | ForEach-Object { Get-MailboxDatabase –Server $_.Name –Status } | fl name, lastfullbackup, lastincrementalbackup

5

As always, you can export the output to a txt, csv or html file. Run the command below to get the output in an html file.

Get-MailboxDatabase –status | fl name, lastfullbackup, lastincrementalbackup | ConvertTo-Html | Out-File c:backup.html

If you want to launch the html file from powershell itself, run

Invoke-Item c:backup.html

SUBSCRIBE FOR DAILY ARTICLE UPDATES VIA EMAIL
Get the published articles delivered straight to your inbox. Your details will not be passed to any third party company.

Exchange Architect, Blogger, Husband & Dad. I have been in IT for the last 11 years, with Exchange Server becoming the prime area in the last few years. I am active on TechNet forums & Experts Exchange.

View all contributions by

2 comments… add one

Speak Your Mind…

Website Hits