需求:把10.5.128.190数据同步到10.5.128.27
用客服端-服务器模式,需要从客户端发起 也就是从10.5.128.27发起
10.5.128.27 作为客户端
10.5.128.190 作为服务端
1. 服务端取得rsync程序文件,一般放到/usr/bin
ftp中转机 rsync目录有
2 .配置服务端
配置文件
用户及密码文件
配置文件/etc/rsyncd.conf(默认无此文件)
use chroot = false
strict modes = false
hosts allow = *
log file = /app/rsync/rsyncd.log
lock file = /app/rsync/rsyncd.lock
# Module definitions
#
[hdarun_app_hdarun]
max connections = 5
uid = root
gid = system
use chroot = no
###服务器需要同步的目录
path = /app/hdarun/test
ignore errors = yes
read only = yes
write only = no
hosts allow = *
hosts deny = 192.168.1.112
comment = rsync files
list = yes
auth users = cnaps2
secrets file = /app/rsync/rsyncd.scrt
transfer logging = y
rsync使用说明
最新推荐文章于 2023-08-15 14:07:55 发布