[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Large scale installations of debian



On Thu, Jul 29, 1999 at 09:28:01AM +0200, Erik Bågfors wrote:
> Now to the large problem.  All debian packages can have install and
> uninstall scripts and alot of them do.  Alot of the scripts asks
> the user questions.  I've always liked this for my own computers but
> this is NOT practical if you want to install 20+ mashines for example.
> 
> The Debian-comunity should be very interested in being able to do large
> installations since this is something that will become more usual as
> more and more companis and schools will use Linux.
> 
> Is there any good way to solve this.  I've read about people doing
> tee pkg.log | dpkg -i pkg-xxx.deb and than installed the packages by doing
> dpkg -i pkg-xxx.deb < pgk.log on all the mashines that should have this
> package but I find this combersome.
> 
> What is your thoughts about this!?

Hi,

I'm working on a system for doing semi-automatic Debian installations (code 
name: deblab). It's more of a hack than an elegant solution but it works
for us (tm) in our department (Debian on Sparc, Alpha and i386, different
package lists for terminal and server).

Let me lay out the basic ideas:

* Install the base system via the usual installation mediums; that's the 
  reason why I call it semi-automatic; I'll take a look at the shell script
  Massimo Dal Zotto posted about some weeks ago to automate the first step too
* after the reboot you skip the profiles and the dselect step and log in as
  root
* get the autoinstallation tarball via ftp or nfs
* the following installation is done in three phases which are executed by a 
  simple bash script:

1. configure apt and install some necessary packages (I use cfengine and 
   expect as installation engines)
2. invoke cfengine to do some preinstallation e.g. install /etc/exim.conf 
   (exim skips the postinst if it finds a valid exim.conf), /etc/gpm.conf
   and similar cases
3. set the packages to install via dpkg --set-selections
4. start the installation via an expect-script which runs apt-get and answers
   the questions according to its data 
5. invoke cfengine to do the postinstallation (copying site-wide master 
   configuration files); e.g. hosts, hosts.allow, XF86Config, autofs, etc.
6. Voila, done ;-)

Several drawbacks:

- I didn't scan all installation scripts for interaction; I automated the 
  scripts from the packages we use; potential users should give me feedback
  which scripts are missing
- If it takes more than 8 minutes between two Setting up lines the expect
  script assumes that we are hanging because of a user interaction which 
  isn't automated yet and will give the keyboard control back to the user
  to answer the question; on slow machines this timeout is too short for 
  example when compiling the emacs calc package; after completing the user
  interaction expect resumes automatic mode
- it's not general enough yet and probably very fragile

What are the configuration files ?
You need templates for some of your config files like exim.conf, most config
files will be site-wide the same. You need a reference package list,
a simple text database of the answers for the expect script and a cfengine
configuration for later maintenance. 

I'll test the setup today and tomorrow in our department and could put
together a Debian package over the weekend if somebody is interested.
Note however that you should regard the package as an alpha thingie.
But perhaps we can get it in a more general usable state 'til the release
of potato.

Greetings,



				Christian
 
-- 
Christian Meder, email: meder@isr.uni-stuttgart.de
 
What's the railroad to me ?
I never go to see
Where it ends.
It fills a few hollows,
And makes banks for the swallows, 
It sets the sand a-blowing,
And the blackberries a-growing.
                      (Henry David Thoreau)
 


Reply to: