Linux distribution package versions

Linux distribution package versions

NAME

apt-show-versions - Lists available package versions with distribution

DESCRIPTION

apt-show-versions parses the dpkg status file and the APT lists for the installed and available package versions and distribution and shows upgrade options within the specific distribution of the selected package. This is really useful if you have a mixed stable/testing environment and want to list all packages which are from testing and can be upgraded in testing. apt-show-versions uses caching for the status information of installed and available packages. If you run apt-show-versions as root the cache is updated as needed. If you run as non-root uses the newest available information, but can't update the cache. If you run as root with the option -i the cache is initialized or updated only.

SYNOPSIS

apt-show-versions [-h] [[-p] package name] [-a] [-b]

OPTIONS

If you don't give any options the status of all installed packages is printed. -p package, --package=package Print available and installed versions for specified package. You can also specify a package name without the option -p. If -p and a package name are missing, all installed packages are displayed. -r, --regex interpret package from option -p as a regex. -R, --regex-all like --regex, but also show matching packages which are not installed -u, --upgradeable Print only upgradeable packages -a, --allversions Print all available versions of the selected packages -b, --brief Print only package_name/distribution for upgradeable packages -v, --verbose Prints out messages about which Package files are parsed. -i, --initialize Initialize or update package cache only (as root). Do this every time when the status of the installed or available packages has changed. Initialization is done automatically on installation of the package and via a cron.daily job. -stf file, --status-file=file Use file as the dpkg status file instead of /var/lib/dpkg/status -ld directory, --list-dir=directory Use directory as path to apt's list files instead of /var/state/apt/lists/ or /var/lib/apt/lists/ -h, --help Prints out command-line help.

EXIT CODES

0 No error 1 Wrong usage 2 apt-show-versions has been called with exactly one package and upgradeable option set, but package is uptodate. As no output has been requested, this case gets signaled using the exit code. 255 Unspecified error

EXAMPLES

If you want to know for all your installed packages whether they are uptodate or upgradeable, use: apt-show-versions If you want to have a list of all upgradeable packages: apt-show-versions -u To get a list of all available versions of libc6: apt-show-versions -a -p libc6 To get information about several packages: apt-show-versions dpkg apt apt-show-versions -r ^texlive To upgrade all packages in testing: apt-get install `apt-show-versions -u -b | fgrep testing`

AUTHOR

SEE ALSO

© 2019 Canonical Ltd. Ubuntu and Canonical are registered trademarks of Canonical Ltd.

Читайте также:  Alt linux температура процессора

Источник

How can I check the available version of a package in the repositories?

How can I check the version of the available package in the Ubuntu repositories without installing it?

7 Answers 7

This gives you information of all available package versions.

alaa@aa-lu:~$ apt-cache policy vlc vlc: Installed: 2.0.8-0ubuntu0.13.04.1 Candidate: 2.0.8-0ubuntu0.13.04.1 Version table: *** 2.0.8-0ubuntu0.13.04.1 0 500 http://ae.archive.ubuntu.com/ubuntu/ raring-updates/universe i386 Packages 500 http://security.ubuntu.com/ubuntu/ raring-security/universe i386 Packages 100 /var/lib/dpkg/status 2.0.6-1 0 500 http://ae.archive.ubuntu.com/ubuntu/ raring/universe i386 Packages
  • From the output, you can see that there are two versions available: 2.0.8-0ubuntu0.13.04.1 and 2.0.6-1 . It also tells you which repositories they are coming from.
  • Installed: tells you the version you have installed. If you don’t have the package installed, you’ll see (none) .
  • Candidate: is the version that will be installed if you use apt-get install vlc . If you want to install the other version, you would do apt-get install vlc=2.0.6-1 .

Go to packages.ubuntu.com, fill in the search form and get a nice view of the package including the version.

enter image description here

enter image description here

Additional benefits

  • Will also list versions of packages for other versions of Ubuntu. Eg. if you want to know about the version of the package in Raring (13.04), but your system still has Precise (12.04), then this will provide a way to find it out.
  • You don’t even need Ubuntu to be installed.

Biggest downside is that it won’t list the versions of other repositories you possible have installed, such as PPAs. You will then need the apt-cache policy approach as already posted.

Pro tip

Take the shortcut — just browse to http://packages.ubuntu.com/packagename and replace packagename with the name of the package you want to query.

Читайте также:  Duckduckgo браузер для linux

It also gives information about all available package versions in the repositories. This command output had the syntax like this:

packageName | Version | Repository 

apt-cache’s madison command attempts to mimic the output format and a subset of the functionality of the Debian archive management tool, madison. It displays available versions of a package in a tabular format. Unlike the original madison, it can only display information for the architecture for which APT has retrieved package lists (APT::Architecture).

$ apt-cache madison chromium-browser chromium-browser | 32.0.1700.102-0ubuntu0.13.10.1~20140128.970.1 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy-updates/universe amd64 Packages chromium-browser | 32.0.1700.102-0ubuntu0.13.10.1~20140128.970.1 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy-security/universe amd64 Packages chromium-browser | 29.0.1547.65-0ubuntu2 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy/universe amd64 Packages chromium-browser | 29.0.1547.65-0ubuntu2 | http://archive.ubuntu.com/ubuntu/ saucy/universe amd64 Packages chromium-browser | 29.0.1547.65-0ubuntu2 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy/universe Sources chromium-browser | 32.0.1700.102-0ubuntu0.13.10.1~20140128.970.1 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy-updates/universe Sources chromium-browser | 32.0.1700.102-0ubuntu0.13.10.1~20140128.970.1 | http://mirror.sov.uk.goscomb.net/ubuntu/ saucy-security/universe Sources chromium-browser | 29.0.1547.65-0ubuntu2 | http://archive.ubuntu.com/ubuntu/ saucy/universe Sources chromium-browser | 29.0.1547.65-0ubuntu2 | http://archive.ubuntu.com/ubuntu/ saucy/universe Sources 

Источник

How to install specific version of some package? [duplicate]

Please do not vote to delete this post. It is useful as a signpost. Duplicates serve to guide others to the right Q&A.

2 Answers 2

How to know the version of installed package?

The above command will shows installed package version and also all the available versions in the repository according to the version of Ubuntu in which you are running.It doesn’t display the package version which was intended for another version of Ubuntu(not your’s).

Example:

$ apt-cache policy gparted gparted: Installed: 0.16.1-1 Candidate: 0.16.1-1 Version table: *** 0.16.1-1 0 500 http://ubuntu.inode.at/ubuntu/ saucy/main amd64 Packages 100 /var/lib/dpkg/status 

So the installed gparted version is 0.16.1-1 .

How to install a specific package version?

Example:

$ sudo apt-get install gparted=0.16.1-1 Reading package lists. Done Building dependency tree Reading state information. Done gparted is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 265 not upgraded. 

In every case I’ve ever tried this I always get the error The following packages have unmet dependencies: , followed by a list of packages. Any way to make it resolve that automatically?

Читайте также:  Linux mint стиль windows

Please note that it will most likely fail, because there is usually only 1 or 2 versions of the package that are available in the repository. If you want a different version than currently designed for your distribution, you might need to download it and install with sudo dkpg -i . Dependency errors need to be resolved by downloading and installing (also with dkpg ) all missing packages (this can take many iterations). Alternatively you can download the program source code, compile it and install it (this also requires manual dependency resolution).

Источник

Оцените статью
Adblock
detector