Check the OS Version in Linux
Last Updated :
23 Jul, 2025
When we want to install the Software on our system, first we must know whether our current Operating System is supporting this version of the software or not. In Windows, we can easily check it as Windows is based on a GUI-based Operating System.
But we prefer to use the Command line instead of the GUI in an Operating System like Linus/Unix.
5 Simple Ways to Check the Linux OS Version:
Here are some easy ways to see which Linux version your computer is using, with simple commands or by clicking through settings.
1) Using the os-release file available in Linux’s etc directory to check the Version of Ubuntu.
We can check the Linux Operating System (OS) information by running the below command.
cat /etc/os-release
Output:
used `cat /etc/os-release` for displaying the Version of UbuntuTo only view the name and version of Ubuntu or Red Hat Linux, we can filter out it by using the `grep` command.
grep '^VERSION' /etc/os-release
grep -E '^(VERSION|NAME)=' /etc/os-release
only view the name and version of Red Hat LinuxIn this example, we checked our name and version of Red Hat Linux.
2) Using the `lsb_release` Command to Check the OS Version of Ubuntu.
LSB Stands for Linux Standard Base, we can check the Linux Operating System (OS) with the sing lsb_release command.
lsb_release -a
Output:
used `lsb_release -a` to display the ng OS version in linux 3) Using the `hostnamectl` Command to Check Version of Ubuntu.
We can use the `hostnamectl` command to check the Linux Operating System (OS) or we can say to check the version of Ubuntu.
hostnamectl
Output:
used hostnamectl for displaying the OS version of Ubuntu in Linux4) `uname` Command in Linux to Check the Version of Ubuntu.
To print the version of the Linux kernel we can use the `uname` command.
uname -r
version of Linux kernel5) Using GUI (Graphical User Interface) to Check the Version of Linux.
We have 3 Simple Steps to find OS version of Ubuntu in Linux.
As shown below.
click the application point by the yellow arrowStep 2: Search Settings kernel on the Search bar.
Click on settings as shown below.
click the application pointed by the yellow arrowStep 2: click on About.
As shown below. And we can easily see the version of Ubuntu.
click on About to view the detailsConclusion
It is essential to know the operating system version when we are installing software or performing any kind of system update. Checking the OS version in Windows is straightforward due to the GUI (Graphical User Interface), whereas in Linux users have several ways to check the OS version including OS-release file, lsb_release command, hostnamectl command, or the GUI (Graphical User Interface).
One must understand the importance of knowing the CLI methods to find out the OS version as Linux is mostly used for CLI, by this users can troubleshoot issues, install new software, and keep the system updated.
Similar Reads
How to Check the MySQL Version in Linux Checking the MySQL version on a Linux system is a fundamental task for database administrators and developers. Knowing the MySQL version is important for troubleshooting, compatibility, and applying the appropriate updates. In this article, we'll explore various methods to easily determine the MySQL
3 min read
How to Check Java Version in Linux Java is a widely used programming language and platform, and having the correct version installed is crucial for running Java applications smoothly. If you're working on a Linux system, knowing your Java version can help ensure compatibility with tools, frameworks, or projects. Whether you're debugg
4 min read
How to Check Kernel Version in Linux The kernel is the core component of the Linux operating system, responsible for managing hardware, running processes, and ensuring system stability. Whether you're updating software, installing new drivers, or troubleshooting issues, knowing your kernel version helps ensure everything works smoothly
7 min read
How to Find openSUSE Linux Version? openSUSE is well known for its GNU/Linux-based operating systems, mainly Tumbleweed, a tested rolling release, and Leap, a distribution with Long-Term-Support(LTS). MicroOS and Kubic are new transactional, self-contained distributions for use as desktop or container runtime. Here we figure out which
2 min read
How to Check Your Ubuntu Version: A Guide Ubuntu is a Linux distribution built on Debian that is mostly comprised of software that is open-source and free. Ubuntu is officially available in three editions: Desktop, Server, and Core for IoT devices and robots. Canonical, a British corporation, and a group of other developers work on the oper
4 min read
How to Find Out Postfix Mail Server Version in Linux? The most commonly used implementations of SMTP in most Linux distros are Sendmail and Postfix. Postfix is an open-source mail-transfer agent that was originally developed as an alternative to Sendmail and is usually set up as the default mail server. We'll show you how to figure out what version of
1 min read