客户端:Gentoo、GCC 4.3.4、RSync 3.0.9 服务器:Ubuntu 10.04.4 LTS、RSync 3.0.7
客户端和服务器连接通过的是Internet,大约2Mbps。平没问题。
在任何方向上调用任何文件的 RSync 挂在随机文件上,然后在超时后失败:
[sender] io timeout after 30 seconds -- exiting
rsync error: timeout in data send/receive (code 30) at io.c(140) [sender=3.0.9]
[sender] _exit_cleanup(code=30, file=io.c, line=140): about to call exit(30)
Run Code Online (Sandbox Code Playgroud)
在 1/10 尝试中正确通过。
我尝试添加 SSH 选项 TcpRcvBufPoll=yes, KeepAlive=yes; 禁用和启用 rsync 压缩——没有变化。
如何使 rsync 正常工作?
一种方法是使用 tcpdump
tcpdump port 22 and host <IP>
Run Code Online (Sandbox Code Playgroud)
和斯特雷斯
strace -f -o xxx -p <PID of the rsync process>
Run Code Online (Sandbox Code Playgroud)
两边跑。当超时发生时,您至少应该能够在 tcpdump 的输出中看到不规则的东西。
随着新信息的出现,您应该能够追查问题的根源。
此外,在两台机器上运行traceroute或mtr以检查它们之间的路由/连接是否健康。
归档时间: |
|
查看次数: |
13158 次 |
最近记录: |