REM ########################################################################
REM Program Name: Mirror_TST.BAT
REM Version : 2.01
REM Owner : TDE Information System
REM Purpose : to mirror data between active test server and backup server
REM ========================================================================
REM Command Syntax: mirror_tst.bat <source test server>
REM Example: mirror_tst.bat tsttdem1
REM ========================================================================
REM Notes:
REM V2.01 JM 7/20/2001
REM -Added parameter input capability.
REM -Disable log file zipping. Discover that pkzip25 did not work well
REM Scheduler service. pkzip25 was found to be working well with Task
REM Scheduler service.
REM -Added /PURGE capability which allow robocopy to delete files/folders
REM that are found in target but not in source to ensure no accumulation of
REM stile data in target.
REM -Added command syntax for reference purposes.
REM
REM V2.00 JM 7/18/2001
REM add capability to compress previous log file to reduce space consumption
REM add robocopy capability to reduce time to mirror the designated data
REM
REM ########################################################################
DEL C:/MIRROR/MIRROR_TST_SERVICE_BEGIN > NUL
DEL C:/MIRROR/MIRROR_TST_SERVICE_END > NUL
DEL c:/mirror/mirror_tst_previous_07_day.log > nul
rename c:/mirror/mirror_tst_previous_06_day.log mirror_tst_previous_07_day.log
rename c:/mirror/mirror_tst_previous_05_day.log mirror_tst_previous_06_day.log
rename c:/mirror/mirror_tst_previous_04_day.log mirror_tst_previous_05_day.log
rename c:/mirror/mirror_tst_previous_03_day.log mirror_tst_previous_04_day.log
rename c:/mirror/mirror_tst_previous_02_day.log mirror_tst_previous_03_day.log
rename c:/mirror/mirror_tst_previous_01_day.log mirror_tst_previous_02_day.log
rename c:/mirror/mirror_tst.log mirror_tst_previous_01_day.log
ECHO MIRROR TSTFOX02 SERVICE BEGIN > C:/MIRROR/MIRROR_TST_SERVICE_BEGIN
net use //172.17.2.16/intelap dmd$backup /user:dmd-backup
cd/
robocopy C:/autoftp //172.17.2.16/intelap/tstfox04/c_drive/autoftp *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
robocopy C:/ifics //172.17.2.16/intelap/tstfox04/c_drive/ifics *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
robocopy C:/xmanf //172.17.2.16/intelap/tstfox04/c_drive/xmanf *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
robocopy C:/ipdl //172.17.2.16/intelap/tstfox04/c_drive/ipdl *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
robocopy d:/tstcom //172.17.2.16/intelap/tstfox04/d_drive/tstcom *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
robocopy e:/ //172.17.2.16/intelap/tstfox04/e_drive *.* /E /V /NP /R:2 >> c:/mirror/mirror_tst.log
ECHO MIRROR TSTFOX02 SERVICE END > C:/MIRROR/MIRROR_TST_SERVICE_END