discuzX2全站自动备份批处理
discuzX2全站自动备份批处理
发布时间:2016-12-28 来源:查字典编辑
摘要:复制代码代码如下:@echooffecho开始备份本站重要数据!xcopy"D:webYUNSAFE.COMWWWROOT*.*""D:we...

复制代码 代码如下:

@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

推荐文章
猜你喜欢
附近的人在看
推荐阅读
拓展阅读
相关阅读
网友关注
最新DOS/BAT学习
热门DOS/BAT学习
脚本专栏子分类