This article introduces the management of Linux system network performance skills, mainly introduces the route, Netstat, tcpdump Three network management test tools and the implementation of the function.
Route
When configuring a network, specify the path that the package will go through when the packet is received. In a Linux system, a command route is provided, which sets a static route for the NIC configured by the Ifconfig command. This setup work is usually introduced in/etc/rc.d/rc.inet1 and is performed at system boot time.
We illustrate how to use the route command with several examples:
Route Add-net 127.0.0.0
This command adds a route to the routing table that specifies the address or network. Note that at this point the network is a Class A address, the mask is set to 255.0.0.0, and the newly added entry is connected to the LO device.
Route add-net xxx.xxx.xxx.xxx netmask 255.255.255.0 Dev eth0
This command adds a route to the host with the IP address xxx.xxx.xxx.xxx, and its netmask is set to 255.255.255.0.
Route del-net xxx.xxx.xxx.xxx
This command deletes the route to xxx.xxx.xxx.xxx this network.
The route command also makes it easy to manage routing information for the entire network, and its output is the routing table for the network. As shown below:
[Root@lee/root] #route
Kernel IP routing table
destination Gateway genmask Flags Metric Ref use Iface
10 10.8.224 * 255.255.255.255 UH 0 0 0 eth0
10.10.8.0 * 255.255.255.0 u 0 0 0 eth0
127.0.0.0 * 255.0.0.0 u 0 0 0 Lo
default dgc8.njupt.edu 0.0.0.0 ug 0 0 0 eth0
default dgc8.njupt.edu 0.0.0.0 UG 1 0 0 eth0
[root@lee /root]#