Restore All Installed packages in Ubuntu server to new machine

I’ve recently had the occasion to make a complete list of software installed while upgrading our Ubuntu 8.04 LTS server to 10.04 LTS. It’s always safe to note down all the packages already installed in the server but  using this we can create a list of packages thats already installed.

This steps will help you to restore all your packages that were installed by creating a package list and uninstall all application installed after the list was made.

Getting Started !

Step 1
Use the following command to create a list of all the installed packages currently available

  sudo dpkg --get-selections > /etc/package.selections 

Step 2
Now our package list is ready and we can copy this file (package.selections) to your new machine

  sudo dpkg --set-selections < /etc/package.selections && apt-get dselect-upgrade 

This command will uninstall all packages installed after you created your restore list.

Done 🙂


Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )


Connecting to %s

Create a free website or blog at

Up ↑

%d bloggers like this: