Recording and copying system configuration in Debian/Ubuntu

July 9, 2010 at 7:03 pm | DEBIAN/UBUNTU, HOW-TOS | 2 comments

debianYou can make a local copy of the package and debconf selection states using dpkg and debconf-get-selections command. The debconf-get-selections command output the content of current debconf database.

You will require the “debconf-utils” packages to do that.

Install debconf-utils:

$ sudo aptitude install debconf-utils
$ sudo dpkg --get-selections '*' > selection.dpkg
$ sudo debconf-get-selections    > selection.debconf

Here, “*” makes “selection.dpkg” to include package entries for “purge” too.

You can transfer these 2 files to another computer, and install there with the following.

$ sudo dselect update
$ sudo debconf-set-selections < myselection.debconf
$ sudo dpkg --set-selections  < myselection.dpkg
$ sudo apt-get -u dselect-upgrade    # or dselect install

If you are thinking about managing many servers in a cluster with practically the same configuration, you should consider to use specialized package such as fai to manage the whole system.

Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • Reddit
  • StumbleUpon
  • Technorati
  • Yahoo! Bookmarks
  • Twitter
  • Blogosphere News
  • FriendFeed
  • FSDaily
  • Yahoo! Buzz

Related posts:

  1. Automatic download and upgrade of packages In Debian/Ubuntu
  2. Using The Debian Alternatives System
  3. Purge Removed Packages On Ubuntu/Debian
  4. Basic Package Management Operations Using Aptitude
  5. Keep Track Of Configuration Changes Using etckeeper

Tags: , ,

2 Responses to “Recording and copying system configuration in Debian/Ubuntu”

  1. TheGZeus says:

    This isn't really system configuration, just the sum total of a given system's packages.
    You also need apt's config files, etc.

    But really, it might be better to be using dd for a cluster of nigh-identical machines. Install once, copy many.
    Be nice to Debian's servers, they're free.

  2. [...] Recording and copying system configuration in Debian/Ubuntu [...]

Leave a Reply

Sponsors