Table of contents
1.
Introduction
2.
What is Linux?
3.
Linux Distribution's Version
4.
OS Version in Linux using Graphical User Interface
5.
Commands to check OS version in Linux 
5.1.
1) Checking OS version on Linux Using cat /etc/os-release
5.2.
2) Checking OS version on Linux Using lsb_release -a
5.3.
3) Checking OS version on Linux Using cat /proc/version
5.4.
4) Checking OS version on Linux Using uname -a
5.5.
5) Checking OS version on Linux Using hostnamectl
5.6.
6) Checking OS version on Linux Using dmesg | grep Linux
6.
Frequently Asked Questions
6.1.
How do I find the OS version on Linux?
6.2.
What are the 3 types of files in Linux?
6.3.
How can we check OS version?
6.4.
How do I find the OS version in Unix?
7.
Conclusion
Last Updated: Mar 3, 2025
Medium

How to check OS version in linux

Author Dhruv Rawat
0 upvote
Career growth poll
Do you think IIT Guwahati certified course can help you in your career?

Introduction

How do you check OS version in Linux which you are running? If you are an open-source operating system, knowing your Linux version is helpful. Through version information, you could troubleshoot issues, find compatibility information for software, and check if the software is up to date with the latest security patches to keep it secure.

In this article, we'll explore different methods to check the version of your Linux in your system so you know what you're running.

How to check OS version in linux

What is Linux?

Linux is a free open-source operating system and a popular choice among developers and programmers because everyone has access to its source code and can modify it. It was released by Linus Torvalds, a Finnish software engineer in 1991. 

Also read,  features of linux operating system

There are several variants of Linux, known as Linux distributions like Suse, OpenSUSE, Debian, Ubuntu and CentOS, to name a few. Each distribution comes with its own set of features and tools. Also, Linux provides the option to add on additional software and do customisation according to the needs. Many large organisations and governments use Linux as a very stable and secure operating system for their servers and infrastructure.

Linux Distribution's Version

Below are some steps you could follow to know your Linux OS version.

  • Open terminal: press Ctrl + Alt + T keys from the keyboard or search it.
     
  • Remote Server: user on a remote server should log in using the following command:
     
ssh user@server-name

 

  • Run the command: on the terminal type any one of the following commands:
     
cat /etc/os-release
 lsb_release -a
cat /proc/version

Also see, gzip command in linux

OS Version in Linux using Graphical User Interface

Below are some steps you could follow in order to check OS version in Linux using GUI.

  • Open Settings: right click on your home screen and goto settings options from the menu.
     
  • About Section: Once settings open, go to the About section option and open it.
     
  • OS version: in the About section you'll get all the details like processor, graphics and memory, scroll down to check the OS version in linux.

Commands to check OS version in Linux 

In this section, we will check some commands that will guide us on how to check os version in Linux and will display all its details.

1) Checking OS version on Linux Using cat /etc/os-release

We will use Linux’s /etc directory from where we will retrieve the Linux version using the above command.

Output:

Output for cat command

2) Checking OS version on Linux Using lsb_release -a

Let’s use the above command to get all details of our Linux distribution.

Output:

Output for lsb release a command

3) Checking OS version on Linux Using cat /proc/version

We will use the above command for Linux’s proc directory and get the version file from there.

Output:

output for version command

4) Checking OS version on Linux Using uname -a

We will use the above standard command to check the kernel or Linux version.

Output:

Output

5) Checking OS version on Linux Using hostnamectl

We will use the above command, which will display the information of our system and use it to change the hostname of the system.

Output:

Output for hostnamectl

6) Checking OS version on Linux Using dmesg | grep Linux

We will use the above command, which will display the system log messages from the kernel’s ring buffer but also helps us to find os version in Linux.

Output:

Output for grep command

Frequently Asked Questions

How do I find the OS version on Linux?

To determine the operating system version on Linux, enter a terminal and type "lsb_release -a" or "cat /etc/os-release." It will display specific details about your Linux distribution and version.

What are the 3 types of files in Linux?

The three types of files in Linux are Regular Files (containing data), Directories (for organizing files), and Special Files (representing hardware devices or system resources).

How can we check OS version?

Select Start > Settings > System > About from the menu.  You can see whether your device is running a 32bit or 64bit version of Windows under Device specifications > System type.  You can see which edition and version of Windows your device is running under Windows specifications.

How do I find the OS version in Unix?

Open the terminal application (bash shell) . For remote server login using the ssh: ssh user@server-name.  Type any one of the following command to find os name and version in Linux: cat /etc/os-release. lsb_release -a.hostnamectl. Type the following command to find Linux kernel version: uname -r.

Check this out: Touch command in linux

Conclusion

Congratulations you did an amazing job!! This article has gone through a detailed introduction to Linux and discussed various commands on how to check os version in Linux in the system and illustrate it with the help of examples. At last, some frequently asked questions have been discussed.

I hope you enjoyed reading this article. Here are some more related articles:

Live masterclass