Debian-Ubuntu How to not upgrade a package

How can you not upgrade a package or packages to Ubuntu / Debian Linux? How can you create a package update blacklist using the apt / apt-get command?

Below we will see how we can not upgrade packages using the apt, apt-mark option in Debian or Ubuntu Linux.

The apt-mark method works with installed and uninstalled packages.

We usually run the following two commands to update all packages:

sudo apt update && sudo apt upgrade
ή
sudo apt-get update && sudo apt-get upgrade

Let's see a list of available updates:

Run the apt command:

sudo apt list --upgradable

Now how can you force apt-get to keep a package named geany using apt-mark

The apt-mark booking option can be used as follows to prevent the package from being automatically installed, upgraded or removed:

sudo apt-mark hold package_name
sudo apt-mark hold geany

Display a waiting list of packages

How to view a waiting list of packages:

apt-mark showhold

Cancel waiting

Do you want to cancel a package you have specified in the list? Try:

sudo apt-mark unhold package_name
sudo apt-mark unhold geany

iGuRu.gr The Best Technology Site in Greeceggns

Get the best viral stories straight into your inbox!















Written by giorgos

George still wonders what he's doing here ...

Leave a reply

Your email address is not published. Required fields are mentioned with *

Your message will not be published if:
1. Contains insulting, defamatory, racist, offensive or inappropriate comments.
2. Causes harm to minors.
3. It interferes with the privacy and individual and social rights of other users.
4. Advertises products or services or websites.
5. Contains personal information (address, phone, etc.).