Software Updates is capable of checking for updates and installing them without asking for a password except for kernel updates.

The same is not true for apt-get in a terminal. If you try to apt-get update without sudo you get an error: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied).

Is there a command you could run in terminal which permits updating without using sudo?

2 Answers 2


Software Updates uses aptdaemon to do all the work. You can do that from the command line using aptdcon:

Check for updates:

aptdcon --refresh

Install updates:

aptdcon --safe-upgrade
  • No longer available in my disco donkey repos
    – Ray Foss
    Commented Mar 12, 2021 at 1:57
  • @RayFoss Ubuntu 19.04 reached end-of-live on 2020-01-23. On supported Ubuntu versions aptdaemon is still available Commented Mar 12, 2021 at 9:41
  • Today years old when I learned about this. Commented Aug 23, 2023 at 22:19

open your sudoers file as sudo nano /etc/sudoers from your terminal and

Then do as

<your-username> ALL=NOPASSWD: sudo apt-get update

save & close.

Then check & If its asking same restart your PC and try again.

hope that helps.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .