rsync同步文件简单使用
注:本文基于rsync-3.1.2-6.el7_6.1编写 1、环境准备 机器 用途 192.168.0.100 rsync服务端 192.168.0.120 rsync客户端 2、服务端配置 安装rsync 由于使用CentOS 7系统,因此,rsync已经安装好,如果没安装直接使用yum安装即可, yum install -y rsync 配置rsyncd.conf [ root@CentOS-7-4 /home ] # cat /etc/rsyncd.conf uid = nobody gid = nobody use chroot = false max connections = 4 pid file = /var/run/rsyncd.pid log file = /var/log/rsyncd.log lock file = /var/run/rsync.lock transfer logging = yes [ test ] path = /testdir/ auth users = testuser secrets file = /etc/rsyncd.secrets read only = false uid = root gid = root 其中, log file 即为rsync日志,出现问题的时候查看这个来看报错信息 path 即为test模块映射的目录