GBase 8a通过corosync-cfgtool查看本地选中的IP和nodeid

如果本机有多个IP,如下命令可以查看被选中的IP和nodeid。

[root@gbase_rh7_002 gcinstall]# corosync-cfgtool -s
Printing ring status.
Local node ID 1711407114
RING ID 0
        id      = 10.0.2.102
        status  = ring 0 active with no faults

如果Local node ID为正数,则Local node ID即为node id;
如果Local Node ID值为负数,则计算Local node ID+2^32。   
例如:
[root@localhost gcware]# corosync-cfgtool -s
Printing ring status.
Local node ID -1540419412
RING ID 0
        id      = 172.16.47.164
        status  = ring 0 active with no faults
则node id = 2^32-1540419412=4294967296-1540419412=2754547884。

参考