Ubuntu – How to get a list of installed packages held back from upgrade

package-management

Recently, I needed to get a list of packages that were installed on my Ubuntu system which were also put on hold for upgrade.

The 'hold' status for a package means that when the operating system is upgraded, the installer will not upgrade these packages either, unless explicitly stated in the options.

I am looking for a command-line solution but understand this may be possible from the GUI as well.

Best Answer

You can use apt-mark:

apt-mark showhold

this will show the packages that are kept in "hold" state so that the pacakge manager won't auto upgrade the packages.

From man apt-mark:

showhold
           showhold is used to print a list of packages on hold