关于Linux_系统资源监控_dmesg_free_uptime_uname

(系统资源查看命令-dmesg【查看系统内核资源信息】)->判断服务器的硬件状态
Comment:dmesg | grep CPU,指定查看cpu资源信息
(系统资源查看命令-free【查看内存使用状态】)
Comment: free [-b|-k|-m|-g]
  • 选项:
    • -b:以字节为单位显示
    • -k:以KB为单位显示,默认就是以KB为单位显示
    • -m:以MB为单位显示
    • -g:以GB为单位显示
(系统资源查看命令-cat /proc/cpuinfo【查看Cpu信息】)

(系统资源查看命令-uptime【查看OS平均负载信息】)

(系统资源查看命令-uname【查看当前内核信息】   内核版本)

 (系统资源查看命令-file /bin/ls 【判断当前系统的位数】)

(系统资源查看命令-lsb_release -a 【查看当前系统的发行版本】[ri'li:s]  发行版本)

(系统资源查看命令lsof)

  • lsof | more
    • # 查看OS中所有process调用的文件
  • lsof  /sbin/init
    • # 查看某个文件被哪个process调用 
  • lsof -c httpd
    • # 查看httpd process调用了哪些文件
  • lsof -u root
    • # 按照用户名,查看某用户的process调用的文件名
 
原文地址:https://www.cnblogs.com/mrchenyushen/p/8735385.html