When you press Ctrl – C to interrupt a process in the middle of the an apt-get task, you often get this error, and you cannot use apt-get anymore, because the system thinks that another process is using apt-get and it locks it:
E: Could not get lock /var/lib/dpkg/lock -- open (11 Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?
The quick and dirty solution for fixing the problem is to delete the /var/lib/dpkg/lock file, like this:
$ sudo rm -rf /var/lib/dpkg/lock
Actually I tried that! But it didnt help!
Instead I tried to grep the dpkg process, and killed the process id with kill -9 ‘pid’.
For Ubuntu 13.04:
sudo dpkg –configure -a