Linux下如何查看版本信息, 包括位数、版本信息以及CPU内核信息、CPU具体型号等等,整个CPU信息一目了然。
# uname -a (Linux查看版本当前操作系统内核信息) Linux localhost.localdomain 2.4.20-8 #1 Thu Mar 13 17:54:28 EST 2003 i686 athlon i386 GNU/Linux
# cat /proc/version (Linux查看当前操作系统版本信息) Linux version 2.4.20-8 (bhcompile@porky.devel.redhat.com) (gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5)) #1 Thu Mar 13 17:54:28 EST 2003
# cat /etc/issue 或cat /etc/redhat-release(Linux查看版本当前操作系统发行版信息) Red Hat Linux release 9 (Shrike)
cat /etc/redhat-release,这种方法只适合Redhat系的Linux: [root@S-CentOS home]# cat /etc/redhat-release CentOS release 6.5 (Final)
# cat /proc/cpuinfo (Linux查看cpu相关信息,包括型号、主频、内核信息等) processor: 0 vendor_id: GenuineIntel cpu family: 6 model: 62 model name: Intel(R) Xeon(R) CPU E5-2650 v2 @ 2.60GHz stepping: 4 microcode: 0x428 cpu MHz: 2593.836 cache size: 20480 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: 5187.67 clflush size: 64 cache_alignment: 64 address sizes: 46 bits physical, 48 bits virtual power management:
# getconf LONG_BIT (Linux查看版本说明当前CPU运行在32bit模式下, 但不代表CPU不支持64bit) 32
# lsb_release -a (经销商、描述、发行版本、研发代码的查看) No LSB modules are available. Distributor ID:Ubuntu Description:Ubuntu 14.04.2 LTS Release:14.04 Codename:trusty