Linux下如何查看版本信息, 包括位数、版本信息以及CPU内核信息、CPU具体型号等等,整个CPU信息一目了然。
1.uname -a (Linux查看版本当前操作系统内核信息)
Linux iZ28hv9y2qkZ 3.10.0-123.9.3.el7.x86_64 #1 SMP Thu Nov 6 15:06:03 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
(x86_64代表的是64位系统,我这里是Centos7)
--------------------------------------------------------------------------------------------------------------------------
2. cat /proc/version (Linux查看当前操作系统版本信息)
cat /proc/version
Linux version 3.10.0-123.9.3.el7.x86_64 ([email protected]) (gcc version 4.8.2 20140120 (Red Hat 4.8.2-16) (GCC) ) #1 SMP Thu Nov 6 15:06:03 UTC 2014
-------------------------------------------------------------------------------------------
3.cat /etc/issue 或cat /etc/redhat-release(centos7适用)(Linux查看版本当前操作系统发行版信息)
CentOS Linux release 7.2.1511 (Core)
-------------------------------------------------------------------------------------------------------------------------
4.cat /proc/cpuinfo (Linux查看cpu相关信息,包括型号、主频、内核信息等)
CentOS Linux release 7.2.1511 (Core)
[[email protected] project]# ^C
[[email protected] project]# cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 45
model name : Intel(R) Xeon(R) CPU E5-2630 0 @ 2.30GHz
stepping : 7
microcode : 0x70d
cpu MHz : 2300.048
cache size : 15360 KB
physical id : 0
siblings : 1
core id : 0
cpu cores : 1
apicid : 0
initial apicid : 0
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat clflush mmx fxsr sse sse2 ht syscall nx rdtscp lm constant_tsc rep_good nopl pni ssse3 cx16 sse4_1 sse4_2 popcnt aes hypervisor lahf_lm
bogomips : 4600.09
clflush size : 64
cache_alignment : 64
address sizes : 46 bits physical, 48 bits virtual
power management:
-------------------------------------------------------------------------------------------
5.getconf LONG_BIT (Linux查看版本说明当前CPU运行在32bit模式下还是64bit模式下的)
64