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

Mass install / Autoinstall (Was: Re: Debian vs Red Hat??? I need info.)



>>>>> "Jeremy" == Jeremy Hansen <jeremy@xxedgexx.com> writes:

    Jeremy> Autoinstall (Red Hat's kickstart)
    Jeremy> 	This is also something fairly important.  We need this as we do a
    Jeremy> 	lot of mass installs.

 The best way to do that that I've found so far is to set up a box
 with two removable hard drive racks, install and _configure_
 everything on one drive, then use `cfdisk', `mkswap', and `mke2fs' to
 partition and format the second drive.  Use `cpio' from a script to
 copy everything from the master drive to the copy, then run the
 appropriate Lilo command to make that copy bootable.  You can then
 mount it in another machine and it's ready to go.  You have to filter
 some things out when you copy.  See below.

 Another way to do it would be to create a tar archive, useing "find |
 grep -v -f exclude-patterns | cpio", name it `base2_2.tgz' and put it
 in place on an intranet web server where you can point the Debian
 installer's netfetch...  Then you can install several machines at
 once over the LAN... in theory.

 This is just a starter... I have not done this much yet myself, since
 I don't have extra hardware to work with and really need to spend my
 time on reading and studies.  I have done it from drive to drive
 using `cpio' to install the filesystem snapshot, but have not done it
 by naming a tar format archive as base and using the debian-boot
 installer.  It might just work.  NFS mounting the server directory
 where the `cpio' or `tar' archive sits might work fine also.

 You could burn a bootable CD with the archive on it, and on the
 bootable's root.bin, have `sfdisk' etc. and a script that automaticly
 partitions, formats, and installs the archive.  It might be simpler
 to try the netfetch/dbootstrap approach though.

 You can make a copy of the system like this... it will create a
 `cpio' archive... substitute `ustar' for `crc' to make a `tar'
 compatible archive.  RTFM's... you're on your own.

8<-------------------------------------------->8
#!/bin/bash
find / -print0 |
 grep --invert-match --extended-regexp --null-data --file=/root/make-tarball.exclude-patterns |
 cpio --create --format=crc --null --reset-access-time --block-size=10 |
 gzip --best > /tmp/system-snapshot_$(date +%Y.%m.%d).cpio.crc.gz
8<-------------------------------------------->8

 You may need to tweak this some.  (NO WARRANTEE)

 "make-tarball.exclude-patterns"
8<-------------------------------------------->8
^/proc/.*
^/tmp/.*
^/lost+found
^/boot/lost+found
^/var/cache/apache/.*
^/var/cache/apt/.*\.deb
^/var/log/.*\.log
^/var/log/\(amanda\|apache\|gdm\|ksymoops\|mailman\|news\|sendfile\|wu-ftpd\)/.*
^/var/log/\(syslog\|smb\|nmb\|messages\|mail\|lpr\|debug\|dmesg\).*
^/var/lock/\.LCK.*
^/var/run/.*\.pid
^/var/run/\(ndc\|utmp\)
^/var/samba/.*
\.bash_history
\.gnome-errors
.*~
/\.saves-.*
/\.#.*
/\.netscape/cache/.*

-- 
Those who do not study Lisp are doomed to reimplement it - Poorly.
A few months in the laboratory often saves several hours at the library.

mailto:karlheg@debian.org (Karl M. Hegbloom)



Reply to: