How to Disable Automatic update and upgrade – Ubuntu

1.Why we have to disable Automatic Update or Upgrade?

When you want to install any application you may get the below messages

root@ubuntu1804:~# sudo dpkg -i mysql-apt-config_0.8.15-1_all.deb

dpkg: error: dpkg frontend is locked by another process

it is because of periodic update running in the background.

Some update may cause to need your machine restart.

2. Disable Automatic Updates from Command Line

Edit /etc/apt/apt.conf.d/20auto-upgrades to disable automatic updates from the command line:

$ sudo nano /etc/apt/apt.conf.d/20auto-upgrades

Once you have the file opened, switch off the Update-Package-Lists directive from 1 to 0 as shown below

APT::Periodic::Update-Package-Lists “0”;

APT::Periodic::Unattended-Upgrade “0”;

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.