Linux中如何查看各项性能指标?本篇文章重点为大家讲解一下Linux下查看性能指标具体方法,有需要的小伙伴可以参考一下。

硬盘查看命令df
硬盘查看命令df最常用参数是-h,以容易阅读的方式显示磁盘分区使用情况。
df -h

df -h /root/#以易读方式显示目录所在分区的使用情况

其它常用参数:
-a:显示所有文件系统
-B:指定显示时的块大小
-H:以1000字节为换算单位来显示
-i:显示索引字节信息
-k:只显示本地文件系统
-t:只显示指定类型的文件系统
-T:输出时显示文件系统类型
–sync:在取得磁盘使用信息前,先执行sync命令
内存情况的查询命令free常用参数:
-b:以Byte为单位显示内存使用情况
-k:以kb为单位显示内存使用情况
-m:以mb为单位显示内存使用情况
-g:以gb为单位显示内存使用情况

-t:显示内存使用总和
查看IO使用情况的命令iostat
需要安装sysstat软件包 参数:

-c:仅显示cpu的状态
-d:仅显示存储设备的状态,不可以和-c一起使用

-k:以KB大小显示读入读出的block信息

-t:显示日期

实时显示进程动态的命令toptop
能够实时显示系统中各个进程的资源占用状况

-d:改变显示的更新速度
-q:没有任何延迟的显示速度
-n:更新的次数,完成后就退出
查看进程信息的命令ps

查看端口使用情况的命令netstat

常用参数:
-a:显示所有连线中的socket
-p:显示正在使用socket的程序识别码和程序名称

-u:显示udp传输协议的连线状况
以上就是良许教程网为各位朋友分享的Linux系统相关内容。想要了解更多Linux相关知识记得关注公众号“良许Linux”,或扫描下方二维码进行关注,更多干货等着你 !
