From owner-freebsd-questions@FreeBSD.ORG Mon Nov 19 20:10:24 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 278D916A41B for ; Mon, 19 Nov 2007 20:10:24 +0000 (UTC) (envelope-from erik@cederstrand.dk) Received: from mail.itu.dk (pluto.itu.dk [130.226.142.18]) by mx1.freebsd.org (Postfix) with ESMTP id DC8FD13C448 for ; Mon, 19 Nov 2007 20:10:23 +0000 (UTC) (envelope-from erik@cederstrand.dk) Received: from localhost (unknown [10.0.0.3]) by mail.itu.dk (Postfix) with ESMTP id C895036EFE3; Mon, 19 Nov 2007 21:10:16 +0100 (CET) X-Virus-Scanned: amavisd-new at itu.dk Received: from superman.itu.dk ([130.226.142.5]) by localhost (daredevil.itu.dk [130.226.142.26]) (amavisd-new, port 10024) with ESMTP id A4b49A4Fp+dr; Mon, 19 Nov 2007 21:10:11 +0100 (CET) Received: from wimac.littlebit.dk (unknown [85.233.238.191]) by superman.itu.dk (Postfix) with ESMTP id D7DAF9E71A; Mon, 19 Nov 2007 21:10:11 +0100 (CET) Message-ID: <4741EDA2.3030504@cederstrand.dk> Date: Mon, 19 Nov 2007 21:10:10 +0100 From: Erik Cederstrand User-Agent: Thunderbird 2.0.0.9 (Macintosh/20071031) MIME-Version: 1.0 To: =?ISO-8859-1?Q?Javier_Mart=EDn_Rueda?= References: <474170F2.4080909@diatel.upm.es> In-Reply-To: <474170F2.4080909@diatel.upm.es> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Cc: freebsd-questions@freebsd.org Subject: Re: Changing the boot device from PXE to hard disk X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Nov 2007 20:10:24 -0000 Javier Martín Rueda wrote: > I have set up a simple unattended installation system for FreeBSD, so > that I can manually configure a group of computers to boot with PXE, > and when they boot they will automatically install FreeBSD. > > The final step would be to configure the BIOS to boot from the first > hard drive. So far I can do that manually by pressing "Del" when the > computer boots and entering the ROM BIOS setup program, but I would > like to know if it is possible somehow to change the boot device > priority in the BIOS from FreeBSD? It's not possible to access the BIOS setting through FreeBSD. What I do is to set the boot order in BIOS to: 1. hard drive 2. PXE Before the unattended install, wipe out the MBR. If this is a blank hard drive, then you're already OK. If the drive contains a previous FreeBSD install, do: # sysctl kern.geom.debugflags=16 # dd if=/dev/zero of=/dev/ad0 bs=512 count=1k as root. This makes the BIOS skip the hard drive on the next boot and continue to boot via PXE. Make sure your install puts an MBR on the disk, so the BIOS picks the hard drive after rebooting. Erik