Ubuntu: I downloaded a package and all of its dependencies, how can I easily install them all at once?


I downloaded .deb packages with their dependencies.

How could I install it once? Like automically searches for its dependencies on my library.


I downloaded .deb packages with their dependencies... How could I install it once?

You can use 1 installation instruction with the package names divided by a "space".


 dpkg -i first.deb second.deb third.deb  

You can also install all .DEBs in a directory with ...

dpkg -R --install packages/  

If packages/ has first.deb second.deb third.deb it will install them all.

This will not "automically searches for its dependencies on my library...". It will install the packages listed; nothing more. It is you who needs to make sure the dependencies are all downloaded too.

There is a tool to help you with dpkg called "gdebi". Installation:

sudo apt-get install gdebi-core  

You can install .deb packages like this ...

sudo gdebi /path/to/filename.deb  

and it will also try to install dependencies.

And do not forget: when you get a broken package warning due to above: sudo apt-get -f install will fix most of those (if not all)


If all deb's with dependencies are exist in one directory then you can install as below.

Open terminal (Ctrl+Alt+T) and change to directory (cd <path/to/directry>) containing all .deb's and install by following command:

sudo dpkg -i *.deb  

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »