rsync实时同步文件
http://rsync.samba.org/download.html
[root@v01 src]# yum install git
[root@v01 src]# git clone git://git.samba.org/rsync.git
[root@v01 src]# git clone git://git.samba.org/rsync.git
Initialized empty Git repository in /usr/local/src/rsync/.git/
remote: Counting objects: 25470, done.
remote: Compressing objects: 100% (9736/9736), done.
[root@v01 local]# which rsync
/usr/bin/rsync
[root@v01 local]# rpm -qf /usr/bin/rsync
rsync-3.0.6-12.el6.x86_64
[root@v01 www]# rsync -a webtest/ online/
[root@v01 www]# tree online/
online/
├── authz
├── index.html
└── index.php 0 directories, 3 files
[root@v01 www]# cd online/
[root@v01 online]# ll -all
total 24
drwxr-xr-x. 3 www www 4096 May 9 12:03 .
dr-xr-xr-x. 6 www www 4096 May 9 12:42 ..
-rw-r--r--. 1 root root 1080 May 9 12:03 authz
-rw-r--r--. 1 root root 31 May 9 11:40 index.html
-rw-r--r--. 1 root root 17 May 9 10:42 index.php
drwxr-xr-x. 6 root root 4096 May 9 12:03 .svn
[root@v01 www]# rsync -v webtest/* online/ #如果加*(如:webtest/*),则.xxx的隐藏文件不会被同步
authz
index.html
index.php sent 1315 bytes received 69 bytes 2768.00 bytes/sec
total size is 1128 speedup is 0.82
[root@v01 www]# cd online/
[root@v01 online]# ls
authz index.html index.php
[root@v01 online]# ll -all
total 20
drwxr-xr-x. 2 root root 4096 May 9 12:51 .
dr-xr-xr-x. 6 www www 4096 May 9 12:50 ..
-rw-r--r--. 1 root root 1080 May 9 12:51 authz
-rw-r--r--. 1 root root 31 May 9 12:51 index.html
-rw-r--r--. 1 root root 17 May 9 12:51 index.php
rsync实时同步文件的更多相关文章
- linux下实现多台服务器同步文件(inotify-tools+rsync实时同步文件安装和配置)
		
inotify-tools+rsync实时同步文件安装和配置 注:转载https://www.linuxidc.com/Linux/2012-06/63624.htm
 - inotify-tools+rsync实时同步文件安装和配置
		
服务器A:论坛的主服务器,运行DZ X2论坛程序;服务器B:论坛从服务器,需要把X2的图片附件和MySQL数据实时从A主服务器实时同步到B服务器.MySQL同步设置会在下一编中说到.以下是用于实时同步 ...
 - rsync+inotify安装配置 实时同步文件
		
安装 #安装inotify 工具 [root@localhost ~]# yum install inotify-tools -y 常用命令 [root@localhost ~]# inotifywa ...
 - linux设置rsync+inotify实时同步文件
		
linux设置rsync+inotify实时同步文件 应用场景: 同步接收方:test01 接收目录:/opt/software/test/a/ 同步发起方:test02 同步目录:/opt/so ...
 - 真正的inotify+rsync实时同步 彻底告别同步慢
		
真正的inotify+rsync实时同步 彻底告别同步慢 http://www.ttlsa.com/web/let-infotify-rsync-fast/ 背景 我们公司在用in ...
 - sersync 实时同步文件
		
sersync 主要用于服务器同步,web镜像等功能.sersync是使用c++编写,在结合rsync同步的时候,节省了运行时耗和网络资源.因此更快.sersync配置起来很简单.另外本项目相比较其他 ...
 - CentOS7之Rsync+Inotify架构实现实时同步文件和文件夹
		
简介:rsync是用来同步文件和文件夹的,inotify是用来实现监听变动而自动同步的 OS:Centos7.3 服务器端:172.16.13.157 客 户 端 :172.16.13.156 目 ...
 - linux rsync实时同步
		
rsync同步 同步与复制的差异:复制:完全拷贝源到目标同步:增量拷贝,只传输变化过的数据 同步操作:remote sync 远程同步支持本地复制,或与其他ssh,rsync主机同步.官方网站:htt ...
 - lsyncd —— 多机器实时同步文件神器
		
lsyncd 是一个支持实时.双向.多机器的多模式文件同步工具. 使用 Lua 语言封装了 inotify 和 rsync 工具,采用了 Linux 内核(2.6.13 及以后)里的 inotify ...
 
随机推荐
- frameset用法
			
<html> <frameset rows="15%,*" border="1" frameborder="1" scro ...
 - latin1
			
Latin1是ISO-8859-1的别名,有些环境下写作Latin-1.ISO-8859-1编码是单字节编码,向下兼容ASCII,其编码范围是0x00-0xFF,0x00-0x7F之间完全和ASCII ...
 - C++中map的一点疑惑...
			
int CRuntimePara::getInt(const string& strKey,int iDefault){ map<string,string>::const_ite ...
 - sh脚本学习之: sh脚本 、sed、awk
			
sh脚本 sh命令的批处理文件,支持更复杂的逻辑. Shell中的变量 参数 $0 当前脚本路径 $1....$n 脚本执行对应的第n个参数 条件判断 文件判断 test [op] path e存在 ...
 - 修改织梦默认提示"dedecms提示信息!"
			
在使用dedecms搜索的时候如果搜索频率过快,经常会跳出一个提示窗口提示"管理员设定搜索时间间隔为*秒,请稍后再试!".怎么自定义Dedecms提示信息呢?让心存不轨的家伙少一个 ...
 - java笔记--反射进阶之总结与详解
			
一.反射进阶之动态设置类的私有域 "封装"是Java的三大特性之一,为了能更好保证其封装性,我们往往需要将域设置成私有的, 然后通过提供相对应的set和get方法来操作这个域.但是 ...
 - Android EditText的设置
			
1.输入法Enter键图标的设置: 软件盘的界面替换只有一个属性android:imeOptions,这个属性的可以取的值有normal,actionUnspecified,actionNone,ac ...
 - 直接拿来用!超实用的Java数组技巧攻略
			
java编程语言经验分享 摘要:本文分享了关于Java数组最顶级的11大方法,帮助你解决工作流程问题,无论是运用在团队环境或是在私人项目中,你都可以直接拿来用. 本文分享了关于Java数组最顶级的11 ...
 - Unity3D如何制作透贴和使用透贴模型
			
http://momowing.diandian.com/post/2012-10-25/40040842845 Unity3D如何制作透贴和使用透贴模型??解决办法!!! 问题: 同事通过3DMAX ...
 - xcode SVN
			
Mac上SVN的管理工具: CornerStone http://blog.csdn.net/wohaoxuexi/article/details/8444184 步骤: 1. import 项目到s ...