:: "Ntbackup for NT4x.txt" . An Ntbackup cmd file for Scheduler (for NT v4x). :: Please rename this file to "Ntbackup for NT4x.cmd" to use in Scheduler. :: By Bret A. Bennett :: Revisions: :: 09/28/01: Added Net Start commands to restart Trend Micro's Scanmail for Exchange (ie. SMEX). :: 08/22/01: This revision has additions to accommodate Small Business Server v4.5 (SBS): Exchange has special procedure to stop and start the "Microsoft Exchange POP3 Connector" service. For further info see Q257689 and Q160572. :: Note - Sc.exe is available in the NT Resource Kit or at www.bretabennett.com/utils . :: 05/30/01 :: 04/03/01 :: Note - Aintx.zip is available at various ftp locations or at www.bretabennett.com/utils . :: Stop Exchange net stop MSExchangeMSMI /y net stop MSExchangePCMTA /y net stop MSExchangeFB /y net stop MSExchangeDX /y net stop MSExchangeIMC /y net stop MSExchangeMTA /y net stop MSExchangeIS /y net stop MSExchangeDS /y net stop MSExchangeSA /y :: The following line is only necessary if running on Small Business Server v4.5. It requires Sc.exe (see "Revisions" above). sc stop mspop3connector :: Create the Date environmental variable. Requires Ntdate.exe :: Aintx.zip contains ntdate.exe and other Unix-like utilities for NT. set DayOfWeek= set Month= set Day= set Year= set Hour= set Minute= set Second= set Date= for /F "tokens=1-7 delims=: " %%i in ('ntdate') do ( set DayOfWeek=%%i set Month=%%j set Day=%%k set Year=%%l set Hour=%%m set Minute=%%n set Second=%%o set Date=%%i %%j %%k %%l %%m %%n %%o ) :: Here's the backup code: :: Here's the Full Bkup code: ntbackup backup C: D: /v /b /hc:off /t normal /d "Full Backup of drives C and D" /l "c:\bkup-log\FB %Date%.log" /e /tape:0 :: Here's the Daily bkup code: :: ntbackup backup C: D: /a /v /hc:off /t incremental /d "Daily Backup of drives C and D" /l "c:\bkup-log\DB %Date%.log" /e /tape:0 : Restart Exchange net start MSExchangeSA net start MSExchangeDS net start MSExchangeIS net start MSExchangeMTA net start MSExchangeIMC net start MSExchangeDX net start MSExchangeFB net start MSExchangePCMTA net start MSExchangeMSMI :: The following line is only necessary if running on Small Business Server v4.5. It requires Sc.exe (see "Revisions" above). sc start mspop3connector :: Restart Trend Micro's Scanmail for Exchange (ie. SMEX). net start scanmail_monitor net start scanmail_realtimescan net start scanmail_web :: Alert a user that the fullbkup has finished. net send Administrator Full Backup Finished. :: End