常用OS获取信息命令

一、linux
#CPU信息(总核心数和型号)
 cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c

#物理CPU数及每颗物理CPU中核心数(可能有超线)
 cat /proc/cpuinfo | grep physical | uniq -c

#系统位数
 getconf LONG_BIT

#CPU是否支持64位运算(大于零就支持)
 cat /proc/cpuinfo | grep flags | grep ' lm ' | wc -l

#cpu完整信息(root)
 dmidecode | grep 'Processor Information'

#内存信息(各项)
 cat /proc/meminfo

#OS内核信息
 uname -a

#linux版本信息 
 cat /etc/issue | grep Linux

#机器型号(root)
 dmidecode | grep "Product Name" 

#网卡信息
 dmesg | grep -i eth

二、solaris
#查看CPU
 /usr/platform/sun4u/sbin/prtdiag –v|more
 或
  psrinfo -v
#查看内存 
 prtconf | grep 'Memory'
 /usr/platform/sun4u/sbin/prtdiag -v
#查看硬盘信息
 iostat -E

三、AIX

#物理cpu数 
1.prtconf

2.lsdev 
  lsdev -Cc processor

#逻辑cpu数 
3.bindprocessor 
  bindprocessor -q

4.vmstat

5.smtctl(root权限)

#查看内存
1.lsattr 
  lsdev -Cc memory

  lsattr -El L2cache0

  lsattr -El mem0

2.prtconf 
  prtconf|grep Memory|grep -v + 
 
3.vmstat 

4.topas 

#查看交换分区
1.lsps 
  lsps -a

2.lsps 
  lsps -s

3.prtconf 
 
4.topas

原文地址:https://www.cnblogs.com/lhdz_bj/p/8575592.html