文件服务器rsync

随笔2个月前发布 小雪薇薇
26 0 0

服务器配置

echo “cc:cc2023” > /etc/rsync.password
chmod 600 /etc/rsync.password
vi /etc/rsyncd.conf

uid = root
gid = root
use chroot = no
max connections = 40
pid file = /var/run/rsyncd.pid
log file = /var/log/rsyncd.log
exclude = lost+found/
transfer logging = yes
timeout = 900
ignore nonreadable = yes
dont compress   = *.gz *.tgz *.zip *.z *.Z *.rpm *.deb *.bz2
auth users = cc
secrets file = /etc/rsync.password

[backup]
path = /data1/backup
comment = my backup dir
read only = false

运行

sudo systemctl start rsyncd
sudo firewall-cmd –list-all

rsync -avzP ./kylin10sp1-desktop-x64-template.qcow2 cc@10.31.66.80::backup
rsync -avzP ./newdir/ cc@10.31.66.80::backup

© 版权声明

相关文章

暂无评论

您必须登录才能参与评论!
立即登录
暂无评论...