How to Create automatic Batch file to backup Outlook pst

September 10, 2013 at 18:12:17
Specs: Windows 7
I have simple batch file to copy a Outlook pst file to an external drive. The pst file is copied but the taskeng.exe window "hangs" and does not continue to restart outlook and therefore close on its own. The pst file is over 4Gb. I would also like to know how to prevent the taskeng.exe windows from popping up as well. Any help is appreciated, thank you!

:: Backup pst file to Server external drive
@echo off
setlocal EnableDelayedExpansion
start "" "C:\Program Files (x86)\Microsoft Office\Office12\Outlook.exe"
taskkill /im outlook.exe /f
@ping -n 5 -w 1000>nul
@ping -n 5 -w 1000>nul
robocopy "C:\Users.pst" "\\SERVER\Outlook Backup\user.pst"
start outlook.exe

message edited by prelude

See More: How to Create automatic Batch file to backup Outlook pst

September 10, 2013 at 21:23:15
You should look at using Volume Shadow copy (Volume Shadow Service / VSS) for open/locked files on WinXP, Win7 or newer recomended, NTFS drives.

NTFS formatted drives are a base level requirement for copying open/locked files like Outlook PST files. If you are not familiar with the differences between FAT(FAT32/FATEX) and NTFS drives then you should do some research now to understand file system locking and management options available.

This is a very good reference for using robocopy to backup open/locked files:

If you are running Exchange 2010 and have "good storage space" for all of your Outlook/Exchange users, I strongly recommend importing all PST files to Exchange and not allowing local "c:\" drive PST files. Read more here: PST import request.

I know this is not an explicit answer but I hope it helps you in the right direction for your company. I'm happy to help with the actual details on this topics if you think either reference might be what you are looking for.


--Mike Wood

message edited by mikewwood

Report •

September 11, 2013 at 11:39:10
Thanks for the quick reply. Reading through the provided information. I'll be back soon.

Report •
Related Solutions

Ask Question