1. 查看内核版本命令:
[root@localhost Addy]$ cat /proc/version
Linux version 2.6.5-7.244-smp (geeko@ buildhost) (gcc version 3.3.3 (SuSE Linux)) #1 SMP Mon Dec 12 18:32:25 UTC 2005
[root@localhost Addy]$ uname -a
Linux mylinuxserver 2.6.5-7.244-smp #1 SMP Mon Dec 12 18:32:25 UTC 2005 i686 i686 i386 GNU/Linux
[root@localhost Addy]$ uname -r
2.6.5-7.244-smp
2. 明确地查看操作系统的位数:
如何知晓操作系统是32位还是64位?这里介绍一种简单的方式:
[root@localhost Addy]$ getconf LONG_BIT
64
通过上面操作,我们可以很方便看到是64位。我的版本信息如下:
[root@localhost Addy]$ lsb_release -a
LSB Version: :core-4.0-amd64:core-4.0-ia32:core-4.0-noarch:graphics-
4.0-amd64:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-amd64:printing-
4.0-ia32:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 5.8 (Final)
Release: 5.8
Codename: Final
如果你的显示不出来,请man getconf,查看下帮助。