Tuesday, October 6, 2015

High availability and backup of Outlook archive

Email in Outlook connected with Exchange mailbox is quite safe. The usual mail storage file (PST) is replaced with a mirror of the data (OST file) saved directly on the company's server. If anything bad happens to your computer, or the OST storage file gets corrupted - no worries, all your data is safe and sound in the central mailbox database.

However it is quite often that the company policy sets the limit to the size of your Exchange mailbox. If you preserve too many messages and reach the full capacity of the storage the server will disable sending any emails from your address.

To help this situation Outlook is fitted with the archiving feature. In short - it automatically saves all Outlook items (emails, tasks, appointments etc.) older than a set threshold to a separate PST file, stored locally on your computer. This way you can keep your Exchange mailbox small and below the company's limit and maintain access to all your old mail as well.

Unfortunately, since the archive PST file is stored locally on your computer, it is not protected the same way as your mailbox. If the hard drive of your PC fails or the PST file is corrupted, all your archived data may be lost. A good idea is configuring the archiving function to store the PST data file directly on the company server (e.g. in a network shared folder). The drawback is that when disconnected from your company's network you cant access the archive.

To ensure your data safety and provide high availability access to your old emails try a simple method described below. It automatically copies your local archive file to the defined location every time you log into your computer.

Step 1.


Open Windows Notepad and enter the following text in it:

copy "C:\Users\Luke\Documents\Outlook Files\Archive.pst" g:\
Timeout 20

Make sure to replace "C:\Users\Luke\Documents\Outlook Files\Archive.pst"  with the actual path to your own archive PST. If you want to copy all files from that location simply replace the file part (Archive.pst) with the wildcard *.*

Also make sure to replace g:\ with the drive letter of your mapped network share, or any other folder of your choice.

The Timeout 20 command gives additional delay after completing the process, so you can see its results.

Step 2.


Save the above text to your hard drive as a bat file, e.g.: copy-pst.bat . You can test the script by double clicking it.



Step 3.


Launch the  Task Scheduler tool by typing its name in the Windows Start menu search field. Alternatively you can find it in the Windows Control Panel, Administrative Tools.


Step 4.


Click Create Basic Task in the right hand side panel. This launches the configuration wizard.



Step 5.

Follow the configuration wizard. After entering the name of the task and a short description hit the Next button. The following window lets you choose when the task should be triggered and launched. Select  When I log on and hit Next.



In the third step of the wizard select the action - mark Start a program and hit the Next button again.




In a submenu window that opens navigate to the bat file you have created earlier by clicking the Browse button. Click Next and then the Finish button to complete the wizard.



That's it! You have just created a system task that will run the archive PST file copying script every time you log into your windows account.

It keeps the archive locally on your machine, so it is always accessible even outside your company's network and makes a backup copy of it to the safe spot of your choice.

See also our other hints about:

How to set up internal autoresponder in Exchange Server
Quick commands to check Exchange Server health
How to check out of office status in Exchange