I used to put a custom build nginx as a deb package, but it was updated by apt and nginx could not be started, so I will write it as a memorandum.
Do it as root or run it with sudo.
apt-mark hold <package name>
** Example: **
apt-mark hold nginx
That way, running ```apt upgrade `` `will be ignored.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
nginx
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
With the same privileges as above.
apt-mark unhold <package name>
** Example: **
apt-mark unhold nginx
This will remove the deterrence.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:
nginx
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 851 kB of archives.
After this operation, 30.7 kB disk space will be freed.
Do you want to continue? [Y/n]
apt-mark showhold
Type this command to see the packages that are being suppressed.
If nothing is returned, there are no packages being suppressed.
Recommended Posts