Last active
December 16, 2021 10:13
-
-
Save aliabidzaidi/fd873021efc7f70d276a7128ce22848e to your computer and use it in GitHub Desktop.
Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied) [FIX]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied) | |
# E: Unable to lock directory /var/lib/apt/lists/ | |
# E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied) | |
# E: Unable to lock the administration directory (/var/lib/dpkg/), are you root? | |
sudo killall apt apt-get | |
# If none of the above works, remove the lock files. Run in terminal: | |
sudo rm /var/lib/apt/lists/lock | |
sudo rm /var/cache/apt/archives/lock | |
sudo rm /var/lib/dpkg/lock* | |
# then reconfigure the packages. Run in terminal: | |
sudo dpkg --configure -a | |
# and | |
sudo apt update |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment