Home Ubuntu How To Check Available Version Of A Package In Ubuntu Repositories

How To Check Available Version Of A Package In Ubuntu Repositories

By sk
Published: Updated: 11.7K views

If you ever wondered how to check available version of a package in Ubuntu repositories, read on. It's not that difficult as you might think.

We can do this two methods.

  1. The command line way
  2. Graphical way

1. Check available version of a package in Ubuntu repositories from command line

This is the easiest and quickest way to find a package version from command line.

Open your Terminal, and run the following command:

$ apt-cache policy <packageName>

For example, let us find out all available versions of Chromium web browser from the Ubuntu repositories.

To do so, run:

$ apt-cache policy chromium-browser

Sample output:

chromium-browser:
 Installed: (none)
 Candidate: 65.0.3325.181-0ubuntu1
 Version table:
 65.0.3325.181-0ubuntu1 500
 500 http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages

As you see in the above output, the latest available version in the remote repository is 65.0.3325.181. This command also indicates in which repositories they are coming from.

You may wonder if the given package is installed or not. It's easy to find out too.

In the above output, you see two words namely Installed and Candidate.

  • Installed : This will tell you the version that you have currently installed in your Ubuntu system. So, in our case, I didn't install chromium browser in my Ubuntu, hence it shows none. If it is installed, you will the version number after the term "Installed".
  • Candidate : This is actual version that will be installed from the Ubuntu repositories when you install Chromium browser using apt-get.

Now let me check another package, say for example firefox.

$ apt-cache policy firefox

Sample output:

firefox:
 Installed: 59.0.2+build1-0ubuntu1
 Candidate: 59.0.2+build1-0ubuntu1
 Version table:
 *** 59.0.2+build1-0ubuntu1 500
 500 http://in.archive.ubuntu.com/ubuntu bionic/main amd64 Packages
 100 /var/lib/dpkg/status

See? I have installed Firefox in my Ubuntu and the currently installed version is 59.0.2.

Here is two more commands to check the package version from Ubuntu repositories.

$ apt-cache showpkg chromium-browser

The above command will display the complete details of the package version along with all dependencies.

Check available version of a package in Ubuntu repositories

Check available version of a package in Ubuntu repositories

Here is yet another command that displays the package version from Ubuntu repositories.

$ apt-cache madison chromium-browser

Sample output:

chromium-browser | 65.0.3325.181-0ubuntu1 | http://in.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages

Unlike the previous command, it will display the output in a neat format.

Well, now let us see the graphical way.

2. Check available version of a package in Ubuntu repositories from Ubuntu site

This method is for Ubuntu desktops. Open your web browser, and go to the following website.

Enter the name of the package version, and hit the Search button.

Search package details from Ubuntu website

Search package details from Ubuntu website

That's it. You'll see the available version of the package from the Ubuntu repositories.

Check available version of a package in Ubuntu repositories from Ubuntu site

Check available version of a package in Ubuntu repositories from Ubuntu site

This method has two advantages over the command line way.

First, We can search the package version for different Ubuntu releases. For example, you can search the available package version for a trusty version.

Search package version for specific Ubuntu release

Search package version for specific Ubuntu release

Second, you don't need an Ubuntu system. You can check the version from any distribution. All you need is an Internet connection, and a web browser.

You May Also Like

2 comments

jymm April 7, 2017 - 4:24 pm

Sudo apt-get install synaptic. There problem fixed.

Reply
Logik December 15, 2017 - 6:02 pm

Its not that easy. Some times the install command did not ask you for confirmation to istall package before installing it. So just to check version for package, you need not to install it, ehh??

Reply

Leave a Comment

* By using this form you agree with the storage and handling of your data by this website.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

This website uses cookies to improve your experience. By using this site, we will assume that you're OK with it. Accept Read More