天天看點

Linux檢視CPU等硬體資訊

檢視CPU資訊(型号) 

# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c 

8  Intel(R) Xeon(R) CPU            E5410   @ 2.33GHz 

(看到有8個邏輯CPU, 也知道了CPU型号) 

# cat /proc/cpuinfo | grep physical | uniq -c 

4 physical id      : 0 

4 physical id      : 1 

(說明實際上是兩顆4核的CPU) 

# getconf LONG_BIT 

32 

(說明目前CPU運作在32bit模式下, 但不代表CPU不支援64bit) 

# cat /proc/cpuinfo | grep flags | grep ' lm ' | wc -l 

(結果大于0, 說明支援64bit計算. lm指long mode, 支援lm則是64bit) 

再完整看cpu詳細資訊, 不過大部分我們都不關心而已. 

# dmidecode | grep 'Processor Information' 

檢視内 存資訊 

# cat /proc/meminfo 

# uname -a 

Linux euis1 2.6.9-55.ELsmp #1 SMP Fri Apr 20 17:03:35 EDT 2007 i686 i686 i386 GNU/Linux 

(檢視目前作業系統核心資訊) 

# cat /etc/issue | grep Linux 

Red Hat Enterprise Linux AS release 4 (Nahant Update 5) 

(檢視目前作業系統發行版資訊) 

檢視機器型号 

# dmidecode | grep "Product Name"  

檢視網卡資訊 

# dmesg | grep -i eth

Linux下如何檢視版本資訊, 包括位數和多核資訊,今天我們就來一起看看linux 檢視版本資訊以及檢視CPU核心資訊、CPU具體型号等等,整個CPU資訊一目了然。相信不會讓大家失望。

# uname -a

Linux euis1 2.6.9-55.ELsmp #1 SMP Fri Apr 20 17:03:35 EDT 2007 i686 i686 i386 GNU/Linux

(Linux檢視版本目前作業系統核心資訊)

# cat /etc/issue | grep Linux

Red Hat Enterprise Linux AS release 4 (Nahant Update 5)

(Linux檢視版本目前作業系統發行版資訊)

# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c

8 Intel(R) Xeon(R) CPU E5410 @ 2.33GHz

(Linux檢視cpu有8個邏輯CPU, 也知道了CPU型号)

# cat /proc/cpuinfo | grep physical | uniq -c

4 physical id : 0

4 physical id : 1

(Linux檢視版本說明實際上是兩顆4核的CPU)

# getconf LONG_BIT

32

(Linux檢視版本說明目前CPU運作在32bit模式下, 但不代表CPU不支援64bit)

# cat /proc/cpuinfo | grep flags | grep ' lm ' | wc -l

8

(結果大于0, 說明支援64bit計算. lm指long mode, 支援lm則是64bit)

最後再完整看cpu實體資訊, 不過大部分我們都不關心而已.

# dmidecode | grep -A48 'Processor Information$'