You are on page 1of 10

Linux性能工具大全

查询域名的IP:nslookup(name server lookup)

Server 和 Address 是DNS 服务器


(端口号53)
非权威应答(Non-authoritative
answer)意味着answer来自于其
他服务器的缓存,而不是权威的
Baidu DNS服务器。
缓存会根据 ttl(Time to Live)的
值定时的进行更新。
包的路由路径:traceroute
网络是否互通:ping
网络是否互通:ping

$ ping -c 5 -i 2 www.baidu.com # ping 5次,间隔时间为2秒


网络接口:ifconfig
网络链接与端口:netstat
netstat -a # 列出所有端口
netstat -at # 列出所有tcp端口
netstat -au # 列出所有udp端口
netstat -nl # 只列出所有监听端口
netstat -tl # 只列出所有监听 tcp 端口
netstat -ul # 只列出所有监听 udp 端口
netstat -tunlp|grep 端口 # 查看占用端口号的进程,tcp, udp, n(全
部数字,不用别名), l监听,p进程信息
ip:多功能的网络命令(ifconfig,route,arp,netstat…)

$ ip addr #查看IP地址
$ ip addr del 192.168.17.30/24 dev eth0 # 删除IP地址
ip:多功能的网络命令

$ ip –s link # 显示网络接口的统计
ip:多功能的网络命令

RX和TX显示了接收和发送了多少数据。
bytes:表示已接收/发送的数据字节数 packets:表示已接收/发送的数据报数目errors:
表示在接收/发送时出现的错误次数,包括 too-long-frames 错误
Ring Buffer 溢出错误,crc 校验错误,帧同步错误,fifo overruns 以及 missed pkg 等等。
dropped:由于资源不足而丢弃的数据包总数
overrun:表示在接收数据包时,因为系统出现错误或系统反应太慢而导致丢包的数目
mcast:收到的组播数据包总数
carrier:表示物理连接出错的次数
collsns:表示出现以太冲突的次数

You might also like