User Tools

Site Tools


howtos:create_a_package_list

Intro

Reinstalling a machine it can be a pain to remember all the packages installed that must be installed again.

Here's a dirty description of how to make an install list.

Note this is done on a Ubuntu system.

Making the list

Not all software on the system is taken from the repositories and thus can't be used in the install script. So first find the software that must be excluded from the list.

Go into Synaptics and find the selection “Status” down in the left corner. Click on it and select “Installed (local or obsolete)”:

:howtos:screenshot-synaptic_package_manager_.png

This list of packages must be filtered out of the list. Here is a command creating a list and filtering out what I must download afterwards:

dpkg -l |grep '^ii '|sed -r 's/ii\s+(\S+)\s+.*/\1/i'|egrep -v  "zattoo|virtualbox|truecrypt|pytube|parcellite|opera|nxclient|flv2mpeg4|adobereader-enu"  > list.txt  

The part “egrep -v “zattoo|virtualbox….” is the list of software that I manually downloaded and installed on the system.

The file list.txt now contains the list of packages that was installed on the old system.

Using the list

Now to get all the software back on the new system, copy list.txt onto it and run:

sudo for i in `cat list.txt`; do apt-get install -y $i; done

Et voilà and your system is now a lot heavier with software LOL

Update: A quicker way of installing the software is to convert the list into one line see a description here.

sudo apt-get install -y `cat list.txt | tr "\n" " "`

list.txt

truecrypt-4.3a-ubuntu-7.10-x86.tar.gz

run.sh.txt

howtos/create_a_package_list.txt · Last modified: d/m/Y H:i (external edit)