1.Linux主机性能查询
一、CPU性能查询
top #综合查询
sar #查看cpu近期使用的数据
vmstat
二、内存使用查询
free -m
三、io查询
iostat
四、网卡性能查询
[root@localhost ~]# ifconfig ens33ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.0.61 netmask 255.255.255.0 broadcast 192.168.0.255
inet6 fe80::7580:f510:72dc:6d0a prefixlen 64 scopeid 0x20
ether 00:50:56:b6:14:60 txqueuelen 1000 (Ethernet)
RX packets 196678222 bytes 34307181199 (31.9 GiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 187359243 bytes 30052140832 (27.9 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
[root@P-NC1LNCJAPP01 ~]# ethtool bond0
Settings for bond0:
Supported ports: [ ]
Supported link modes: Not reported
Supported pause frame use: No
Supports auto-negotiation: No
Supported FEC modes: Not reported
Advertised link modes: Not reported
Advertised pause frame use: No
Advertised auto-negotiation: No
Advertised FEC modes: Not reported
Speed: 2000Mb/s
Duplex: Full
Port: Other
PHYAD: 0
Transceiver: internal
Auto-negotiation: off
Link detected: yes
[root@P-NC1LNCJAPP01 ~]# sar -n DEV 1
Linux 3.10.0-1127.el7.x86_64 (P-NC1LNCJAPP01) 2021年09月28日 _x86_64_ (8 CPU)
09时50分07秒 IFACE rxpck/s txpck/s rxkB/s txkB/s rxcmp/s txcmp/s rxmcst/s
09时50分08秒 eno5 1.00 1472.00 0.06 256.56 0.00 0.00 0.00
09时50分08秒 eno6 1552.00 0.00 418.15 0.00 0.00 0.00 0.00
09时50分08秒 eno7 0.00 0.00 0.00 0.00 0.00 0.00 0.00
09时50分08秒 eno8 0.00 0.00 0.00 0.00 0.00 0.00 0.00
09时50分08秒 bond0 1553.00 1472.00 418.21 256.56 0.00 0.00 0.00
09时50分08秒 lo 0.00 0.00 0.00 0.00 0.00 0.00 0.00
09时50分08秒 enp1s0f4u4 0.00 0.00 0.00 0.00 0.00 0.00 0.00
09时50分08秒 docker0 0.00 0.00 0.00 0.00 0.00 0.00 0.00
rxpck/s:每秒钟接收的数据包
txpck/s:每秒钟发送的数据包
rxbyt/s:每秒钟接收的字节数
txbyt/s:每秒钟发送的字节数
rxcmp/s:每秒钟接收的压缩数据包
txcmp/s:每秒钟发送的压缩数据包
rxmcst/s:每秒钟接收的多播数据包
netstat -i
Iface MTU RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg
bond0 1500 6372180035 0 1160868 0 6308849615 0 0 0 BMmRU
docker0 1500 0 0 0 0 0 0 0 0 BMU
eno5 1500 741685195 0 0 0 6102158297 0 0 0 BMsRU
eno6 1500 5630494840 0 0 0 206691318 0 0 0 BMsRU
eno7 1500 0 0 0 0 0 0 0 0 BMsU
eno8 1500 0 0 0 0 0 0 0 0 BMsU
enp1s0f4u4 1500 0 0 0 0 0 0 0 0 BMRU
lo 65536 13252860 0 0 0 13252860 0 0 0 LRU
五、设备登录信息
last #查看用户登录信息
lastb #列出登入系统失败的用户相关信息
lastlog #显示系统中所有用最近的登录信息

浙公网安备 33010602011771号