en
  English
Phone :  +370 (5) 204-1903
Email :  sales@1gbits.com
  1. Dedicated server
  2. Blog
  3. How to Get Linux Version? [Check Linux Version Command]

How to Get Linux Version? [Check Linux Version Command]

When it comes to web hosting or other similar online services, Linux is king. There are simply more advantages to using Linux than Windows when it comes to web hosting. The biggest advantages are that Linux distributions are open-source and lightweight operating systems compared to Windows. Howerver there are multiple versions of Linux, and how do you check Linux version in your system?

Linux Tutorial Dec 23, 20 by Nisal N 2 min Read
How to Get Linux Version? [Check Linux Version Command]

As Linux is a free and open-source operating system, there are many variants of it out there, called Linux distributions. Some of the most popular ones are Debian, CentOS, Ubuntu, Fedora, and RHEL. It is most important to check Linux version you have installed on your device before installing any application and security patches.

How To Check Linux Version 

There are multiple ways to find the Linux version on our device. Here we have listed the best Linux version command to find Linux version.

1. Find Linux version with the cat command:

Type in the following cat command into the Linux terminal:

cat /etc/os-release

The output should look like this.

You will be treated with a result as shown above. However, if you want a refined version of this, you can use the grep command as mentioned below. 

grep '^VERSION' /etc/os-release

As you can see in the output below, the Linux version command gives the distribution name and its version.

2. Get Linux version Using hostnamectl command:

Open the terminal and type the following command to check OS version Linux:

hostnamectl

The result should look somewhat similar to this:

3.   Show Linux version Using uname command:

This will not provide you with the exact Linux OS version, but the Linux kernel version.

uname -r

This is a sample output:

Alternatively, you could also use this command to find the kernel version:

cat /proc/version

And this will be the result:

Conclusion

In this article, we went through the steps to check Linux version on your server. This article also helps you check various methods to get your Linux distribution version and even the Linux kernel version. If you think there are other methods to find the Linux version that is not mentioned here in this article, feel free to add them to the comment section below! We will review it and amend the article with the new methods to find Linux's latest version. 

People Are Also Reading:

author img

Nisal N

Computers has always fascinated me since I was a kid and here we are. I love travelling for 2 reasons: the first one to see a new part of the world and second (the most important one) to experience the rich culture hidden among the country and people. I'm pretty good at cooking but very poor when it comes to baking.

Leave A Comment