抑郁症健康,内容丰富有趣,生活中的好帮手!
抑郁症健康 > linux系统查看电脑设备型号 Linux系统查看硬件信息

linux系统查看电脑设备型号 Linux系统查看硬件信息

时间:2020-07-15 06:20:03

相关推荐

一、查看服务器型号、序列号:

[root@Master ~]#dmidecode|grep "System Information" -A9|egrep "Manufacturer|Product|Serial"

查看主板型号

[root@Master ~]# dmidecode |grep -A16 "System Information$"

查看BIOS信息

[root@Master ~]# dmidecode -t bios

查看内存槽及内存条

[root@Master ~]# dmidecode -t memory | head -45 | tail -23

查看网卡信息

dmesg | grep -i Ethernet

查看pci信息,即主板所有硬件槽信息

[root@Master ~]# lspci | head -10

二、查看CPU信息

(1)查看cpu型号

[root@Master ~]# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c

40 Intel(R) Xeon(R) CPU E5-2650 v3 @ 2.30GHz

(2)查看系统中实际物理CPU的数量(物理)

[root@Master ~]# grep 'physical id' /proc/cpuinfo | sort | uniq | wc -l

2

(3)系统中实际物理CPU的数量(核数)线程

[root@Master ~]# cat /proc/cpuinfo |grep 'processor'|wc -l

40

(4)查看每个物理CPU中core的个数(即核数)

[root@Master ~]# cat /proc/cpuinfo |grep "cores"|uniq

cpu cores : 10

(5)查看CPU的主频

[root@Master ~]# cat /proc/cpuinfo |grep MHz|uniq

cpu MHz : 1200.000

cpu MHz : 2300.000

cpu MHz : 1200.000

(6)查看CPU的详细信息

[root@Master ~]# cat /proc/cpuinfo | head -20

(7)查看CPU的相关信息

[root@Master ~]# lscpu

(8)查看cpu运行模式

[root@Master ~]# getconf LONG_BIT

64

(9)查看cpu是否支持64bit

[root@Master ~]# cat /proc/cpuinfo | grep flags | grep ' lm ' | wc -l

40

(结果大于0, 说明支持64bit计算. lm指long mode, 支持lm则是64bit)

三、查看内存信息

(1)查看内存硬件信息

[root@Master ~]# dmidecode -t memory | head -45 | tail -24

(2)最大支持多少内存

[root@Master ~]# dmidecode|grep -P 'Maximum\s+Capacity'

(3)Linux 查看内存的插槽数,已经使用多少插槽.每条内存多大:

dmidecode |grep -A5 "Memory Device" |grep Size|grep -v Range

(4)Linux 查看内存的频率:

[root@Master ~]# dmidecode|grep -A16 "Memory Device"|grep 'Speed'

(5)Linux 查看内存的详细信息:

[root@Master ~]# cat /proc/meminfo |head -20

6)Linux 查看内存的使用情况

[root@Master ~]# free -m //-b,-k,-m,-g show output in bytes, KB, MB, or GB

四、查看硬盘信息

(1)查看挂接的分区状态

[root@Master ~]# fdisk -l |grep Disk

(2)查看硬盘和分区分布

[root@Master ~]# lsblk

(3)查看硬盘和分区的详细信息

[root@Master ~]# fdisk -l

(4)查看挂接的分区状态

[root@Master ~]# mount | column -t

(5)查看挂接的分区状态

[root@Master ~]# swapon -s

(6)查看硬盘使用情况

[root@Master ~]# df -hT

(7) 硬盘检测命令smartctl

[root@Master ~]# smartctl -a /dev/sda

五、查看网卡信息

(1)查看网卡硬件信息

[root@Master ~]# lspci | grep -i 'eth'

(2)查看系统的所有网络接口

[root@Master ~]# ifconfig -a

[root@Master ~]# ip link show

(3)查看某个网络接口的详细信息,例如eth0的详细参数和指标

[root@Master ~]# ethtool eth0

(4)查看所有网卡的链路状态

[root@Master ~]# for i in seq 0 9;do ethtool eth${i} | egrep 'eth|Link';done

六、列出所有PCI设备信息

[root@Master ~]# lspci -tv | more

如果觉得《linux系统查看电脑设备型号 Linux系统查看硬件信息》对你有帮助,请点赞、收藏,并留下你的观点哦!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。