代码如下:
@echo off
echo 开始备份本站重要数据!
xcopy "D:webYUNSAFE.COMWWWROOT*.*" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOT" /i /q
xcopy "D:webYUNSAFE.COMWWWROOTapi" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTapi" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTarchiver" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTarchiver" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTconfig" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTconfig" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTdata" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTdata" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTinstall" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTinstall" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTRewrite" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTRewrite" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTsource" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTsource" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTstatic" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTstatic" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTtemplate" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTtemplate" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTuc_client" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTuc_client" /e /i /q
xcopy "D:webYUNSAFE.COMWWWROOTuc_server" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%WWWROOTuc_server" /e /i /q
echo 本站重要数据备份完成!
echo 开始备份本站MYSQL数据库!
xcopy "D:Program FilesMySQLMySQL Server 5.1Datayafan" "D:webYUNSAFE.COMBAKBakUp%date:~0,10%MYSQLDataYAFAN" /e /i /q
echo 数据库备份完成!
echo 开始打包所有数据!
cd D:webYUNSAFE.COMBAK
"C:Program FilesWinRARRar.exe" a -k -r -s -m1 -inul "D:webYUNSAFE.COMBAKBakUp%date:~0,10%.rar" BakUp%date:~0,10%
echo 打包所有数据完成!
exit
(免责声明:文章内容如涉及作品内容、版权和其它问题,请及时与我们联系,我们将在第一时间删除内容,文章内容仅供参考)