人妖在线一区,国产日韩欧美一区二区综合在线,国产啪精品视频网站免费,欧美内射深插日本少妇

新聞動(dòng)態(tài)

查看Linux系統(tǒng)版本信息的方法小結(jié)

發(fā)布日期:2022-02-04 08:13 | 文章來源:源碼中國(guó)
如何查看Linux系統(tǒng)使用的版本信息呢? 下面這篇文章收集、整理了一些常見的查看Linux系統(tǒng)版本的方法。由于手頭只有Oracle Linux、Centos Linux、Redhat Linux三個(gè)版本Linux,所以像Debian、Ubuntu之類的Linux系統(tǒng),下面方法在這些版本都沒測(cè)試過。

1:more /etc/issue 命令查看

1.1 Oracle Linux


復(fù)制代碼
代碼如下:

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


1.2 Centos Linux


復(fù)制代碼
代碼如下:

[root@Centos2 ~]# more /etc/issueCentOS release 6.4 (Final)Kernel \r on an \m


1.3 RedHat Linux


復(fù)制代碼
代碼如下:

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


2: lsb_release -a 命令查看

2.1 Oracle Linux


復(fù)制代碼
代碼如下:

[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

2.2 Centos Linux

復(fù)制代碼
代碼如下:

[root@Centos2 ~]# lsb_release -a
LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 6.4 (Final)
Release: 6.4
Codename: Final

2.3 RedHat Linux

復(fù)制代碼
代碼如下:

[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

3:cat /etc/redhat-release 命令查看

這個(gè)命令應(yīng)該只有部分Linux可以查看,不是所有版本Linux都可以使用該命令

3.1 Oracle Linux

復(fù)制代碼
代碼如下:

[root@DB-Server ~]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 5.7 (Tikanga)

[root@DB-Server etc]# cat /etc/*release
Enterprise Linux Enterprise Linux Server release 5.7 (Carthage)
Oracle Linux Server release 5.7
Red Hat Enterprise Linux Server release 5.7 (Tikanga)
[root@DB-Server etc]# ls /etc/*lease
/etc/enterprise-release /etc/oracle-release /etc/redhat-release
[root@DB-Server etc]#

3.2 Centos Linux

復(fù)制代碼
代碼如下:

[root@Centos2 ~]# cat /etc/redhat-release
CentOS release 6.4 (Final)

[root@Centos2 ~]# cat /etc/*release
CentOS release 6.4 (Final)
LSB_VERSION=base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
CentOS release 6.4 (Final)
CentOS release 6.4 (Final)
[root@Centos2 ~]# ls /etc/*release
/etc/centos-release /etc/lsb-release /etc/redhat-release /etc/system-release
[root@Centos2 ~]#

3.3 RedHat Linux

復(fù)制代碼
代碼如下:

[root@getlnx05 ~]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 5.7 (Tikanga)

[root@getlnx05 ~]# cat /etc/*release
Red Hat Enterprise Linux Server release 5.7 (Tikanga)
[root@getlnx05 ~]# ls /etc/*release
/etc/redhat-release
[root@getlnx05 ~]#

4 rpm -q redhat-release命令查看,只適用于Redhat Linux

復(fù)制代碼
代碼如下:

[root@getlnx05 ~]# rpm -q redhat-release
redhat-release-5Server-5.7.0.3

海外服務(wù)器租用

版權(quán)聲明:本站文章來源標(biāo)注為YINGSOO的內(nèi)容版權(quán)均為本站所有,歡迎引用、轉(zhuǎn)載,請(qǐng)保持原文完整并注明來源及原文鏈接。禁止復(fù)制或仿造本網(wǎng)站,禁止在非www.sddonglingsh.com所屬的服務(wù)器上建立鏡像,否則將依法追究法律責(zé)任。本站部分內(nèi)容來源于網(wǎng)友推薦、互聯(lián)網(wǎng)收集整理而來,僅供學(xué)習(xí)參考,不代表本站立場(chǎng),如有內(nèi)容涉嫌侵權(quán),請(qǐng)聯(lián)系alex-e#qq.com處理。

相關(guān)文章

實(shí)時(shí)開通

自選配置、實(shí)時(shí)開通

免備案

全球線路精選!

全天候客戶服務(wù)

7x24全年不間斷在線

專屬顧問服務(wù)

1對(duì)1客戶咨詢顧問

在線
客服

在線客服:7*24小時(shí)在線

客服
熱線

400-630-3752
7*24小時(shí)客服服務(wù)熱線

關(guān)注
微信

關(guān)注官方微信
頂部