How to check Linux version information

王林
Release: 2023-05-13 13:37:18
forward
1420 people have browsed it

系统

发行版本

--

内核版本、位数

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

Check the system release version

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

You can also find related information through cat /etc/redhat-release.

Check the system kernel version and number of bits

[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
Copy after login

LSB Version item displays the system kernel version, where amd64 indicates that the system is 64-bit of.

CentOS

View the system release version cat /etc/issue

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

You can also query the same information through cat /etc/centos-release .

Check the system kernel version and digits 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
Copy after login

Linux version 2.6.32-431.el6.x86_64Displays the Linux version,x86_64 Shows a 64-bit system. Relevant information can also be found through uname -r.

Oracle Linux

Check the system release version

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

You can also query related information through cat /etc/oracle-release.

Check the system kernel version and number of bits

[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
Copy after login

LSB Version displays the system kernel version, where amd64 indicates that the system is 64-bit .

Summary of applicable scope of all commands

View system release version

##lsb_release -aAll Linux distributions##cat /etc/redhat-releasecat /etc/issueView system kernel bits
# #Command


Applicable scope





RedHat Linux



All Linux Release version


Commanduname -a , uname -rcat /proc/version


Applicable scope



All Linux distributions



All Linux distributions


The above is the detailed content of How to check Linux version information. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:yisu.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!