From owner-freebsd-doc Tue Oct 15 13: 1:37 2002 Delivered-To: freebsd-doc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2EF6237B401 for ; Tue, 15 Oct 2002 13:01:33 -0700 (PDT) Received: from mail.ruhr.de (in-ruhr4.ruhr.de [212.23.134.2]) by mx1.FreeBSD.org (Postfix) with SMTP id 8C08E43E9C for ; Tue, 15 Oct 2002 13:01:31 -0700 (PDT) (envelope-from ue@nathan.ruhr.de) Received: (qmail 22552 invoked by uid 10); 15 Oct 2002 19:54:49 -0000 Received: from nathan.internal (localhost [127.0.0.1]) by nathan.internal (8.12.6/8.12.6) with ESMTP id g9FJwnp7076831 for ; Tue, 15 Oct 2002 21:58:49 +0200 (CEST) (envelope-from ue@nathan.internal) Received: (from ue@localhost) by nathan.internal (8.12.6/8.12.6/Submit) id g9FJwn8H076830 for freebsd-doc@freebsd.org; Tue, 15 Oct 2002 21:58:49 +0200 (CEST) Date: Tue, 15 Oct 2002 21:58:49 +0200 From: Udo Erdelhoff To: freebsd-doc@freebsd.org Subject: Please review: new handbook chapter on serial install Message-ID: <20021015195849.GA76747@nathan.internal> Mail-Followup-To: freebsd-doc@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi, the chapter about using a serial console lacks one important feature: A description how to install FreeBSD with a serial console. As I had to re-install one of my boxes today anyway, I recorded what needs to be done and turned it into sgml. Here's the result: Index: chapter.sgml =================================================================== RCS file: /home/ncvs/doc/en_US.ISO8859-1/books/handbook/serialcomms/chapter.sgml,v retrieving revision 1.66 diff -u -r1.66 chapter.sgml --- chapter.sgml 30 Sep 2002 15:33:26 -0000 1.66 +++ chapter.sgml 15 Oct 2002 19:47:57 -0000 @@ -2609,6 +2609,135 @@ attach a monitor into it. You might also try installing an AMI BIOS. + + + + + Udo + Erdelhoff + Contributed by + + + + Using a Serial Console to Install FreeBSD + + With only a little bit of work, it is also possible to + install a FreeBSD system over a serial + console. Of course, you will have to prepare your BIOS first + to be able to boot without a keyboard (or even without a + graphics adapter). You will have to configure it to try to + boot from floppy before it tries to boot from hard disk. This + cannot be done over a serial console on most PC + mainboards. + + The secret of installing FreeBSD over a serial console is + the fact that even the boot loader and the kernel used on the + installation floppies support a serial console, just like + their big counterparts that are installed on your hard disk. + In other words, all you have to do is to create a + boot.config file on the boot medium. In + theory, this could be a remotely mounted root file system for + a diskless installation, a modified installation CD/DVD, or a + modified boot floppy. The easiest solution (and the only one + described in this chapter) is to create a modified boot floppy + because this can be done with the on-board tools of a standard + installation. Please note that you do + NOT have to install the complete system + from floppy disk, you can still use your CD-ROM, DVD-ROM, or + your internet connection to get the distributions. + + + The official way of creating a modified boot floppy is to + modify the scripts and Makefile used by + make release. This is not required if the + only change is the addition of a + boot.config file on the boot disk. The + boot disk consists of two parts, the boot sector/loader and + the installation kernel. The latter is stored in a small UFS + file system that can be modified and manipulated with all the + usual tools. This includes the creation of + boot.config. All you need is a system + that can mount, read, and write FreeBSD file systems. As a + rule of thumb, this means another FreeBSD system. Once you + have this, it is rather easy to create a modified + boot.flp for installation over a serial + console. + + + + Create floppy disks from the + kern.flp and + mfsroot.flp images. + + + + Insert the floppy disk with the + kern.flp into the drive. + + + + Mount the file system on + kern.flp, create a sutitable + boot.config, and unmount the + disk. + + &prompt.root; mount /dev/fdX /mnt +&prompt.root; echo -P > /mnt/boot.config +&prompt.root; umount /mnt + + + + Connect your serial console to the new FreeBSD system, + just as explained above. + + + + Insert the modified kern.flp into + the disk drive of the new FreeBSD system and start/reboot + it. + + + + After a while, you should see activity on your serial + console, probably the sppiner, followed by the + usual start messages from the kernel. With two minor + exceptions, you can use &man.sysinstall.8; just as if you + were installing FreeBSD with a conventional set-up: + + + + &man.sysinstall.8; cannot start the emergency + holographic shell on an additional VTY because there is + only one serial console. + + + + There is an additional dialog at the start of + &man.sysinstall.8; where you can define which kind of + terminal you are using. + + + + Once &man.sysinstall.8; has finished extracting all the + distributions, it will ask you if you want to change your + settings. You will have to do this, because the newly + installed system is not configured for a serial console + yet. In order to allow log-ins over the serial console, + you will have to select TTYs from + the Configuration. Activate the + &man.getty.8; on ttyd0 and + configure the terminal type to the appropriate value + for your terminal. + + The second required change is the creation of a + boot.config file on the root file system + of your newly installed FreeBSD box. This can be done by + selecting shell from the + Fixit menu. Just type echo -P + > /boot.config, exit the shell, quit + &man.sysinstall.8; and watch your newly installed system boot + with an active serial console. + Comments? /s/Udo -- Enjoy the beauty and power of root To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message