From owner-freebsd-config@FreeBSD.ORG Sat Aug 2 11:50:17 2003 Return-Path: Delivered-To: freebsd-config@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 68FB937B401 for ; Sat, 2 Aug 2003 11:50:17 -0700 (PDT) Received: from mail.speakeasy.net (mail12.speakeasy.net [216.254.0.212]) by mx1.FreeBSD.org (Postfix) with ESMTP id BE74043FE5 for ; Sat, 2 Aug 2003 11:50:16 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (qmail 833 invoked from network); 2 Aug 2003 18:50:15 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender )encrypted SMTP for ; 2 Aug 2003 18:50:15 -0000 Received: from laptop.baldwin.cx (laptop.baldwin.cx [192.168.0.4]) by server.baldwin.cx (8.12.9/8.12.9) with ESMTP id h72IoB9s009392; Sat, 2 Aug 2003 14:50:11 -0400 (EDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.4 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <20030801200829.GA23119@silence.syrah.us> Date: Sat, 02 Aug 2003 14:50:32 -0400 (EDT) From: John Baldwin To: Matthew cc: freebsd-config@freebsd.org Subject: RE: Extending sysinstall a la Kickstart X-BeenThere: freebsd-config@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Installation and Configuration List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Aug 2003 18:50:17 -0000 On 01-Aug-2003 Matthew wrote: > Hello, > > I'm a new freebsd user. I recently switched from (RedHat) > Linux for various reason. > > Is anyone aware of a a "Kickstart" equivalent for FreeBSD? > > RedHat's Kickstart system allows you to automate the install > process. You make a single install floppy, stick it in the floppy > drive, turn on (or reboot) the computer, wait 5 to 20 minutes > (depending upon the size of the install), remove the floppy, and then > reboot into a freshly installed OS. > > (Alternatively, you can have the Kickstart process rewrite the > floppy, turing it into a book disk. In this case, you don't need to > remove the floppy, and Kickstart can then automatically reboot the > machine when installation is complete. In this scenario, you can > leave floppies sitting in remote, network accessible machines. When > you want to reinstall the OS on them, you write a Kickstart image to > the floppy, reboot the server, and then simply wait, all of which can > be done remotely over the network.) > > I've done a lot of searching for Kickstart equivalents for > FreeBSD, and it looks like the closest thing is /stand/sysinstall's > scripting capabilities. > > I'm planning on extending /stand/sysinstall to increase the > degree to which installation can be automated. Specficially: > > * Hard drive partitioning. I can press "A" both during the > primary ("slice level"?) and secondary ("partition level"?) > partitioning during a manual install. However, I cannot currently > script secondary level "auto" partitioning. > > * Network configuration. I can manually configure the network > interface via sysinstall. But I cannot automate this process unless: > 1. I use DHCP > 2. I know the name of the ethernet device > > I want to be able to specify, via a script, the IP address, > host name, domain, netmask, etc. I also to specify, via a script, > that I don't know the ethernet device name so sysinstall should just > use the first ethernet device it finds. I recognize that sysinstall > cannot always autodetect the ethernet device, so the script will fail > in these cases. > > I'm pretty confident that make these extensions to sysinstall, > as they are simply extensions which allow the scripts to access > already extant sysinstall functionality. > > I'd like to make them in such a way that they can be merged > into the FreeBSD project so that others have easy access to them. Are > there any guidelines I should follow? I searched the handbooks for > instructions and guidelines on becoming a FreeBSD developer, but > didn't find anything. Perhaps I missed it? > > I'm planning on modifying sysinstall in 4-8-stable. It looks > like sysinstall has recently moved from /usr/src/release/sysinstall to > /usr/src/usr.sbin/sysinstall? Have there been other significant > changes to sysinstall recently? Your best bet is to make use of shell scripts that generate config files. This is what I do to accomplish similar tasks, thus, you can do: install.cfg ------------ command=sh /stand/installtype.sh system config=installtype.cfg LoadConfig and have installtype.sh generate installtype.cfg on the fly. I added dialog to the /stand crunchgen and used this sort of thing to reduce the install for our custom boxes at work down to a couple of simple menus for the common cases. sysinstall's scripting support is quite braindead, and a better solution is not to keep hacking on it I think, but to embed a real scripting language like python into sysistall. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/