Remove Package from Apt Update List
When using the Advanced Package Tool (APT) on your Linux system, you may encounter situations where you want to remove a package from the apt update list. This can be useful when you no longer need a specific package or when you want to prevent it from being updated automatically. In this article, we will guide you through the process of removing a package from the apt update list.
Step 1: Identify the Package
The first step is to identify the package you want to remove from the apt update list. You may already know the name of the package, or you can use the following command to list all the packages in the update list:
$ apt list --upgradable
This command will display a list of packages that have updates available. Look for the package you want to remove from the list.
Step 2: Remove the Package
Once you have identified the package you want to remove, you can proceed with removing it from the apt update list. Open a terminal and use the following command:
$ sudo apt-mark unhold <package-name>
Replace <package-name> with the actual name of the package you want to remove. This command will unhold the package, allowing it to be removed from the update list.
Step 3: Update the Package List
After removing the package from the update list, it is important to update the package list to reflect the changes. Run the following command to update the package list:
$ sudo apt update
This command will fetch the latest package information from the repositories and update the package list on your system.
Step 4: Verify the Removal
To ensure that the package has been successfully removed from the apt update list, you can run the following command:
$ apt list --upgradable
If the package you removed no longer appears in the list, it means that it has been successfully removed from the update list.
Conclusion
Removing a package from the apt update list is a simple process that can be done using a few commands in the terminal. By following the steps outlined in this article, you can easily remove a package from the update list and prevent it from being updated automatically.
References
| Source | Link |
|---|---|
| Ubuntu Documentation | https://help.ubuntu.com/community/AptGet/Howto |
| Debian Wiki | https://wiki.debian.org/Apt |