Putting packages on hold with apt on Debian


These 2 equal commands will make that package stay stuck in that version so you will have to take it off hold if you want to upgrade it:

echo "package hold" | dpkg --set-selections
apt-mark hold package

2 equal commands to take a package off Hold:

echo "package install" | dpkg --set-selections
apt-mark unhold package

2 commands to list packages on hold:

dpkg --get-selections | grep hold
apt-mark showhold