linux的常用命令--ifconfig命令【持续补充ing】

ifconfig #查看本机网络/网卡配置的命令

例:ifconfig #通常的输出结果如下

eth0: flags=4163<UP,BROADCAST,RUNNING> mtu 1500
  inet 192.168.1.26 netmask 255.255.255.128 broadcast 10.9.68.127
  ether fa:12:3e:85:cc:aa txqueuelen 1000 (Ethernet)
  RX packets 14952827 bytes 3546535962 (3.3 GiB)
  RX errors 0 dropped 0 overruns 0 frame 0
  TX packets 18573930 bytes 7673469127 (7.1 GiB)
  TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

eth0:#网卡名称

inet 192.168.1.26 #IP地址

netmask 255.255.255.128 #网络掩码

broadcast 10.9.68.127 #网关地址

ether fa:12:3e:85:cc:aa #网卡物理地址

txqueuelen 1000 (Ethernet) #网卡类型,千兆网卡

注意:在windows系统下,我们用命令行查看网络信息,用的是ipconfig,和Linux的有一字之差哦。

猜你喜欢

转载自www.cnblogs.com/creasybear/p/11589028.html