标签:fastdfs
1、故障描述:
配置好fdfs后,测试上传一个/etc/passwd的文件,发现有报错信息(之前已经重启过FastDFS相关的服务过了)
[root@Docker-01 fdfs]# fdfs_upload_file /etc/fdfs/client.conf /etc/passwd [2016-04-03 22:40:56] ERROR - file: tracker_proto.c, line: 48, server: 192.168.1.136:22122, response status 2 != 0 tracker_query_storage fail, error no: 2, error info: No such file or directory
2、检查trackerd.log发现如下报错:
[2016-04-03 23:14:08] ERROR - file: connection_pool.c, line: 110, connect to 192.168.1.137:22122 fail, errno: 113, error info: No route to host [2016-04-03 23:14:08] ERROR - file: tracker_mem.c, line: 4297, get sys files from other trackers fail, errno: 113 [2016-04-03 23:14:38] ERROR - file: connection_pool.c, line: 110, connect to 192.168.1.137:22122 fail, errno: 113, error info: No route to host [2016-04-03 23:14:38] ERROR - file: tracker_mem.c, line: 4297, get sys files from other trackers fail, errno: 113 [2016-04-03 22:34:44] ERROR - file: tracker_proto.c, line: 48, server: 192.168.1.136:22122, response status 11 != 0 [2016-04-03 22:35:14] INFO - file: tracker_client_thread.c, line: 310, successfully connect to tracker server 192.168.1.136:22122, as a tracker client, my ip is 192.168.1.136
3、解决方法:
1、关闭防火墙:sudo systemctl stop firewalld.service 2、关闭开机启动:sudo systemctl disable firewalld.service 备注:需要在几个节点上分别执行
4、重新上传:
[root@Docker-01 logs]# fdfs_upload_file /etc/fdfs/client.conf /etc/shells group1/M00/00/00/wKgBiFcBNwKAM6FxAAAAXzJ-yp83094006 [root@Docker-02 fdfs]# fdfs_upload_file /etc/fdfs/client.conf /etc/passwd group1/M00/00/00/wKgBiFcBNCSAP497AAAIfEUcfXc0851118
5、在Docker-01上进行测试:
[root@Docker-01 00]# dd if=/dev/zero of=/tmp/tmp.iso bs=1M count=512 记录了512+0 的读入 记录了512+0 的写出 536870912字节(537 MB)已复制,14.5861 秒,36.8 MB/秒 [root@Docker-01 00]# fdfs_upload_file /etc/fdfs/client.conf /tmp/tmp.iso group1/M00/00/00/wKgBiVcBOV2AGUh5IAAAALBf1UE892.iso [root@Docker-01 00]# cd /data/fdfs_storage/ base/ store/ [root@Docker-01 00]# cd /data/fdfs_storage/store/data/ Display all 256 possibilities? (y or n) [root@Docker-01 00]# cd /data/fdfs_storage/store/data/00/00/ [root@Docker-01 00]# ll 总用量 524296 -rw-r--r--. 1 root root 2172 4月 3 23:17 wKgBiFcBNCSAP497AAAIfEUcfXc0851118 -rw-r--r--. 1 root root 95 4月 3 23:30 wKgBiFcBNwKAM6FxAAAAXzJ-yp83094006 -rw-r--r--. 1 root root菜单、 536870912 4月 3 23:40 wKgBiVcBOV2AGUh5IAAAALBf1UE892.iso [root@Docker-01 00]# du -sh wKgBiVcBOV2AGUh5IAAAALBf1UE892.iso 512MwKgBiVcBOV2AGUh5IAAAALBf1UE892.iso [root@Docker-01 00]# pwd /data/fdfs_storage/store/data/00/00
6、在Docker-02上进行测试:
[root@Docker-02 fdfs]# cd /data/fdfs_storage/store/data/00/00 [root@Docker-02 00]# ll 总用量 524296 -rw-r--r--. 1 root root 2172 4月 3 23:17 wKgBiFcBNCSAP497AAAIfEUcfXc0851118 -rw-r--r--. 1 root root 95 4月 3 23:30 wKgBiFcBNwKAM6FxAAAAXzJ-yp83094006 -rw-r--r--. 1 root root 536870912 4月 3 23:40 wKgBiVcBOV2AGUh5IAAAALBf1UE892.iso [root@Docker-02 00]# du -sh wKgBiVcBOV2AGUh5IAAAALBf1UE892.iso 512MwKgBiVcBOV2AGUh5IAAAALBf1UE892.iso [root@Docker-02 00]#
本文出自 “冰冻vs西瓜” 博客,请务必保留此出处http://molewan.blog.51cto.com/287340/1760341
标签:fastdfs
原文地址:http://molewan.blog.51cto.com/287340/1760341