Ubuntu Linux is a free and open source operating system. Knowing your Ubuntu os version and name can be very useful for applying security patches and software updates. This page shows how to find out your Ubuntu Linux version from the CLI and GUI methods.
Check Ubuntu version in Linux
The procedure to find os name and version on Ubuntu Linux:
- Open the terminal application (bash shell) by pressing Ctrl+Alt+T
- 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 Ubuntu:
- Type the following command to find Ubuntu Linux kernel version:
Let us see all examples in detailed to check your version.
Ubuntu Show Version Number using /etc/os-release file
Type the following cat command:
$ cat /etc/os-release
NAME="Ubuntu" VERSION="18.04.1 LTS (Bionic Beaver)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 18.04.1 LTS" VERSION_ID="18.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=bionic
Here is another outputs:
NAME="Ubuntu" VERSION="20.04 LTS (Focal Fossa)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu Focal Fossa (development branch)" VERSION_ID="20.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=focal UBUNTU_CODENAME=focal
Checking your Ubuntu version From the lsb_release terminal command
The lsb_release command gives LSB (Linux Standard Base) and distribution-specific information on the CLI. The syntax is:
$ lsb_release -a
No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 18.04.1 LTS Release: 18.04 Codename: bionic
How to check Ubuntu version using the hostnamectl command
Not a fan of the Ubuntu command line? Try GUI
You can see Ubuntu version graphically, i.e. using GUI. Open System Settings by pressing the Super key on your keyboard and type “settings“. Click on Details. You will see version below Ubuntu Logo:
It is a good idea to check your Ubuntu version so that you can apply patches and update versions for security and performance reasons. Ubuntu release cycle is divided into two groups:
- LTS (Long Term Support) release, which is published every two years in April. For servers and stability reasons, you always need to use LTS.
- Interim release – Every six months Canonical releases a short version of Ubuntu, which is suitable for cutting edge hardware and desktop users.
You learned how to check your current Ubuntu version through the command-line and GUI. For more info see this page here.