rsync 只同步目录结构不同步文件的方法
(福利推荐:你还在原价购买阿里云服务器?现在阿里云0.8折限时抢购活动来啦!4核8G企业云服务器仅2998元/3年,立即抢购>>>:9i0i.cn/aliyun)
If you are using an older rsync version, try:
rsync -av --include='*/' --exclude='*' /path/to/src /path/to/dest/
rsync -av --include='*/' --exclude='*' /path/to/apache/logs/ root@www433.nixcraft.net.in:/path/to/apache/logs/
# cd /var/log/apache/
# rsync -av -f"+ */" -f"- *" . root@server2.nixcraft.com:/var/log/apache/
Sample outputs:
building file list ... done
./
cricketnow.in/
cyberciti.biz/
hexindia.net/
io9.in/
nixcraft.com/
theos.in/
sent 388 bytes received 98 bytes 972.00 bytes/sec
total size is 0 speedup is 0.00
You can also make local copies as follows:
# cd /var/log/apache/
# rsync -av -f"+ */" -f"- *" . /jailfs/apache/httpd_root/var/log/apache/
相关文章
centos6.4+nginx+mysql+php+phpmyadmin整合过程详解
这篇文章主要介绍了centos6.4+nginx+mysql+php+phpmyadmin整合过程,较为详细的分析了centos6.4+nginx+mysql+php+phpmyadmin整合的具体步骤、操作指令与相关实现技巧,需要的朋友可以参考下2016-11-11Visual Studio Code(vscode) git的使用教程
这篇文章主要介绍了详解Visual Studio Code(vscode) git的使用,小编觉得挺不错的,现在分享给大家,也给大家做个参考。一起跟随小编过来看看吧2017-11-11
最新评论