DON'T PANIC

Install a list of packages with DPKG without effort

Posted on: April 11, 2011


Sometimes you have a computer with all necessary packages installed, then you have to install another one but it is tricky to pass by command line all packages!! so the old dpkg provides you a method to do that without effort. Enjoy it!

To make a local copy of the package selection states

root@buzz:~# dpkg --get-selections > packages_list_to_install

packages-list-to-install is a file with a complete list of all packages installed on the computer where you ran.

You might transfer this file to another computer, and install it there with:

root@squeeze:~# dpkg --clear-selections
root@squeeze:~# dpkg --set-selections < packages_list_to_install

To actually download and install the requested packages

root@squeeze:~# apt-get dselect-upgrade

Advertisements

2 Responses to "Install a list of packages with DPKG without effort"

>buzz
What’s the story behind this host name? Actully running buzz, once running buzz and upgraded many times since, or unrelated to debian naming schemes?

Buzz is just a host name for this example, it doesn’t have any relation to the topic. Instead of being “Buzz”, could be whatever name.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


  • None
  • analialorenzatto: Buzz is just a host name for this example, it doesn't have any relation to the topic. Instead of being "Buzz", could be whatever name.
  • fridelain: >buzz What's the story behind this host name? Actully running buzz, once running buzz and upgraded many times since, or unrelated to debian naming
  • Pratik: Nice, but I would change it to include more directories. Like my .mozilla and .kde4 by using .{config,mozilla,kde4} instead of just .config .

Categories

%d bloggers like this: