Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I used the commands at the end of this article to try installing the restricted extras the article recommends. http://www.webupd8.org/2013/04/7-things-to-do-after-installing-ubuntu.html

sudo apt-get install ubuntu-restricted-extras

When I input this command in the terminal, I receive the following error message:

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?
rick@rick-XPS-L521X:~$ sudo apt-get install ubuntu-restricted-extras
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?
rick@rick-XPS-L521X:~$ sudo apt-get install libavformat-extra-53 libavcodec-extra-53
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?
rick@rick-XPS-L521X:~$ sudo apt-get install ubuntu-restricted-extras
[sudo] password for rick: 
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 first time I tried installing the restricted extras, the terminal brought me to a legal approval page which ended with no way to agree or not agree to the terms. So I exited and tried to install again but then received the error message. How do I fix this?

share|improve this question

marked as duplicate by Eliah Kagan, Mitch, Kevin Bowen, Alvar, Eric Carvalho Aug 17 '13 at 3:19

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

add comment

1 Answer 1

This either means that you are already running apt-get (could be via Software Center), or that the lock has not been properly been released last time.

If you are sure that no ongoing process is running you can try deleting the lock file.

share|improve this answer
    
How do i delete the lock file? –  Capitalism Prevails Aug 16 '13 at 22:00
    
sudo rm /var/lib/dpkg/lock You may need to run sudo apt-get update afterwards. –  l3dx Aug 17 '13 at 9:57
    
Also, check the duplicate's answer. –  l3dx Aug 17 '13 at 9:59
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.