Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I need to replicate an Ubuntu server setup on 10-15 servers. I have a fresh Natty 64-bit server installed on a machine with all the extra required packages installed (no user data, system hasn't been used). What I need to do is to clone this machine to other servers in the easiest way possible.

I was thinking of using the remastersys tool to create an ISO image from the setup and install it on the machines. Is there a way that can help me automate this installation as much as possible, i.e. how can one install an ISO image to a large number of servers easily.

Thanks!

share|improve this question
    
Ken, you're right, how do I move it? –  recipriversexclusion May 19 '11 at 23:12
    
A mod should look at it sooner or later if it's been flagged. –  Mr E May 19 '11 at 23:43
add comment

migrated from stackoverflow.com May 21 '11 at 10:04

This question came from our site for professional and enthusiast programmers.

4 Answers

The usual answer to this sort of problem is to get a basic system installed as quickly as possible with as little manual intervention, then run the same apt-get install ... commands on all machines to get the packages synchronized on all of them. A local package mirror is an excellent way to improve installation speed on the other machines, and provides an easy place to store / distribution site-local packages.

But this only helps initial set up; you might wish to look into managing your configuration with puppet or chef. This lets you deploy and re-deploy servers or desktops with given configurations over and over again without much extra effort.

An excellent (if potentially dated, at this point) introduction to managing multiple machines is hosted by our friends at infrastructures.org.

share|improve this answer
add comment

Alternative:

dpkg --get-selections

and its opposite number

dpkg --set-selections

To set up the another machine with the same packages.

From the man page:

   --get-selections [package-name-pattern...]
          Get list of package selections, and write it to stdout.  Without
          a  pattern,  non-installed  packages (i.e. those which have been
          previously purged) will not be shown.

  --set-selections
          Set package selections using file read  from  stdin.  This  file
          should  be in the format '<package> <state>', where state is one
          of install, hold, deinstall or purge. Blank  lines  and  comment
          lines beginning with '#' are also permitted.
share|improve this answer
add comment

You can also use Mondo Rescue to clone your installation. It will create a bootable CD/clone of your installation and you can use that to install ther servers using it. I have used it and it works very well. Here's a howto:

http://www.mondorescue.org/docs/mondorescue-howto.html

share|improve this answer
add comment

If this is a long term thing, where you might need to install more computer or perhaps re-installed computer, you should maybe think about using the debian/ubuntu preseeding capabilities. This will give you the option to recreate the same configuration time and time again, with no need to run through any installation steps.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.