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

2000-05-23 Thread I. Forbes
Hello All

There is definitately some scope for development in this area.  
Debian is one of the best distro's to maintain but it is one of the 
worst to install.  These advantages and disadvantages are 
multiplied when you have many machines to maintain.

On 17 May 00, at 21:55, Karl M. Hegbloom wrote:

  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.
 
 88
 #!/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
 88

I tried this to create a custom base2_2.tzg with reasonable results.

First problem is that we need a tar file and not a cpio one.  Cpio's 
tar format does not support block devices so the whole /dev/ 
directory gets broken.  Then I tried ustar.  This worked better but 
still has some limitation on file name length.  A few files in 
/var/state/apt/lists/* were too long - not a major trainsmash.  

I wasted a few hours trying tar instead of cpio.  It seems not to be 
able to backup a directory, without backing up the contents of that 
directory, this is a problem with things like /var/cache/apt/archives.  
Maybe a real find/grep/tar guru could get it right but I went back to 
Karl's script  :-)

I still have some bugs.  After the base install lilo would not run 
(something broken with vmlinuz softlink).  Then when the new 
system is rebooted it went into a loop asking about shadow 
passwords etc.  I eventually replaced the /etc/inittab.  Bug 
squashing is a slow process ...  a full test cycle requires a backup 
and a new installation.  

This seems a viable method of setting up a mass install system.  
After I got things going I used Midnight Commander to do some 
global searches and replaces in /etc to sort out things like domain 
names and ppp accounts etc and then I had a system ready to run 
with exim, squid, dns ,ppp, diald, mgetty, calamaris, dhcp, apache, 
ftp, ipchains, samba, uucp, fetchmail etc all working!  Best of all it is 
a fully compliant Debian system, so apt-get update| apt-get 
upgrade also works!  

Next step may be to modify the dinstall program.

Question:  Is'nt there a deb package with scripts for creating boot 
disks?  I feel I should not be reinventing the wheel.

Another question:  Which list should we be discussing this?  Karl's 
original messages was sent to a whole bunch of lists?

My modified scripts are as follows (mind the line wrapping):

#! /bin/bash
find / -print0 |
 grep --invert-match --extended-regexp --null-data --
file=/root/config/exclude-pattern |
 cpio --create --format=ustar --null --reset-access-time --block-
size=10 |
 gzip --best  /tmp/base2_2-$(date +%Y.%m.%d).tgz

^/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\|sendfil
e\|wu-ftpd\)/.*
^/var/log/\(syslog\|smb\|nmb\|messages\|mail\|lpr\|debug\|dmesg\).*
^/var/lock/.*
^/var/run/.*\.pid
^/var/run/\(ndc\|utmp\)
^/var/samba/.*
^/var/spool/squid/.*/.*/.*
\.bash_history
\.gnome-errors
.*~
/\.saves-.*
/\.#.*
/\.netscape/cache/.*
^/etc/modules
^/etc/hostname
^/etc/hosts
^/etc/networks
^/etc/resolv.conf
^/etc/modutils/
^/etc/apm/event.d/pcmcia
^/etc/init.d/pcmcia
^/etc/pcmcia/
^/etc/network/interfaces
^/tmp/


Ian Forbes

-
Ian Forbes ZSD
http://www.zsd.co.za
Office: +27 +21 683-1388  Fax: +27 +21 64-1106
Snail Mail: P.O. Box 46827, Glosderry, 7702, South Africa
-




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

2000-05-19 Thread Santiago Palmier Campos
Long time ago in the past '[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]' wrote

 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.

You can't do that, I've tried it before.  Lilo can't be installed on any
secondary disk.  Don't ask me why because I don't know.  There's a HOWTO
about it.

--

Hi to * ! 

( First of all, sorry for my english :)

IMHO LILO can be installed on secondary disks ( and on the first sector of a
bootable partition also ). Let me explain myself:

I have 2 HDD at home, one ( /dev/hda ) with M$ Win 95  WinNT 'PlayStation'
( Job reasons :o( ) and the other ( /dev/hdc ) with Debian Hamm ( 'So old'
I know ;oD I'm try to upgrade but... unfortunately 'time is no friend of
mine' :(  ).

I use (Commercial SW) V Communications' System Commander (
http://www.v-com.com/ ) to boot my machine with Linux and (gasp!) with M$
Win XX, and it works fine for me! 

LILO was installed on MBR of the secondary disk ( /dev/hdc ), it shows an
alert 'LILO is not installed on primary disk' or something like that... but
it runs ;)

Try to add these lines  ( don't remember exactly, I'm at the office right
now ) to your /etc/lilo.conf:

...
...
boot=/dev/hdc   # my 2nd HDD
...
...
image=/boot/vmlinuz
label=linux
root=/dev/hdc1  # or whatever your partition is ;o)
read-only

I'm no Linux guru, so please correct me if I've misunderstood you or I'm
wrong with anything.

Regards from Spain, Santy #;oD 

--  
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact
[EMAIL PROTECTED]




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

2000-05-18 Thread Karl M. Hegbloom
 Jeremy == Jeremy Hansen [EMAIL PROTECTED] 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.

88
#!/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
88

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

 make-tarball.exclude-patterns
88
^/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:[EMAIL PROTECTED] (Karl M. Hegbloom)




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

2000-05-18 Thread Bulent Murtezaoglu
[...]
KMH  The best way to do that that I've found so far is to set up
KMH a box with two removable hard drive racks, install and
KMH _configure_ everything on one drive, then use `cfdisk',
KMH `mkswap', and `mke2fs' to partition and format the second
KMH drive.  
[...]

I do a possibly non-kosher thing similar to the above.  I tar
everything up once it is set up and stick the tar file[s] into a 
SCSI drive.  I have a box that boots from this SCSI drive and has
IDE drawers and a kernel with IDE support built as modules.  I then
hot-swap IDE drives, sfdisk, mke2fs, mount and un-tar without bringing
down the machine.  Insmoding the ide modules after switching the
drives on and rmmoding before removing them seems to work fine.
Never lost a drive yet, but the largest drives I worked with under
this scheme were 4.3G.  With the newer/larger drives, you'd probably 
need to make sure LILO and the BIOS agree on a geometry for the drive 
to be actually bootable (dunno the incantation for that yet!).

cheers,

BM  



 




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

2000-05-18 Thread Jeremy Hansen

Most of the answers I've been getting on this subject seem like total
hacks, which may work but really are tricks to doing this.  I was really
looking for something within debian that's built to do kickstart type
installations.

Although what you suggest may work, it leave little flexibility between
machines and also takes a lot more work then I was hoping to do.

For example, I have 20 machines at a co location I need to go install.  
Right now with Red Hat I can take my laptop, slap a floppy in each
machine, turn 'em on, 5 minutes later I have 20 fully configured machines
ready to rock.  Also if I use DHCP and place my kick start config file on
the server, I could literally have 20 different configurations for each
machine and never have to touch a key.  This is a part of Red Hat, no
tricks have to be done, all you need is a proper ks.cfg file and a central
place where the distro comes from, usually over nfs for convenience.  YOu
can't beat that when doing large installations.  To do what I need to do
in Debian seems that it would take a very long time, even hours, which is
not fun if you've ever spent time at a co location.

It seems a lot of Debian users are developers and in this case I'm sure
Debian is perfect, but Red Hat's kickstart allows me to see my wife at
night (not really, but you know what I mean).

-jeremy

  Jeremy == Jeremy Hansen [EMAIL PROTECTED] 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.
 
 88
 #!/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
 88
 
  You may need to tweak this some.  (NO WARRANTEE)
 
  make-tarball.exclude-patterns
 88
 ^/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/.*
 
 

-- 

http://www.xxedgexx.com | [EMAIL PROTECTED]
-




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

2000-05-18 Thread Mike Bilow
Are you aware of this?

http://www.informatik.uni-koeln.de/fai/

-- Mike


On 2000-05-18 at 13:55 -0400, Jeremy Hansen wrote:

 It seems a lot of Debian users are developers and in this case I'm sure
 Debian is perfect, but Red Hat's kickstart allows me to see my wife at
 night (not really, but you know what I mean).





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

2000-05-18 Thread Adam Di Carlo

I would agree most of the proposed solutions are quick hacks.

The fact is, we won't be natively supporting bulk installation until
Woody.  And even that  is in question.  As I understand it, the
proposed Woody install system is debconf based; moreover, debconf can
have different backends for receiving configuration info, for
instance, an LDAP backend, or a backend that munges an XML file from a
web server.

Yes, vapor vapor vapor but that's the right way to do it if you ask
me.  Hopefully debconf will be _de rigeur_ for any package requiring
configuration info at pkg install time in Woody, so what we would have
is really a general solution rather than just a partial or hack
solution.

-- 
.Adam Di [EMAIL PROTECTED]URL:http://www.onShore.com/




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

2000-05-18 Thread Mike Bilow
Agreed that this seems technically sound, but it would be really nice to
have this Real Soon Now.  I think it might be reasonably possible to
backport this from Woody into Potato fairly soon after the release of
Potato.  The fact is that an automatic installation system will be really
hard to test on the unstable tree.  I am not proposing that something like
this should really be called stable, but if it could be made compatible
with the stable distribution (then Potato) that would be very helpful.

-- Mike


On 2000-05-18 at 19:32 -0400, Adam Di Carlo wrote:

 The fact is, we won't be natively supporting bulk installation until
 Woody.  And even that  is in question.  As I understand it, the
 proposed Woody install system is debconf based; moreover, debconf can
 have different backends for receiving configuration info, for
 instance, an LDAP backend, or a backend that munges an XML file from a
 web server.





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

2000-05-18 Thread Craig Sanders
On Thu, May 18, 2000 at 01:55:37PM -0400, Jeremy Hansen wrote:
 Most of the answers I've been getting on this subject seem like
 total hacks, which may work but really are tricks to doing this.  I
 was really looking for something within debian that's built to do
 kickstart type installations.

huh? what do you think kickstart is? it's the same kind of total hack
- the difference is that you have to do it RedHat's way whether you like
it or not, and it pretends to be easy enough to use that you don't need
to know what you're doing to run it.

personally, i think that anyone who needs to mass-build machines
*SHOULD* know exactly what they are doing. i wouldn't trust any machine
built by someone who needed such point-and-click tools.

 Although what you suggest may work, it leave little flexibility
 between machines and also takes a lot more work then I was hoping to
 do.

actually, it leaves a lot of flexibility between machines. use ed or
'perl -i' scripts to automatically edit config files in place.

 For example, I have 20 machines at a co location I need to go install.
 Right now with Red Hat I can take my laptop, slap a floppy in each
 machine, turn 'em on, 5 minutes later I have 20 fully configured
 machines ready to rock.

you can do the same thing with debian...just install the nfs server
package on your laptop.

craig

--
craig sanders




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

2000-05-18 Thread Chris Wagner
At 09:55 PM 5/17/00 -0700, Karl M. Hegbloom wrote:
 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.

You can't do that, I've tried it before.  Lilo can't be installed on any
secondary disk.  Don't ask me why because I don't know.  There's a HOWTO
about it.

+---+
|-=I T ' S  P R I N C I P L E  T H A T  C O U N T S=-   |
|=-  -=ALAN KEYES FOR PRESIDENT=- -=|
| Balanced Budgets Personal Freedoms Morality Lower Tax |
|=--  http://www.Keyes2000.com.  --=|
+———+




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

2000-05-18 Thread Chris Wagner
If kickstart is a red hat package, you can install it on debian using alien.
Then you can use red hat's kickstart to install debian. :)

At 01:55 PM 5/18/00 -0400, Jeremy Hansen wrote:
Most of the answers I've been getting on this subject seem like total
hacks, which may work but really are tricks to doing this.  I was really
looking for something within debian that's built to do kickstart type
installations.

Although what you suggest may work, it leave little flexibility between
machines and also takes a lot more work then I was hoping to do.

Only for the initial setup.  Once your base install is made, a few scripts
written, it can become 100% automatic.  It's just not 100% automatic out of
the box.

+---+
|-=I T ' S  P R I N C I P L E  T H A T  C O U N T S=-   |
|=-  -=ALAN KEYES FOR PRESIDENT=- -=|
| Balanced Budgets Personal Freedoms Morality Lower Tax |
|=--  http://www.Keyes2000.com.  --=|
+———+




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

2000-05-18 Thread Jeremy Hansen

Hmm, I don't agree here.  Kickstart is a way of automating the tasks
already involved with a manual install.  It does what it's supposed to do
quite well and actually with the flexibility available, I rarely encounter
a situation that requires more custom things.  Hacks can be included in
kickstart during the %post procedure where you can basically write your
script to do whatever.  I've been using Linux long enough that I don't
need to use the hacker way around things for all purposes.

For me it's the bottom line.  Kickstart lets me setup a lot of machines
very quickly with pretty much limitless control over each
install.  Kickstart is part of anaconda and it is design for what it does,
slapping cpio tar and all the other tools you can pass an argument to is
just a mess.

-jeremy

 On Thu, May 18, 2000 at 01:55:37PM -0400, Jeremy Hansen wrote:
  Most of the answers I've been getting on this subject seem like
  total hacks, which may work but really are tricks to doing this.  I
  was really looking for something within debian that's built to do
  kickstart type installations.
 
 huh? what do you think kickstart is? it's the same kind of total hack
 - the difference is that you have to do it RedHat's way whether you like
 it or not, and it pretends to be easy enough to use that you don't need
 to know what you're doing to run it.
 
 personally, i think that anyone who needs to mass-build machines
 *SHOULD* know exactly what they are doing. i wouldn't trust any machine
 built by someone who needed such point-and-click tools.
 
  Although what you suggest may work, it leave little flexibility
  between machines and also takes a lot more work then I was hoping to
  do.
 
 actually, it leaves a lot of flexibility between machines. use ed or
 'perl -i' scripts to automatically edit config files in place.
 
  For example, I have 20 machines at a co location I need to go install.
  Right now with Red Hat I can take my laptop, slap a floppy in each
  machine, turn 'em on, 5 minutes later I have 20 fully configured
  machines ready to rock.
 
 you can do the same thing with debian...just install the nfs server
 package on your laptop.
 
 craig
 
 --
 craig sanders
 
 
 --  
 To UNSUBSCRIBE, email to [EMAIL PROTECTED]
 with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
 

-- 

http://www.xxedgexx.com | [EMAIL PROTECTED]
-




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

2000-05-18 Thread Jeremy Hansen

Well it's funny you brought that up because I was considering just making
one huge rpm of debian and then using kickstart.  Kickstart is a part of
Red Hat's install, Anaconda, not really an rpm but I get your point.

-jeremy

 If kickstart is a red hat package, you can install it on debian using alien.
 Then you can use red hat's kickstart to install debian. :)
 
 At 01:55 PM 5/18/00 -0400, Jeremy Hansen wrote:
 Most of the answers I've been getting on this subject seem like total
 hacks, which may work but really are tricks to doing this.  I was really
 looking for something within debian that's built to do kickstart type
 installations.
 
 Although what you suggest may work, it leave little flexibility between
 machines and also takes a lot more work then I was hoping to do.
 
 Only for the initial setup.  Once your base install is made, a few scripts
 written, it can become 100% automatic.  It's just not 100% automatic out of
 the box.
 
 +---+
 |-=I T ' S  P R I N C I P L E  T H A T  C O U N T S=-   |
 |=-  -=ALAN KEYES FOR PRESIDENT=- -=|
 | Balanced Budgets Personal Freedoms Morality Lower Tax |
 |=--  http://www.Keyes2000.com.  --=|
 +———+
 
 
 

-- 

http://www.xxedgexx.com | [EMAIL PROTECTED]
-




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

2000-05-18 Thread Karl M. Hegbloom
 Craig == Craig Sanders [EMAIL PROTECTED] writes:

 For example, I have 20 machines at a co location I need to go install.
 Right now with Red Hat I can take my laptop, slap a floppy in each
 machine, turn 'em on, 5 minutes later I have 20 fully configured
 machines ready to rock.

Craig you can do the same thing with debian...just install the nfs server
Craig package on your laptop.

 I think that with `Woody' we'll have something as good as or better
 than KickStart.  Read up on `debconf', and think about what I said
 about creating a custom Debian `baseX_X.tgz'.

-- 
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:[EMAIL PROTECTED] (Karl M. Hegbloom)