首页 > Web开发 > 详细

快速在liunx下web备份打包

时间:2020-02-26 13:08:58      阅读:85      评论:0      收藏:0      [点我收藏+]

如何快速的对网站进行打包,可以使用liunx自带的tar命令

 

 tar -cvf /www/wwwroot/www.abc.com/ac.tar /www/wwwroot/www.abc.com/ --exclude *.log --exclude *.zip --exclude *.rar --exclude *.tar --exclude *.mp4 --exclude *.mp3

 

 /www/wwwroot/www.abc.com/ac.tar  意思是打包存放的地址

/www/wwwroot/www.abc.com/ --exclude *.log --exclude *.zip --exclude *.rar --exclude *.tar --exclude *.mp4 --exclude *.mp3  意思是打包路径/www/wwwroot/www.abc.com/下的所有文件

排除了所有log文件、rar文件、rar文件等等,以此类推。

 

--exclude 打包时要排除的文件,也可以是目录

 

快速在liunx下web备份打包

原文:https://www.cnblogs.com/kuyeokuye/p/12366114.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!