Home >System Tutorial >LINUX >Ubuntu finally supports disabling automatic updates of snap packages
snap is a software packaging and deployment system developed by Canonical for operating systems that use the Linux kernel and the systemd init system. These software packages, called snaps, and the tool that uses them, snapd, are available across a range of Linux distributions and allow upstream software developers to publish their applications directly to users.
With snap, users can easily install Linux applications. By default, snapd will check for updates four times a day and automatically update the snap application to the latest version. While there are many ways to control when and how often updates are installed, users cannot completely turn off automatic updates for security reasons.
Although the original intention of snap is good, many developers are deeply troubled by it. From time to time, they will find that commonly used development tools are automatically updated, resulting in incompatible plug-ins and dependencies, and they have to manually Fallback version. Because of this, the first thing many developers do after installing Ubuntu is to uninstall the snap.
Canonical announced today that it allows users to temporarily or permanently disable automatic updates for snap format packages. By default, snap packages are automatically updated to ensure that your application is always up to date.
However, due to the automatic update mode of the snap software package format, sometimes a certain software may become incompatible and unusable. The good news is that although Canonical now allows users to set temporary or permanent disabling, it does not support graphical operations and needs to be executed using the command line in the terminal.
We learned that, for example, if you want to temporarily disable automatic updates for the snap package of VLC media player, you can enter:
snaprefresh--hold=72hvlc
Then the output will be like this:
Generalrefreshesof"vlc"helduntil2022-11-17T12:04:59Z
If you want to temporarily disable the automatic update of the snap package, the command is:
snaprefresh--hold=48h
If you want to permanently disable the automatic update of the snap package, the command is:
snaprefresh--hold
On the contrary, Re-enable automatic updates with the --unhold parameter.
snap refresh --unhold
To re-enable automatic updates for a specific application, such as Firefox, just add the name to the command:
snap refresh --unhold firefox
This command does not currently appear in the official version of Ubuntu. If you If you want to try it, you need to switch snapd to the edge channel through the command:
snap refresh snapd --edge
After the test is completed, if you need to switch snapd back to the stable channel, you need to use the command:
snap refresh snapd --stable
The world has been suffering for a long time snap , but with the continuous improvement of the snap update mechanism, Ubuntu has finally added support for disabling automatic updates of snap applications. Will everyone give snap a chance?
The above is the detailed content of Ubuntu finally supports disabling automatic updates of snap packages. For more information, please follow other related articles on the PHP Chinese website!