2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-08-21 18:50:28 +00:00

Change the usage for xcatstat;

Filter off the lo in the output;
This commit is contained in:
wangxiaopeng
2016-01-21 03:03:24 -05:00
parent 2384541fda
commit 0a3acec252

View File

@@ -23,7 +23,7 @@ my $SELECTOR;
$::USAGE = "Usage: xcatstat [noderange]
This command can be used to display the OS and network interface status for compute nodes which are managed by current xCAT MN.
This command can be used to display the OS and network interface status (On or Off status) for compute nodes which are managed by current xCAT MN.
The output is similar as the CSM command csmstat: /opt/csm/bin/csmstat -d: -s Status,Network-Interfaces
@@ -40,9 +40,9 @@ Example:
Get the status of three nodes: rh6mn,rh7mn,rh7cn
# ./xcatstat rh6mn,rh7mn,rh7cn
# Hostname:Status:Network-Interfaces:
rh6mn:1:eth0-1:lo-1:
rh6mn:1:eth0-1:
rh7cn:0:127:
rh7mn:1:docker0-2:eth0-1:lo-1:
rh7mn:1:docker0-2:eth0-1:
Author: Wang, Xiao Peng\n";
@@ -153,7 +153,7 @@ if ($DILIMITER) {
if (defined($nodestat{$node}{netif})) {
foreach my $if (sort (keys %{ $nodestat{$node}{netif} })) {
if ($if =~ /^lo\d/) {
if ($if =~ /^lo[\d]*/) {
next;
}
if ($nodestat{$node}{netif}{$if} eq "on") {