标题: rsync同步问题 [打印本页] 作者: diego@guo 时间: 2008-06-23 13:32 标题: rsync同步问题 我用Ubuntu的系统。 在rsync客户端手动执行脚本的话,是可以正常同步的。 但是如果把脚本在cron中每隔10分钟执行一次的话,就不能正常同步。
server端的日志如下:
2008/06/23 11:57:33 [24489] params.carameter() - Ignoring badly formed line in configuration file: ignore errors
2008/06/23 11:57:33 [24489] params.carameter() - Ignoring badly formed line in configuration file: ignore errors
2008/06/23 11:57:34 [24489] connect from backup.local (10.23.28.203)
2008/06/23 11:57:34 [24489] rsync on mysql-bug from rs@backup.local (10.23.28.203)
2008/06/23 11:57:34 [24489] building file list
2008/06/23 11:57:34 [24489] rsync: writefd_unbuffered failed to write 4 bytes [sender]: Connection reset by peer (104)
2008/06/23 11:57:34 [24489] rsync error: error in rsync protocol data stream (code 12) at io.c(1123) [sender=2.6.9]
server端的rsyncd.conf的配置如下:
# created by songtao at 2007/12/18
# This script is make a mirror for where is from lx-beijing101 machine's SVN Source Codes to localhost directory and lx-beijing280# This script is the config file of rsync serv
er .
use chroot = no
max connections = 4
pid file = /var/run/rsyncd.pid
lock file = /var/run/rsync.lock
log file = /var/log/rsyncd.log
客户端的备份脚本如下:
#!/bin/bash
# This script is make a mirror for that backup SVN source codes from lx-beijing101 machine /data/SVN_REPOS/ to lx-beijing280 machine
#/backup-svn/SVN_REPOS/ ;