Some times there is a need to keep an installed package held back at a certain version. This can be acheaved by a number of ways. The easiest of which is to use apt-mark.

This tool (apt-mark) is included with all modern debian based distributions.

We are interested in the following three commands:

apt-mark hold [Package Name]

Marks a package as held back. This would stop it from being updated. This requires root access.

apt-mark unhold [Package Name]

Unsets a package set as held back. This requires root access.

apt-mark showhold

Prints the list of package on hold.


~$ sudo apt-mark hold vim
vim set on hold.
~$ apt-mark showhold
~$ sudo apt-mark unhold vim
Canceled hold on vim.
~$ apt-mark showhold