search | index | tags | login/register

backup installed dpkg packages to file (by damian)

* Get selections to stout:
dpkg --get-selections

* Save package list in file:
dpkg --get-selections > media:packages.txt

* Restore selections from file:
dpkg --set-selections < packages.txt
--OR --
cat media:packages.txt > dpkg --set-selections

* Update system:
sudo apt-get dselect-upgrade


***



To make a local copy of the package selection states:
$ dpkg --get-selections "*" >myselections # or use \*
"*" makes myselections include package entries for "purge" too.
You transfer this file to another computer, and install it there with: # apt-get update
  # dpkg --set-selections <myselections
 # apt-get -u dselect-upgrade


Tags:
#apt #backup #clone #config #configuration #dpkg #export #get-selections #linux #management #package #restore #save #selected #selections #set-selections #software #system

Info:
Attribute(s): Public
Created: 02.02.2012 21:50   Total Views: 313
Last Changed: 05.04.2013 12:41   Total Changes: 4
Δt = 0.077653169631958s