Ethtool eth0 View the settings of the eth0 corresponding network card
Ethtool-i eth0 View driver information for eth0 NIC
ethtool-s eth0 viewing network card statistics
Ethtool-s eth0 speed of duplex full Autoneg off to turn off auto-negotiation, set the network card to 100Mbps fully duplex mode
Ethtool-s eth0 speed Duplex half Autoneg off
The above modifications are only valid for the current session, and the original settings are restored after the system restarts. To make the modified settings still valid after the system restarts or after the network is turned on, you must add the appropriate options to the etftool_opts line of the/etc/sysconfig/network-scripts/ifcfg-eth0 file
Ethtool_opts= "Speed of Deplex full Autoneg off"
If the NIC model is very old, you can use Mii-tool to view it accordingly.
Mii-tool eth0 Display the negotiation rate and connection status of the video card
Mii-tool-v eth0 Display the detailed settings of the NIC
The netstat command provides a way to obtain network interface statistics
Netstat-i getting Eth0 Network interface statistics
Netstat-ic Refresh once per second
You can watch the netstat-i with watch.
Network-related partial control scripts and configuration files are located in the/etc/sysconfig/network-scripts directory
/usr/share/doc/initscripts-*/sysconfig.txt file records netscripts related information
Script/etc/init.d/network is responsible for starting the configured network-scripts file
Service Start Stop Restart network interface
Service Network Stop
Service Network start
Service Network restart
Service network status to view the state of the Web interface
Chkconfig can set the network interface to self-boot when booting
Chkconfig Network on Start-Up Networking interface
Chkconfig--list Network View networking switch conditions at different network levels
When a system contains multiple network interfaces, you can use Ifdown ifup to close or open an interface
Ifdown eth0
Ifup eth0
Ifconfig command to view the address of the NIC MAC address and TCP/IP connection
Ifconfig eth0
The IP command not only displays information about the network interface, but also changes the network device, routing, IP tunneling settings
Lspci | Grep-i Wireless can see the model of the PCI wireless network card
Iwconfig viewing and modifying the wireless card interface information
Hostname View native DNS hostnames throughout
Hostname-s View native hostname abbreviation
hostname-d Viewing native domain names
DnsDomainName Viewing native domain names
Hostname name sets the native host name
Check for network failure
IP route checks the default gateway in the actual routing table
Ping the IP address of the default gateway to determine if the gateway's IP layer is connected
--Check the Address Resolution Protocol
Arp-v the ARP cache entry by host list
ARP-VN listing ARP cache entries by IP address
arp-d IP Address Delete an entry in the ARP cache
Arp-s IP Address MAC address to add entries to the ARP cache
IP neighbour can also achieve these functions
--track the routing to the host
Traceroute Address
Traceroute-i using ICMP packet tracing
TRACEROUTE-T using TCP Message Tracking
Traceroute-p port number is connected by default 80
Traceroute-n turn off name resolution when tracing
Tracepath addresses use UDP to track routes
Route Display native routing table information
Route-n Show routing table, do not do DNS resolution
The route add default GW 10.0.0.2 adds 10.0.0.2 as the Defaults gateway
Route add-net 192.168.0.0 netmask 255.255.255.0 ETH0/GW 10.0.0.100 Add new routes to the network by specifying a network port or gateway IP address
Route del-net 193.168.0.0 netmask 255.255.255.0 Delete route
Linux Management Network Connection instructions