Post by Jay Mueller on Nov 7, 2007 9:35:46 GMT -6
How to schedule a batch file to do full and differential backups of my entire Microsoft Office SharePoint 2007 / Windows SharePoint Services environments.
We've written 2 batch files that will help in doing a complete and differential backup of your entire MOSS environment. These batch files can be scheduled using the Scheduled Tasks in Control Panel of Windows 2003 Server. You can copy and paste the code into notepage and save the file as a .bat. We recommend saving your batch files in the same directory as the STSADM.exe tool.
Regarding permissions the account used as the Database Account account should have the following access.
Must have Write permissions to the backup locations.
8-)Full Backup
cd\
cls
REM - Microsoft Office SharePoint Server 2007 Batch Backup File
REM - Windows Task Scheduler will be used to run this batch file on a scheduled basis
cd c:\program files\common files\microsoft shared\web server extensions\12\bin
start stsadm.exe -o backup -directory "\\storage\install support\dev env backup" -backupmethod full
8-)Differential Backup
cd\
cls
REM - Microsoft Office SharePoint Server 2007 Batch Backup File
REM - Windows Task Scheduler will be used to run this batch file on a scheduled basis
cd c:\program files\common files\microsoft shared\web server extensions\12\bin
start stsadm.exe -o backup -directory "\\storage\install support\dev env backup" -backupmethod differential
:oOn a side note here are the other STSADM.exe Catastrophic controls you can use via the command prompt or in the batch file.
stsadm.exe -o backup
-directory <UNC path>
-backupmethod <full | differential>
[-item <created path from tree>]
[-percentage <integer between 1 and 100>]
[-backupthreads <integer between 1 and 10>]
[-showtree]
[-quiet]
We've written 2 batch files that will help in doing a complete and differential backup of your entire MOSS environment. These batch files can be scheduled using the Scheduled Tasks in Control Panel of Windows 2003 Server. You can copy and paste the code into notepage and save the file as a .bat. We recommend saving your batch files in the same directory as the STSADM.exe tool.
Regarding permissions the account used as the Database Account account should have the following access.
- Database server's SQL Service Account
- Windows SharePoint Services Timer service account
- Central Administrator pool account
Must have Write permissions to the backup locations.
8-)Full Backup
cd\
cls
REM - Microsoft Office SharePoint Server 2007 Batch Backup File
REM - Windows Task Scheduler will be used to run this batch file on a scheduled basis
cd c:\program files\common files\microsoft shared\web server extensions\12\bin
start stsadm.exe -o backup -directory "\\storage\install support\dev env backup" -backupmethod full
8-)Differential Backup
cd\
cls
REM - Microsoft Office SharePoint Server 2007 Batch Backup File
REM - Windows Task Scheduler will be used to run this batch file on a scheduled basis
cd c:\program files\common files\microsoft shared\web server extensions\12\bin
start stsadm.exe -o backup -directory "\\storage\install support\dev env backup" -backupmethod differential
:oOn a side note here are the other STSADM.exe Catastrophic controls you can use via the command prompt or in the batch file.
stsadm.exe -o backup
-directory <UNC path>
-backupmethod <full | differential>
[-item <created path from tree>]
[-percentage <integer between 1 and 100>]
[-backupthreads <integer between 1 and 10>]
[-showtree]
[-quiet]