查看系统内核的方法:
1、uname -r
2、cat /proc/version
[root@localhost ~]# uname -r
2.6.32-504.8.1.el6.i686
[root@localhost ~]# cat /proc/version
Linux version 2.6.32-504.8.1.el6.i686 (mockbuild@c6b9.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-11) (GCC) ) #1 SMP Wed Jan 28 18:25:26 UTC 2015
查看系统版本的方法:
1、cat /etc/issue
2、cat /etc/system-release 软连接文件,实际连接到centos-release
3、cat /etc/redhat-release 软连接文件,实际连接到centos-release
4、cat /etc/centos-release
5、rpm -qa | grep release
6、lsb_release -a
LSB是Linux Standard Base的缩写,lsb_release命令用来显示LSB和特定版本的相关信息,可通过yum -y install redhat-lsb命令安装。
[root@localhost ~]# cat /etc/issueCentOS release 6.6 (Final)Kernel \r on an \m[root@localhost ~]# cat /etc/system-releaseCentOS release 6.6 (Final)[root@localhost ~]# cat /etc/redhat-release CentOS release 6.6 (Final)[root@localhost ~]# cat /etc/centos-release CentOS release 6.6 (Final)[root@localhost ~]# rpm -qa | grep releasecentos-release-6-6.el6.centos.12.2.i686[root@localhost ~]# lsb_release -aLSB Version::base-4.0-ia32:base-4.0-noarch:core-4.0-ia32:core-4.0-noarch:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-ia32:printing-4.0-noarchDistributor ID:CentOSDescription:CentOS release 6.6 (Final)Release:6.6Codename:Final
本文出自 “模范生的学习博客” 博客,请务必保留此出处http://mofansheng.blog.51cto.com/8792265/1624193