Get the App
SLTechnology News&Howtos  ›  Development  › 

How to realize automatic backup batch processing of discuzX2 whole station

Shulou Source: shulou.com Published: 2022-06-03 08:19:51 10月03日 Update

This article is to share with you about how to achieve automatic batch backup of discuzX2 site. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

The code is as follows:

@ echo off echo starts backing up the important data of this site! Xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ *."D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\" / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ api"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ api\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ archiver" D:\ web\ YUNSAFE.COM\ BAK BakUp%date:~0,10%\ WWWROOT\ archiver\ "/ e / I / Q xcopy" D:\ web\ YUNSAFE.COM\ WWWROOT\ config "D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ config\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ data"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ data\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ install "D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ install\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ Rewrite"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ Rewrite\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ source" D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10 %\ WWWROOT\ source\ "/ e / I / Q xcopy" D:\ web\ YUNSAFE.COM\ WWWROOT\ static "D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ static\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ template"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ template\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT \ uc_client "D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ WWWROOT\ uc_client\" / e / I / Q xcopy "D:\ web\ YUNSAFE.COM\ WWWROOT\ uc_server"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ uc_server\" / e / I / Q echo backup of important data on this site is complete! Echo starts backing up the MYSQL database of this site! Xcopy "D:\ Program Files\ MySQL\ MySQL Server 5.1\ Data\ yafan"D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%\ MYSQLData\ YAFAN\" / e / I / Q echo database backup completed! Echo starts packing all the data! Cd D:\ web\ YUNSAFE.COM\ BAK "C:\ Program Files\ WinRAR\ Rar.exe" a-k-r-s-M1-inul "D:\ web\ YUNSAFE.COM\ BAK\ BakUp%date:~0,10%.rar" BakUp%date:~0,10% echo packaging all the data is complete! Exit, thank you for your reading! On "how to achieve discuzX2 automatic backup batch processing" this article is shared here, I hope the above content can be of some help to you, so that you can learn more knowledge, if you think the article is good, you can share it out for more people to see it!

Tags: Backup data site-wide important content database more articles good practical code data backup articles see knowledge reference help related Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MariaDB Microsoft macOS Linux Docker