Home > Operation and Maintenance > Linux Operation and Maintenance > How to check version information in linux

How to check version information in linux

青灯夜游
Release: 2023-05-25 12:44:11
Original
75372 people have browsed it

Methods to view version information: 1. Use the "cat /proc/version" command to output the current operating system kernel information; 2. Use the "uname -a" command to output the current operating system kernel information; 3. Use the "lsb_release -a" command to output all version information; 4. Use the "cat /etc/redhat-release" command to output the system version information; 5. Use the "cat /etc/issue" command to output System version information.

How to check version information in linux

#The operating environment of this tutorial: centos7 system, Dell G3 computer.

Sometimes you need to check the version of your Linux system. There are some commands to check. They are introduced as follows: command to check the Linux kernel version (two methods) and command to check the Linux system version (three methods)

1. Check the Linux kernel version command (two methods):

1, cat /proc/version (Linux checks the current operating system kernel version information)

# cat /proc/version
Linux version 2.6.18-194.8.1.el5.centos.plus (mockbuild@builder17.centos.org) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)) #1 SMP Wed Jul 7 11:50:45 EDT 2010
Copy after login
How to check version information in linux

2, uname -a (Linux checks the current operating system kernel version Information)

# uname -a
Linux localhost.localdomain 2.6.18-194.8.1.el5.centos.plus #1 SMP Wed Jul 7 11:50:45 EDT 2010 i686 i686 i386 GNU/Linux
Copy after login
How to check version information in linux

2. Command to check the Linux system version (3 methods):

1, lsb_release -a, you can list all version information:

# lsb_release -a

LSB Version: :core-3.1-ia32:core-3.1-noarch:graphics-3.1-ia32:graphics-3.1-noarch
Distributor ID: CentOS
Description: CentOS release 5.5 (Final)
Release: 5.5
Codename: Final
Copy after login

This command applies to all Linux distributions , including Redhat, SuSE, Debian... and other distributions.

2, cat /etc/redhat-release

This method is only suitable for Redhat Linux:

# cat /etc/redhat-release
CentOS release 5.5 (Final)
Copy after login

How to check version information in linux

3, cat /etc/issue, this command also applies to all Linux distributions

# cat /etc/issue
CentOS release 5.5 (Final)
Copy after login

Extended knowledge: distribution and kernel introduction

Linux is an open source computer operating system kernel. It is a Unix-like operating system written in C language and compliant with POSIX standards.

Newbies are often confused by the numerous Linux distributions. Let’s first explain this problem.

Technically speaking, Linux developed by Linus Torvalds is just a kernel. The kernel refers to a system software that provides device drivers, file systems, process management, network communications and other functions. The kernel is not a complete operating system, it is only the core of the operating system. Some organizations or manufacturers package the Linux kernel with various software and documents, and provide system installation interfaces and system configuration, setting and management tools, which constitutes a Linux distribution.

In the development process of the Linux kernel, various Linux distributions played a huge role. It was they that promoted the application of Linux, allowing more people to start paying attention to Linux. Therefore, it is actually inaccurate to directly refer to Red Hat, Ubuntu, SUSE, etc. as Linux. They are Linux distributions. To be more precise, they should be called "operating system software packages with Linux as the core."

Each distribution version of Linux uses the same Linux kernel, so there is no compatibility problem at the kernel layer. Each version has a different feeling, but it is only in the outermost layer of the distribution version (by the distribution version) Applications integrated and developed by vendors) are reflected.

Linux distributions can be roughly divided into two categories:

  • Releases maintained by commercial companies, represented by the famous Red Hat;

  • Releases maintained by community organizations, represented by Debian.

Related recommendations: "Linux Video Tutorial"

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

Related labels:
source:php.cn
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