[root@Mysql ~]# vim /etc/rsyncd.passwd 在文件中添加密码为123456 [root@Mysql ~]# chmod 600 /etc/rsyncd.passwd 添加脚本rsync-mysql.sh [root@Mysql ~]# # cat /home/script-shell/rsync-mysql.sh rsync -avz /home/mysqlbak rsyncuser@192.168.159.17:: databack --password-file=/etc/rsyncd.passwd [root@Mysql ~]# sh /home/script-shell/rsync-mysql.sh [root@ Mysql ~]# crontab -l 15 14 * * * sh /home/script-shell/rsync-mysql.sh

提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
数据同步--rsync
使用rsync进行两台或多台主机直接的数据同步
rsync数据同步