User Tools

Site Tools


ubuntu_backup_all_package_selections

Take a backup of all installed packages

Use cases:

  1. You want to format to go from say x86 to amd64
  2. You want to copy an entire host and then copy your home folder to it (migration to a new machine)

Firstly, take a backup of software selections in dpkg:

   sudo dpkg --get-selections > ~/softwarelist

Install your new Ubuntu then:

   sudo dpkg --set-selections < ~/softwarelist
   
   sudo apt-get -f install

It might whinge about dependencies or other libs not installed if they came from elsewhere, but it should generally work if it's the same version of Ubuntu (say 16.04 to 16.04 and not 16.04 to 15.10).

ubuntu_backup_all_package_selections.txt · Last modified: 2017/03/22 23:19 (external edit)