apt/preferences.d: A Useful Example
I used to use apt-mark to hold packages, but I never dug far enough to learn where it stores this state. I found a much easier way to hold a package: pin it in preferences!
Make a file, e.g. /etc/apt/preferences.d/krb5-auth-dialog
with contents:
Package: krb5-auth-dialog Version: 3.26.1-4 Pin: release Pin-Priority: 1000
So now apt-cache policy
shows the following:
$ apt-cache policy krb5-auth-dialog krb5-auth-dialog: Installed: 3.26.1-4 Candidate: 3.26.1-4 Version table: 43.0-1+b1 500 500 http://www.example.com/mirror/devuan ceres/main amd64 Packages *** 3.26.1-4 1000 500 http://www.example.com/internal/repo/devuan-deb Packages 100 /var/lib/dpkg/status
For the exact reason of this example package, see krb5-auth-dialog and the news.
Comments