Linux查看处理器信息
目录
一、查看CPU信息
二、查看当前操作系统的缓存行大小
三、查看不同层次的缓存大小
四、查看内存信息
五、查看Linux内核版本,编译器版本
一、查看CPU信息
~ # cat /proc/cpuinfo
processor : 0
BogoMIPS : 48.00
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 4
processor : 1
BogoMIPS : 48.00
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd03
CPU revision : 4
二、查看当前操作系统的缓存行大小
~ # cat /sys/devices/system/cpu/cpu0/cache/index0/coherency_line_size
64
三、查看不同层次的缓存大小
~ # cat /sys/devices/system/cpu/cpu0/cache/index0/size
32K
~ # cat /sys/devices/system/cpu/cpu0/cache/index1/size
32K
~ # cat /sys/devices/system/cpu/cpu0/cache/index2/size
256K
四、查看内存信息
~ # cat /proc/meminfo
MemTotal: 488752 kB
MemFree: 262596 kB
MemAvailable: 348372 kB
Buffers: 3160 kB
Cached: 98764 kB
SwapCached: 0 kB
Active: 97056 kB
Inactive: 94236 kB
Active(anon): 89364 kB
Inactive(anon): 28 kB
Active(file): 7692 kB
Inactive(file): 94208 kB
Unevictable: 0 kB
Mlocked: 0 kB
SwapTotal: 0 kB
SwapFree: 0 kB
Dirty: 0 kB
Writeback: 0 kB
AnonPages: 89412 kB
Mapped: 43264 kB
Shmem: 32 kB
Slab: 24228 kB
SReclaimable: 12808 kB
SUnreclaim: 11420 kB
KernelStack: 3920 kB
PageTables: 2032 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 244376 kB
Committed_AS: 450160 kB
VmallocTotal: 263061440 kB
VmallocUsed: 0 kB
VmallocChunk: 0 kB
CmaTotal: 16384 kB
CmaFree: 16120 kB
五、查看Linux内核版本,编译器版本
~ # cat /proc/version
Linux version 4.9.38 (fuh@dell) (gcc version 7.5.0 (Linaro GCC 7.5-2019.12) ) #13 SMP PREEMPT Sun Sep 29 16:17:37 CST 2024