rsync的BT故障排查

今天一早DB就过来说,一直在工作的rsync服务没有将中转的数据文件定时上传至服务器上,叫我看下原因。

经检查,原来是做了crontab的rsync无法工作了,找出了故障,紧接着便是解决。

1. 先来确定是否是网络的原因,首先是telnet

[[email protected] ~]$ telnet 10.123.1.66 873

Trying 10.123.1.66...

Connected to 10.123.1.66.

Escape character is ‘^]‘.

Connection closed by foreign host.

telnet出现了闪退的问题

其实到了这里我就该想到服务被关掉了才对,唉。。。

2.检查rsync服务器的iptables以及selinux

[[email protected] ssh]# iptables -L

Chain INPUT (policy DROP)

target     prot opt source               destination

ACCEPT     all  --  anywhere             anywhere

ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED

ACCEPT     icmp --  anywhere             anywhere            icmp destination-unreachable

ACCEPT     icmp --  anywhere             anywhere            icmp time-exceeded

ACCEPT     icmp --  anywhere             anywhere            icmp echo-reply

ACCEPT     icmp --  anywhere             anywhere            icmp echo-request

ACCEPT     tcp  --  10.123.0.0/16        anywhere            tcp dpt:ssh

ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:webcache

ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:rsync

ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:pcsync-https

REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited

Chain FORWARD (policy DROP)

target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)

target     prot opt source               destination

[[email protected] ssh]# getenforce

Disabled

iptables以及selinux均正常

3. rsync检测

[[email protected] ~]$ rsync -avz /translog/elcotable/DBM-721_elcas_order_20170304.del [email protected]:/home/elpayment

ssh: connect to host 10.123.1.66 port 22: Connection timed out

rsync: connection unexpectedly closed (0 bytes received so far) [sender]

rsync error: unexplained error (code 255) at io.c(600) [sender=3.0.6]

仍出现错误

4.检查rsync相关的配置以及检查rsync的日志

[[email protected] ssh]# tail -100f /var/log/rsyncd.log

2017/03/03 18:00:00 [8942] connect from UNKNOWN (192.168.1.8)

2017/03/03 18:00:00 [8942] rsync to guiyangKF/ from [email protected] (192.168.1.8)

2017/03/03 18:00:00 [8942] receiving file list

2017/03/03 18:00:00 [8942] sent 76 bytes  received 134 bytes  total size 0

2017/03/03 18:35:30 [11286] rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at rsync.c(542) [receiver=3.0.6]

2017/03/06 11:03:05 [18972] rsyncd version 3.0.6 starting, listening on port 873

2017/03/06 11:11:57 [19043] rsync: failed to create pid file /var/run/rsyncd.pid: File exists (17)

2017/03/06 11:11:57 [19043] rsync error: error in file IO (code 11) at clientserver.c(1015) [receiver=3.0.6]

2017/03/06 11:12:08 [19046] rsyncd version 3.0.6 starting, listening on port 873

[[email protected] ssh]# tail -100f /var/log/messages

Mar  6 11:09:45 epsapp1 rsyncd[19022]: rsync: unable to open configuration file "/etc/rsyncd.conf": No such file or directory (2)

Mar  6 11:09:45 epsapp1 rsyncd[19022]: rsync error: syntax or usage error (code 1) at clientserver.c(953) [receiver=3.0.6]

Mar  6 11:09:45 epsapp1 xinetd[2854]: EXIT: rsync status=1 pid=19022 duration=0(sec)

5.结论是:rsync没有正常启动

[[email protected] ssh]# ps -ef|grep rsync

root     19116     1  0 11:15 ?        00:00:00 rsync --daemon --config=/etc/rsyncd.conf

root     19224 18129  0 11:42 pts/1    00:00:00 grep rsync

启动后,rsync传输正常

[[email protected] ~]$ bash 1-66rsync.sh

sending incremental file list

DBM-721_elcas_order_20170306.del

sent 190816 bytes  received 27 bytes  127228.67 bytes/sec

total size is 986828  speedup is 5.17

sending incremental file list

sent 71 bytes  received 8 bytes  158.00 bytes/sec

total size is 30448786  speedup is 385427.67

时间: 2024-07-31 17:23:23

rsync的BT故障排查的相关文章

Rsync 12种故障排查及思路

Rsync 故障排查整理 Rsync服务常见问题汇总讲解: ============================================================================================== 1 客户端的错误现象:No route to host rsync服务端开启的iptables防火墙 [[email protected] tmp]# rsync -avz /etc/hosts [email protected]::backup r

Rsync 故障排查整理(经典)

Rsync 故障排查整理Rsync服务常见问题汇总讲解: 1 客户端的错误现象:No route to hostrsync服务端开启的iptables防火墙 [[email protected] tmp]# rsync -avz /etc/hosts [email protected]::backup rsync: failed to connect to 172.16.1.41: No route to host (113) rsync error: error in socket IO (c

51CTO学习笔记--Linux运维故障排查思路与系统调优技巧视频课程(高俊峰)

51CTO学习笔记--Linux运维故障排查思路与系统调优技巧视频课程 第一课 Linux运维经验分享与思路 1.一般把主机名,写到hosts下    127.0.0.1    hostname,因为很多应用要解析到本地.oracle没有这个解析可能启动不了. 2.注释掉UUID以及MAC地址,需要绑定网卡的时候,这个可能会有影响. 3.磁盘满了无法启动,  var下木有空间,无法创创建PID等文件,导致文件无法启动,按e   进入single  然后b  重启进入单用户模式. 4.ssh登陆系

[linux]df 磁盘100%Used告警,du显示目录状态良好的故障排查

1.回顾: 某在线主机深夜连续接到告警系统的disk Used 超限告警. 登陆主机查看却遇到了困惑:在检查磁盘使用量 df –h 出来的磁盘使用量确实和告警信息一样,已经被100%占用,但是查看目录大小 du 时,却显示实际目录大小并非这样,而是有很大空闲空间. 如图:磁盘用量 df –h 结果为100%Used, 目录实际总大小 du –h –max-depth=1,显示总目录大小为60k,几乎可以忽略的使用比例. [知识准备] [linux] lsof 命令了解: lsof(list op

Atitit. 包厢记时系统 的说明,教程,维护,故障排查手册v2 pb25.doc

Atitit. 包厢记时系统 的说明,教程,维护,故障排查手册v2 pb25.doc 1. 服务器方面的维护1 1.1. 默认情况下,已经在系统的启动目录下增加了 个启动项目1 1.2. 后台服务.保持mysql数据库服务启动状态2 1.3. 服务器如无必要无需关闭,保持一直开启状态...2 1.4. 配置文件说明3 1.4.1. 指明选片服务端url3 1.4.2. 包厢计时系统提供的接口url (部分分店需要)3 1.4.3. 其他设置3 2. 故障排查4 3. 包厢记时系统5 3.1. 维

公司突然断网故障排查

记一次公司断网故障排查 本来大周一挺好的,刚坐在工位上不到半个小时,公司突然断网,此时,我是有点凌乱的! 下边是排查故障的过程 1,首先我看下本机电脑的IP地址,禁用启动,发现仍旧可以获取到IP地址,这代表DHCP分发是没问题的,因为是突然断网,代表着交换机路由器配置不可能出问题 2,接着我带着笔记本进入机房,看了下光猫,光猫状态正常,然后看了下路由器,路由器是H3C的,有web管理界面,进入web管理界面,发现IP地址状态也是正常的. 4,接着给公司网络运营商打电话,他说是他们那边的问题,有个

虚拟机性能监控与故障排查工具介绍

本文来读书籍<深入理解java虚拟机-JVM高级特性与最佳实践>的阅读笔记,并且对虚拟机性能监控与故障排查一节做了内容整理. 关于导图中的两部分内容还是希望大家能够亲自测试体验下,在网上也有不少的文章介绍,这里摘录几篇个人认为不错的文章,供参考: jstat/jinfo/jstack/jmap命令行工具使用详细介绍 VisualVM 官网介绍及使用说明 使用 VisualVM 进行性能分析及调优 使用VisualVm监控远程Linux服务器java进程 由于在 linux 服务器上面,使用远程

Kubernetes之kubectl常用命令使用指南:2:故障排查

kubectl是一个用于操作kubernetes集群的命令行接口,通过利用kubectl的各种命令可以实现各种功能,是在使用kubernetes中非常常用的工具.这里我们会通过一些简单的实例来展现其中一些高频命令的使用方法. 更为重要的是这些命令使用的场景以及能够解决什么样的问题.上篇文章我们介绍了创建和删除相关的几条命令,这篇文章我们来看一下出现问题时最常用的另外九条命令. 常用命令 kubectl故障排查相关,本文将会简单介绍一下如下命令 项番 命令 说明 No.1 version 显示客户

4核服务器cpu使用率10%负载飙到23.5故障排查

遇到一个故障,一台4核服务器cpu利用率是10%负载却飙到23,先看下问题现场,截图如下:...... 浏览全部请点击运维网咖社地址:4核服务器cpu使用率10%负载飙到23.5故障排查