How to check Linux OS version

This tutorial is about how to check the Linux OS version. We will do our best to help you understand this guide. I hope you enjoy this blog How to check Linux OS version. If your answer is yes, please share after reading.

Check out How to Check Linux Operating System Version

For a normal Linux user, and especially an administrator, it is very important to know the version of the operating system it is running on. There could be several reasons for knowing the version number of your operating system. It can be very useful when installing a new program, checking the availability of various features, and troubleshooting. There are several ways to check the version of the operating system on a Linux system. In this article, we explain the graphical and command line methods of getting the operating system version of a Linux system.

Check the version of the operating system on Linux

How to find the name and version of the operating system on Linux:

  • Open the terminal app (bash shell)
  • To log in to a remote server using ssh: ssh-user @ servername
  • Enter one of the following commands to find out the name and version of the operating system on Linux:
    • cat / etc / os-release
    • lsb_release -a
    • hostnamectl
  • Enter the following command to find the Linux kernel version:

The / etc / os-release file

Enter the following cat command:

We can filter information like operating system version and name using the grep command / egrep command as follows:

  • $ grep ‘^ VERSION’ / etc / os-release
  • $ egrep ‘^ (VERSION | NAME) =’ / etc / os-release

We see that:

  • NAME = “CentOS Linux”
  • VERSION = “8 (core)”

Even a small Linux distribution, like Alpine Linux, provides the required operating system (operating system) information, including the version:

Checking the version of the operating system on Linux using the lsb_release command

The lsb_release command provides LSB (Linux Standard Base) and distribution-specific information about the CLI. The syntax is:

Hostnamectl command

Use the hostnamectl command to query and change the system host name and settings. Just enter the following command to check the operating system name and Linux kernel version:

And there is information as follows. Search for “Operating System” and “Kernel”:

uname command

Just print out the Linux kernel version, run:

Another option is to write the following command:

Sample outputs:

  • Linux version 3.10.0-693.11.6.el7.x86_64 ([email protected]) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-16) (GCC )) # 1 SMP Thu Dec 28 2:23:39 PM EST 2017

/ etc / broadcast file

Use the more / less command like this:

  • $ Cat / etc / problem
  • $ more / etc / problem
  • $ less / etc / problem

Final words: How to check Linux OS version

I hope you understand this article How to check Linux OS versionif your answer is no, you can ask anything through the contact forum section of this article. And if your answer is yes, please share this article with your family and friends.

About Willie Ash

Check Also

myWorkspace: Run Amiga Workbench under Windows

The Commodore Amiga computer was ahead of its time in many ways when it hit …