1

Possible Duplicate:
Fixing “Could not get lock /var/lib/dpkg/lock”

I get a dpkg is locked error even after a reboot??? i can't do any apt-get related commands

E: Could not lock /var/lib/apt/lists/lock is not available - open (11:Resource is temporarily unavailable) 
E: The directory /var/lib/apt/lists/ not lock
E: Could not lock /var/lib/dpkg/lock is not available - open (11: Resource is temporarily unavailable) 
E: Can beheersmap (/var/lib/dpkg/) not lock. Is it in use by another process?

(dutch ubuntu above err code has been translated with Google tranlsater)


update
I found the bug that caused this
i added a ppa that had Foxit Reader (PDF reader) installer in its repository.
the installer tries to download from a link that is dead and it continues to
download it. i have no patient i CTRL-Z/C/X. it then paused the installer. and then remaind locked.

do as @izx says

sudo rm -f /var/lib/apt/lists/lock

and then

sudo dpkg --configure -a

then also

sudo apt-get install -f

Remove the ppa from software-sources and then run in terminal

sudo apt-get purge foxit-installer

and just in case you want to clean everything.

run these

sudo apt-get update
sudo apt-get autoremove
sudo apt-get check
sudo apt-get clean
sudo apt-get autoclean
blade19899
  • 26,704

0 Answers0