https://www.cnblogs.com/lyq863987322/p/8257110.html
随笔 - 53 文章 - 0 评论 - 24
来一波Linux中查看cpu、磁盘、内存、网络的命令
目录
转载请注明出处。
如果想远程管理服务器就有远程管理卡,比如Dell idRAC,HP ILO,IBM IMM
查看硬件的温度/风扇转速,电脑有撸大师,服务器就有ipmitool。使用ipmitool实现对服务器的命令行远程管理
yum -y install OpenIPMI ipmitool #->IPMI在物理机可以成功,虚拟机不行 [root@KVM ~]# ipmitool sdr type Temperature Temp | 01h | ns | 3.1 | Disabled Temp | 02h | ns | 3.2 | Disabled Temp | 05h | ns | 10.1 | Disabled Temp | 06h | ns | 10.2 | Disabled Ambient Temp | 0Eh | ok | 7.1 | 22 degrees C Planar Temp | 0Fh | ns | 7.1 | Disabled IOH THERMTRIP | 5Dh | ns | 7.1 | Disabled CPU Temp Interf | 76h | ns | 7.1 | Disabled Temp | 0Ah | ns | 8.1 | Disabled Temp | 0Bh | ns | 8.1 | Disabled Temp | 0Ch | ns | 8.1 | Disabled
查看cpu方面
想知道了cpu性能好不好、忙不忙可以用lscpu、uptime、top、htop。
实例
cpu负载:
[root@m02 ~]# uptime 09:11:40 up 18:35, 1 user, load average: 0.00, 0.05, 0.05
查看内存方面
内存够不够可以用free
[root@cache01 ~]# free -h total used free shared buff/cache available Mem: 472M 105M 93M 4.8M 272M 325M Swap: 1.0G 0B 1.0G
查看磁盘相关
磁盘剩多少写的快不快可以用df、dd、iotop
实例
查看网络方面
网络太卡找iftop, nethogs
nethogs:
iftop: