How to Check Ubuntu Version

How to Check Ubuntu Version

If you are using Ubuntu, it is important to know the version you are running. By knowing the version, you can determine if your system is up to date and if it is compatible with certain software. In this article, we will show you how to check your Ubuntu version using the command line.

Prerequisites

Before we proceed, ensure that you have access to a Ubuntu system and a terminal application.

Checking Ubuntu Version

To check your Ubuntu version, follow the steps below:

  1. Open a terminal application by pressing Ctrl+Alt+T or by searching for “Terminal” in the applications menu.
  2. Type the following command and press Enter:
    lsb_release -a

    This will display detailed information about your Ubuntu version, including the release number, codename, and description.

    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 20.04.2 LTS
    Release:        20.04
    Codename:       focal

    The lsb_release command stands for “Linux Standard Base Release,” which is a command-line tool that displays Linux distribution information.

  3. Alternatively, you can use the following command:
    cat /etc/os-release

    This will display similar information about your Ubuntu version.

    NAME="Ubuntu"
    VERSION="20.04.2 LTS (Focal Fossa)"
    ID=ubuntu
    ID_LIKE=debian
    PRETTY_NAME="Ubuntu 20.04.2 LTS"
    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

    The cat command is used to display the contents of a file, in this case, the /etc/os-release file, which contains information about the operating system.

Conclusion

In this article, we have shown you how to check your Ubuntu version using the command line. By knowing your Ubuntu version, you can ensure that your system is up to date and compatible with certain software. We hope that this article has been helpful, and if you have any questions or feedback, please leave a comment below.

Update Ubuntu

To update your Ubuntu system, you can use the following command:

sudo apt update && sudo apt upgrade

The sudo apt update command updates the package lists, while the sudo apt upgrade command upgrades the installed packages to their latest versions.

Ubuntu Release Schedule

Ubuntu releases a new version every six months, in April and October of each year. The long-term support (LTS) versions are released every two years, in April of even-numbered years. The LTS versions are supported for five years, while the regular versions are only supported for nine months.