mount.ocfs2 error:o2net_connect_expired:1585
如题所示的错误发生在“mount.ocfs2”的阶段,该阶段的正常输出如下:
1 2 |
[root@oel3 ~]# mount.ocfs2 -o datavolume,nointr /dev/sdb1 /ocfs2/ [root@oel3 ~]# |
它的具体发生场景是:向已有的OCFS2节点新增节点的时候。
关于这个错误需要注意以下几点:
在第三节点(新增节点)执行mount.ocfs2操作之前,应该确认节点一、节点二(已有OCFS2集群节点)的内存文件中是否已经识别到了节点三,如下:
1 2 3 4 5 6 |
[root@oel1 ~]# ll /sys/kernel/config/cluster/ocfs2/node/ total 0 drwxr-xr-x 2 root root 0 Sep 19 10:30 oel1 drwxr-xr-x 2 root root 0 Sep 19 10:30 oel2 drwxr-xr-x 2 root root 0 Sep 19 10:30 oel3 [root@oel1 ~]# |
如果已有的OCFS2集群的各个节点上没有识别到新增节点,那么,新增节点做mount.ocfs2的时候很可能会遇到如下的错误:
1 2 3 |
[root@oel3 node]# mount -t ocfs2 /dev/sdb1 /ocfs2/ mount.ocfs2: Transport endpoint is not connected while mounting /dev/sdb1 on /ocfs2/. Check 'dmesg' for more information on this error. [root@oel3 node]# |
该报错的后台日志为:
(/var/log/message)
1 2 3 4 5 6 7 8 9 10 |
Sep 19 10:04:07 oel3 kernel: o2net: connected to node oel1 (num 0) at 192.168.119.131:7777 Sep 19 10:04:37 oel3 kernel: (15133,0):o2net_connect_expired:1585 ERROR: no connection established with node 1 after 30.0 seconds, giving up and returning errors. Sep 19 10:04:37 oel3 kernel: (15443,0):dlm_request_join:901 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: (15443,0):dlm_try_to_join_domain:1049 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: (15443,0):dlm_join_domain:1321 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: (15443,0):dlm_register_domain:1514 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: (15443,0):ocfs2_dlm_init:2024 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: (15443,0):ocfs2_mount_volume:1133 ERROR: status = -107 Sep 19 10:04:37 oel3 kernel: ocfs2: Unmounting device (8,17) on (node 2) Sep 19 10:04:37 oel3 kernel: o2net: no longer connected to node oel1 (num 0) at 192.168.119.131:7777 |
Linux会在o2cb服务start的时候刷新“/sys/kernel/config/cluster/ocfs2/node/”,所以,如果节点一、二的“../node”下没有新增节点的时候,重启“/etc/init.d/{ocfs2,o2cb}”即可。
确认识别到了新增节点后,新增节点上再次执行“mount.ocfs2”就能成功挂载。
——————————————————————————————————————
Ending。