Main Menu

Search

Showing posts with label IB Commands. Show all posts
Showing posts with label IB Commands. Show all posts

INFINIBAND: "rds-ping" & "rds-stress" Command Tests To Troubleshoot Network Communication Issues On Linux Hosts (How To Doc)

"rds-ping" & "rds-stress" commands can be used for troubleshooting Infiniband network issues on Linux hosts. By running tests using "rds-ping" & "rds-stress" commands we can narrow down whether the networking problem is at the Linux OS networking layer or whether the issue is at Infiniband Networking level itself. Because "rds-ping" & "rds-stress" commands will test the reachability of the IP addresses by sending packets over RDS sockets and bypassing Linux OS level tcp rules & route tables.

If actual ping to the hosts/IPs is not working and "rds-ping" & "rds-stress" commands works, then the issue may be at Linux OS network level. If ping and "rds-ping" & "rds-stress" commands both are not working then the issue may be at the Infiniband network layer.

Below are detailed steps for doing "rds-ping" & "rds-stress" tests.

"rds-ping" Tests

1. Identify the IP address of target Linux host to which you want to do rds-ping test.

2. Login to source Linux host as root user and identify interface IP address (in same subnet as target linux host) using which rds-ping test has to be done to the target Linux host.

3. On Linux source host run rds-ping command as follows to do rds test to target host.

rds-ping -c <count> -I <source IP address> <target Linux host IP address>

For e.g. if source IP address is 192.168.2.96 and target IP address is 192.168.2.114, number of ping counts is 3, then your rds-ping command on source Linux host looks as follows:
# rds-ping -c 3 -I 192.168.2.96 192.168.2.114

Below is example snippet of above command.
# rds-ping -c 3 -I 192.168.2.96 192.168.2.114
   1: 142 usec
   2: 167 usec
   3: 110 usec
  
As we can see from above command we see response coming back to the rds-ping.

"rds-stress" Tests

1. Login to the target List host as root user to which you want to do rds tests from source Linux host. Run below command.

rds-stress

You will see output as follows that the target host is listening for connection on port 4000
# rds-stress
waiting for incoming connection on 0.0.0.0:4000

2. Login to source Linux host and connect to target Linux host in above step 1 using rds-stress command as follows:

rds-stress -s <IP address of target VM> -p 4000 -t 1 -D <number of bytes>

In above command replace IP address with the IP address of target Linux host in above step 1. For e.g. if you ran rds-stress between target host with IP 192.168.2.96 and source host with IP 192.168.2.240 and sent 500000 rdma packets from source, your rds commands and outputs on source and target will look as follows:

source:

~]# rds-stress -s 192.168.2.96 -p 4000 -t 1 -D 500000
connecting to 192.168.2.96:4000
negotiated options, tasks will start in 2 seconds
Starting up....
tsks   tx/s   rx/s  tx+rx K/s    mbi K/s    mbo K/s tx us/c   rtt us cpu %
   1   3434   3436    7292.05 1677105.22 1677105.22   37.75   286.29 -1.00
   1   3436   3428    7285.58 1675617.04 1675617.04   38.20   286.30 -1.00
   1   3451   3444    7318.36 1683398.48 1682910.25   37.18   285.21 -1.00
   1   3441   3441    7304.68 1680009.46 1680009.46   37.42   286.42 -1.00

target:
~]# rds-stress
waiting for incoming connection on 0.0.0.0:4000
accepted connection from 192.168.2.240:61630 on 192.168.2.96:4000
negotiated options, tasks will start in 2 seconds
Starting up....
tsks   tx/s   rx/s  tx+rx K/s    mbi K/s    mbo K/s tx us/c   rtt us cpu %
   1   3439   3437    7291.51 1677468.07 1676492.52   42.69   285.65 -1.00
   1   3432   3440    7287.16 1675979.62 1675979.62   41.86   286.46 -1.00
   1   3447   3454    7317.88 1682801.69 1683289.46   41.40   285.27 -1.00
   1   3444   3444    7304.10 1679876.75 1679876.75   41.20   285.69 -1.00
---------------------------------------------
   1   3436   3440    7300.16 1679031.54 1678909.60   41.83   286.06 -1.00  (average)

As you can see from above "rds-stress" command outputs the communication between both the Linux hosts is happening without any issues.




Products to which Article Applies

All Linux hosts using Infiniband.

Additional Reference

https://linux.die.net/man/1/rds-ping
https://linux.die.net/man/1/rds-stress


INFINIBAND: How To Use "ibping" Command To Troubleshooting Infiniband (IB) Network Issues?

"ibping" command will be helpful to troubleshooting Infiniband network issues between two or more hosts. "ibping" command is a client-server command, one one host ibping is executed as a server (using -S option) where it listens for pings from clients. On other host ibping is executed client pinging the server node using LID. Output is similar to the Internet Protocol ping command. The ping repeats every second, until the Ctrl-C key combination exits on the server.

Below are steps to do ibping tests between two hosts.

1) Gather the Port GUID's and Base LIDs of IB ports on both the hosts using below command.

ibstat | egrep "Port|Base"

Below is example output of above command.
    Port 1:
                Base lid: 18
                Port GUID: 0xXXXXXX5ff9e65a9d
        Port 2:
                Base lid: 19
                Port GUID: 0xXXXXXX5ff9e65a9e

2) On on one host run ibping as Server using -S option as follows:
ibping -S -P <IB Port> -d

In above command change IB Port with the IB port number on which you want to do ping test. -d is the debug messages flag.

For e.g. if you want to do ping test on Port 1, your server host side command looks as follows:

ibping -S -P 1 -d

3) Now on other host run the ibping command as follows to connect to Base LID of host in above step 2 where ibping is running in server mode. Replace the IB port to IB port number on client host which you want to use to ping ibping server host.

ibping -P <IB Port> <Base LID of ibping server>

For e.g. if Base LID of ibping server host is 19 and you want to do ibping test using Port 1 of cient host, your command looks as follows:

ibping -P 1 19

Below are example outputs from ibping server and ibping client hosts

On ibping client side we see resonses from ibpingserverhost as follows if there are no issues.

#ibping -P 1 19
Pong from ibpingserverhost.testing.com (Lid 19): time 0.358 ms
Pong from ibpingserverhost.testing.com (Lid 19): time 0.479 ms
Pong from ibpingserverhost.testing.com (Lid 19): time 0.390 ms
Pong from ibpingserverhost.testing.com (Lid 19): time 0.500 ms
Pong from ibpingserverhost.testing.com (Lid 19): time 0.377 ms

On Server side we see ibping responses debug messages as follows if there are no issues.

# ibping -S -P 2 -d
ibdebug: [14359] ibping_serv: starting to serve...
ibdebug: [14359] ibping_serv: Pong: ibpingserverhost.testing.com
ibwarn: [14359] mad_respond_via: dest Lid 20
ibwarn: [14359] mad_respond_via: qp 0x1 class 0x32 method 129 attr 0x0 mod 0x0 datasz 0 off 0 qkey 80010000
ibdebug: [14359] ibping_serv: Pong: ibpingserverhost.testing.com
ibwarn: [14359] mad_respond_via: dest Lid 20
ibwarn: [14359] mad_respond_via: qp 0x1 class 0x32 method 129 attr 0x0 mod 0x0 datasz 0 off 0 qkey 80010000
ibdebug: [14359] ibping_serv: Pong: ibpingserverhost.testing.com
ibwarn: [14359] mad_respond_via: dest Lid 20
ibwarn: [14359] mad_respond_via: qp 0x1 class 0x32 method 129 attr 0x0 mod 0x0 datasz 0 off 0 qkey 80010000

NOTE: Please note that if you started ibping server connection on Port 1 and if you are tring to connect to ibping server on Port 2 Base LID, the test will fail.

Products to which Article Applies

All hosts using Infiniband.

Additional Reference

https://docs.oracle.com/cd/E19632-01/835-0783-03/bbggcjji.html

INFINIBAND: How To Validate If any Infiniband (IB) Switch Ports Have Errors/Failures or Issues? ("listlinkup" Command)

Below "listlinkup" command can be used on IB switch to check if any of the Infiniband Switch ports have errors/failures or issues.
listlinkup | egrep -i "error|bad"

If there are any issues on any of the Switch ports you may be AutomaticHighErrorRate or AutomaticBadSpeedOrWidth errors as follows. AutomaticHighError or BadSwitch errors may happen due to lose cabling, bad cable or bad switch port etc.
Connector  0A Present<->  Switch Port 20 down (AutomaticHighErrorRate)
Connector  0A Present<->  Switch Port 8 down (AutomaticBadSpeedOrWidth)


Products to which Article Applies

Infiniband Switches

Additional Reference

https://docs.oracle.com/cd/E36265_01/html/E36266/z40001002006287.html
 

INFINIBAND: How To Delete VNIC on Infiniband (IB) Switch? ("deletevnic" Command)

Below is command to delete VNIC on IB Switches.
deletevnic <VNIC Port> <VNIC ID>

For e.g. if you have VNIC's as follows which you want to delete.
178 UP          N 161XXXXXXXBBCA95        testnode EL-C 192.168.11.6       0000 00:14:XX:XX:YY:D3 1111 0x800a 0A-ETH-1

Then your deletevnic command will look as follows:

deletevnic 0A-ETH-1 178


Products to which Article Applies

Infiniband Switches

Additional Reference

https://docs.oracle.com/cd/E19671-01/835-0793-03/z400004d2063516.html

 

INFINIBAND: How To Check Status Of Infiniband Links On the Nodes/Hosts Using Infiniband Network? ("iblinkinfo" Command)

Below iblinkinfo command can be used.
iblinkinfo | egrep "HCA|PCIe"

Below is example snippet of above command from Exalogic rack using Infiniband networks. testingcn01-cn08 are Linux nodes and testingsn01 and sn02 are Storage nodes with IB HCA/PCIe cards. Below output shows both the links to all the linux nodes and storage heads are up.

# iblinkinfo | egrep "HCA|PCIe"
CA: testingsn01 PCIe 1:
CA: testingsn02 PCIe 1:
CA: testingcn08 EL-C 192.168.5.108 HCA-1:
          12    5[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      21    2[  ] "testingcn02 EL-C 192.168.5.102 HCA-1" ( )
          12    6[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      19    2[  ] "testingcn01 EL-C 192.168.5.101 HCA-1" ( )
          12    7[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      30    2[  ] "testingcn04 EL-C 192.168.5.104 HCA-1" ( )
          12    8[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      28    2[  ] "testingcn03 EL-C 192.168.5.103 HCA-1" ( )
          12    9[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       6    2[  ] "testingcn06 EL-C 192.168.5.106 HCA-1" ( )
          12   10[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      13    2[  ] "testingcn05 EL-C 192.168.5.105 HCA-1" ( )
          12   11[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      17    2[  ] "testingcn07 EL-C 192.168.5.107 HCA-1" ( )
          12   18[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      15    2[  ] "testingcn08 EL-C 192.168.5.108 HCA-1" ( )
          12   31[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       4    2[  ] "testingsn02 PCIe 1" ( )
          12   32[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       2    2[  ] "testingsn01 PCIe 1" ( )
CA: testingcn07 EL-C 192.168.5.107 HCA-1:
CA: testingcn05 EL-C 192.168.5.105 HCA-1:
CA: testingcn06 EL-C 192.168.5.106 HCA-1:
CA: testingcn03 EL-C 192.168.5.103 HCA-1:
CA: testingcn04 EL-C 192.168.5.104 HCA-1:
CA: testingcn02 EL-C 192.168.5.102 HCA-1:
          27    5[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      20    1[  ] "testingcn02 EL-C 192.168.5.102 HCA-1" ( )
          27    6[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      18    1[  ] "testingcn01 EL-C 192.168.5.101 HCA-1" ( )
          27    7[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      29    1[  ] "testingcn04 EL-C 192.168.5.104 HCA-1" ( )
          27    8[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      22    1[  ] "testingcn03 EL-C 192.168.5.103 HCA-1" ( )
          27    9[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       5    1[  ] "testingcn06 EL-C 192.168.5.106 HCA-1" ( )
          27   10[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       7    1[  ] "testingcn05 EL-C 192.168.5.105 HCA-1" ( )
          27   11[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      16    1[  ] "testingcn07 EL-C 192.168.5.107 HCA-1" ( )
          27   18[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>      14    1[  ] "testingcn08 EL-C 192.168.5.108 HCA-1" ( )
          27   31[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       3    1[  ] "testingsn02 PCIe 1" ( )
          27   32[  ] ==( 4X          10.0 Gbps Active/  LinkUp)==>       1    1[  ] "testingsn01 PCIe 1" ( )
CA: testingcn01 EL-C 192.168.5.101 HCA-1:



Products to which Article Applies

All Hosts using Infiniband Fabric, Oracle Engineered Systems using Infiniband Fabric.

Additional Reference

https://docs.oracle.com/cd/E86824_01/html/E54764/iblinkinfo-1m.html

 

INFINIBAND: "ibstat" Command To Check Infiniband (IB) HCA Ports Status, Node/Port GUIDs, Firmware Version, LID's etc. (How To Doc)

ibstat command can be used on host to check IB HCA ports status, Node/Port GUIDs, Firmware Version, LID's etc.

Below is example output of "ibstat" command.
# ibstat
CA 'mlx4_0'
        CA type: MT4099
        Number of ports: 2
        Firmware version: 2.11.1282
        Hardware version: 0
        Node GUID: 0x00ZZZZZ001432c50
        System image GUID: 0x00ZZZZZ001432c53
        Port 1:
                State: Active
                Physical state: LinkUp
                Rate: 40
                Base lid: 15
                LMC: 0
                SM lid: 109
                Capability mask: 0x02514868
                Port GUID: 0x00ZZZZZ001432c51
                Link layer: IB
        Port 2:
                State: Active
                Physical state: LinkUp
                Rate: 40
                Base lid: 16
                LMC: 0
                SM lid: 109
                Capability mask: 0x02514868
                Port GUID: 0x00ZZZZZ001432c52
                Link layer: IB

Products to which Article Applies
All Operating systems using Infiniband Fabric.

Additional Reference