LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   installing multiple packages at the same time (http://www.linuxquestions.org/questions/linux-newbie-8/installing-multiple-packages-at-the-same-time-912682/)

edier88 11-09-2011 12:57 PM

installing multiple packages at the same time
 
Ok folks, first, sorry if my english is not very good.
Im testing the new Ubuntu 11.10 with Unity, well, that's not the point, the point is that a realized a time ago that when im installing something I can't install other thing, I need to wait to install the first thing after installing the other.

An example, I entered in a terminal "sudo apt-get install ubuntu-restricted-extras" in order to get the restricted extras. Later in another terminal I entered "sudo apt-get install fping" and I got the next 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?

My question is: Can I install, use or do something in order to install many things at the same time?

Thank you ;)

angel115 11-09-2011 01:04 PM

You can put them all on the same line, one after another, like this:
Code:

sudo apt-get install fping apache2 mysql ubuntu-restricted-extras
and so on, just put a space between the packages.

Angel.

AwesomeMachine 11-09-2011 01:13 PM

You need to wait a few moments for the lock on the previous instance of dpkg to release. But unless I want to override a policy, such as remove individual games or utility front ends without removing the entire desktop GUI, I just use synaptic or dselect.

inoculos 11-09-2011 04:56 PM

just an add on to what's already been said, and I know it wasn't what was asked but...

Its a good idea to run sudo apt-get update before running install, you can just do this all in one command:

sudo apt-get update && sudo apt-get install fping apache2 mysql ubuntu-restricted-extras


All times are GMT -5. The time now is 12:16 AM.