Linux版本信息如何查看

37次阅读
没有评论

共计 2192 个字符,预计需要花费 6 分钟才能阅读完成。

本篇内容介绍了“Linux 版本信息如何查看”的有关知识,在实际案例的操作过程中,不少人都会遇到这样的困境,接下来就让丸趣 TV 小编带领大家学习一下如何处理这些情况吧!希望大家仔细阅读,能够学有所成!

系统

发行版本

内核版本、位数

RedHat

cat /etc/issue

cat /etc/redhat-release

lsb_release -a

CentOS

cat /etc/issue

cat /etc/centos-release

cat /proc/version

Debian

cat /etc/issue

cat /etc/debian_version

cat /proc/version

Ubuntu

cat /etc/issue

cat /etc/lsb_release

cat /proc/version

Oracle

cat /etc/issue

cat /etc/oracle-release

lsb_release -a

RedHat 查看系统发行版本

[root@getlnx05 ~]# cat /etc/issue
Red Hat Enterprise Linux Server release 5.7 (Tikanga)
Kernel \r on an \m

通过 cat /etc/redhat-release 也查到看到相关的信息。

查看系统内核版本、位数

[root@getlnx05 ~]# 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: RedHatEnterpriseServer
Description: Red Hat Enterprise Linux Server release 5.7 (Tikanga)
Release: 5.7
Codename: Tikanga

LSB Version 项显示的是系统的内核版本,其中 amd64 表示系统是 64 位的。

CentOS 查看系统发行版本 cat /etc/issue

[chenyurong@localhost local]$ cat /etc/issue
CentOS release 6.5 (Final)
Kernel \r on an \m

通过 cat /etc/centos-release 也可以查询到一样的信息。

查看系统内核版本、位数 more /proc/version

[chenyurong@localhost local]$ cat /proc/version
Linux version 2.6.32-431.el6.x86_64 (mockbuild@c6b8.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC) ) #1 SMP Fri Nov 22 03:15:09 UTC 2013

Linux version 2.6.32-431.el6.x86_64 显示了 Linux 的版本,x86_64 显示了是 64 位的系统。通过 uname - r 也可以查到相关信息。

Oracle Linux 查看系统发行版本

[root@DB-Server ~]# cat /etc/issue
Oracle Linux Server release 5.7
Kernel \r on an \m

通过 cat /etc/oracle-release 也可以查询到相关信息。

查看系统内核版本、位数

[root@DB-Server ~]# 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: EnterpriseEnterpriseServer
Description: Enterprise Linux Enterprise Linux Server release 5.7 (Carthage)
Release: 5.7
Codename: Carthage

LSB Version 显示的是系统的内核版本,其中 amd64 表示系统是 64 位的。

所有命令适用范围总结查看系统发行版本

命令

适用范围

lsb_release -a

所有 Linux 发行版

cat /etc/redhat-release

RedHat 系 Linux

cat /etc/issue

所有 Linux 发行版

查看系统内核位数

命令

适用范围

uname -a、uname -r

所有 Linux 发行版

cat /proc/version

所有 Linux 发行版

“Linux 版本信息如何查看”的内容就介绍到这里了,感谢大家的阅读。如果想了解更多行业相关的知识可以关注丸趣 TV 网站,丸趣 TV 小编将为大家输出更多高质量的实用文章!

正文完
 
丸趣
版权声明:本站原创文章,由 丸趣 2023-07-15发表,共计2192字。
转载说明:除特殊说明外本站除技术相关以外文章皆由网络搜集发布,转载请注明出处。
评论(没有评论)