13) How to use iperf for bidirectional testing of independent network ports under the same network segment in linux system?

 

After the network is built, it is necessary to test and verify the performance data of the network, and use iperf tools to check the performance of the network.

13) How to use iperf for bidirectional testing of independent network ports under the same network segment in linux system?插图Tmei trading

Use iperf to conduct two-way traffic test at PC1 and PC0;

Eth2 performs two-way traffic streaming on Eth0;
Eth3 performs bidirectional traffic flow on Eth1;


PC0 as the server:
#iperf -s -p 5555 (specifies the port number used by the process)
#iperf -s -p 5566
#iperf -s -p 6666
#iperf -s -p 6677

Set routing binding:

PC1 Settings: # IP RouteAdd10.10.111 (IP address of the opposite terminal Eth0) Deveth2 (port name used by PC1 to call the corresponding port).
PC1 Settings: # IP RouteAdd10.10.112 (IP address of the opposite terminal Eth0) Devet H1 (the port name used by PC1 to call the corresponding port).

After the execution, the iperf is executed to direct the outlet flow:

#iperf -B 10.10.10.222 (specify the exit of PC1)-c10.10.111 (the entrance of PC0) -i x (set how often to display) -t x (set how long to test) -p 5555 (specify the port number used by the process) (flow from PC1 to PC0).
#iperf -B 10.10.10.222 (specify the exit of PC1)-c10.10.111 (the entrance of PC0) -i x (set how often to display) -t x (set how long to test) -p 5566 (specify the port number used by the process) -R (set the traffic from PC0)

#iperf -B 10.10.10.223 (specify the exit of PC1)-c10.10.112 (the entrance of PC0) -i x (set how often to display) -t x (set how long to test) -p 6666 (specify the port number used by the process) (flow from PC1 to PC0).
#iperf -B 10.10.10.223 (specify the exit of PC1)-c10.10.112 (the entrance of PC0) -i x (set how often to display) -t x (set how long to test) -p 6677 (specify the port number used by the process) -R (set the traffic from PC0)

 

And so on, but when multiple network ports need to be tested independently, the corresponding settings and tests should be carried out.