rsync: failed to connect to x.x.x.x: Connection refused (111)
来源:互联网 发布:sql报表编辑器 编辑:程序博客网 时间:2024/04/30 10:51
问题:
工作背景:
1. 局域网内两台PC机,一台用作rsync服务器,一台用作rsync客户端,两者以C/S方式(即客户连接远程rsync 服务器,用户验证由rsync 服务器负责)而非远程shell方式(即用户验证由远程shell负责,shell一半使用ssh)进行文件同步;
2. rsync服务器端使用xinetd方式运行rsync服务,即使用/etc/xinetd.d/rsync作为配置文件,以service xinetd restart来启动服务;
3. 从客户端同步服务器端的文件时,出现错误如下:
u1204@u1204-zhw:~/wrk/tmp/tmp$ rsync -a root@192.168.1.144::web_backup/ .rsync: failed to connect to 192.168.1.144 (192.168.1.144): Connection refused (111)rsync error: error in socket IO (code 10) at clientserver.c(128) [Receiver=3.1.0pre1]
解决办法:
1. 该问题属于服务器端服务未启动所造成。
检查rsync服务是否已经启动,
u1204@u1204-zhw:/tftpboot$ ps -ef | grep rsync可以看到rsync服务并没有启动。
root 25509 1 0 15:02 ? 00:00:05 gvim /etc/rsyncd.conf
u1204 26629 5681 0 16:01 pts/5 00:00:00 grep --color=auto rsync
手动启动rsync服务,
u1204@u1204-zhw:/tftpboot$ sudo rsync --daemon
u1204@u1204-zhw:/tftpboot$ ps -ef | grep rsyncroot 25509 1 0 15:02 ? 00:00:07 gvim /etc/rsyncd.confroot 26800 1 0 16:05 ? 00:00:00 rsync --daemonu1204 26824 5681 0 16:07 pts/5 00:00:00 grep --color=auto rsync可以看到rsync服务已经启动了。
2. 从客户端重新进行文件同步操作。
# /usr/local/rsync -a root@192.168.1.144::web_backup .Password: # lsmsg_info.txt hello.txt hello.cpp hello.c hello可以看到服务器端的文件同步到本地目录了。
问题解决。
- rsync: failed to connect to x.x.x.x: Connection refused (111)
- rsync: failed to connect to X.X.X.X: No route to host (113)
- Putty X11 proxy: unable to connect to forwarded X server: Network error:connection refused
- ssh 不能连接linux系统 Could not connect to '192.168.X.X'(port 22) Connection failed
- rsync: failed to connect to 192.168.2.9: Connection refused
- Call to hostname/x.x.x.x:9000 failed on connection exception:java.net.ConnectException
- android Connection to http: 192.168.xx.x:8080 refused
- rsync错误处理-failed to connect to 192.168.xxx.xxx: Connection refused (111)
- cannot connect to X server
- 【MySQL】x.x.x.x is not allowed to connect to this MySQL serve
- 一个无法访问mysql的错误: ERROR 2003 (HY000): Can't connect to MySQL server on 'x.x.x.x' (111)
- 2003 - Can't connect to MySQL server on 'x.x.x.x' (10038)
- connect() failed (111: Connection refused) while connecting to upstream
- [Linux] Can not connect to X server
- designer: cannot connect to X server
- rqt: cannot connect to X server
- cannot connect to X server :0.0
- wkhtmltopdf: cannot connect to X server
- 每天一段小代码——图的存储
- c++设计模式--组合模式
- android Random的使用
- 用故事讲解虚函数。
- 12枚或者13枚鸡蛋,有一个坏的,用天平3次称出来
- rsync: failed to connect to x.x.x.x: Connection refused (111)
- Java与C底层数据类型转换
- 动态语言跟静态语言
- ASP.NET MVC4.0发布网站
- C++ AMP 概述
- ActivityGroup + GridView 实现Tab分页标签
- android在adapter中调用activity跳转效果
- Android XcapClinet 二
- iPhone开发:单独添加.xib文件