From owner-freebsd-current@FreeBSD.ORG Thu Dec 15 23:40:48 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 16E75106566B for ; Thu, 15 Dec 2011 23:40:48 +0000 (UTC) (envelope-from crodr001@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id 9E1B38FC16 for ; Thu, 15 Dec 2011 23:40:47 +0000 (UTC) Received: by eaaf13 with SMTP id f13so3484120eaa.13 for ; Thu, 15 Dec 2011 15:40:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=+jx0ct6wwxDNfc9JwJNIVTtRAEcbTSsHTM0GoddeY80=; b=KESh4vPTqMc29uMxaeHjuOXkUFYpI5HiuDtkZi4Yjxt7g+wCIicb91Ivm/hzO3e4+a A1iPS15Ei7uu9v+6TcFsWjErz9v6yDrk7Jx3I99/CQP8ODXKOAS0iEy8iJKg8ORMaiqI 00Xy1IcKO2DfvTT+0RNNkGWsFHO/byw/l68Qc= MIME-Version: 1.0 Received: by 10.204.129.24 with SMTP id m24mr2414755bks.89.1323992446292; Thu, 15 Dec 2011 15:40:46 -0800 (PST) Sender: crodr001@gmail.com Received: by 10.205.115.138 with HTTP; Thu, 15 Dec 2011 15:40:46 -0800 (PST) In-Reply-To: <94847CD1-4361-424C-A2F6-75CAE918E2A9@averesystems.com> References: <94847CD1-4361-424C-A2F6-75CAE918E2A9@averesystems.com> Date: Thu, 15 Dec 2011 15:40:46 -0800 X-Google-Sender-Auth: 1ZZVw5f8uUS_E_vCHi8-bIy3m-A Message-ID: From: Craig Rodrigues To: Andrew Boyer Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-current@freebsd.org Subject: Re: Idea for change to boot0 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2011 23:40:48 -0000 Hi, This is interesting. I wrote some newer documentation for PXE booting here: http://www.freebsd.org/doc/handbook/network-pxe-nfs.html In 32.8.4, bullet item 1, I mentioned that it is necessary to configure network booting in the BIOS menu. With your change, is entering the BIOS menu to configure network booting still necessary? -- Craig Rodrigues rodrigc@juniper.net On Thu, Dec 15, 2011 at 1:21 PM, Andrew Boyer wro= te: > These two changes allow you to set PXE as the default MBR boot selection,= which enables you to write a 'reboot to the network' script. =A0We've foun= d it to be very useful. =A0What do people think? > > Thanks, > Andrew > >> Index: usr.sbin/boot0cfg/boot0cfg.c >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> --- usr.sbin/boot0cfg/boot0cfg.c =A0 =A0 =A0(revision 228359) >> +++ usr.sbin/boot0cfg/boot0cfg.c =A0 =A0 =A0(working copy) >> @@ -169,7 +169,7 @@ >> =A0 =A0 =A0 =A0 =A0 =A0 o_flag =3D 1; >> =A0 =A0 =A0 =A0 =A0 =A0 break; >> =A0 =A0 =A0 =A0 case 's': >> - =A0 =A0 =A0 =A0 =A0 =A0s_arg =3D argtoi(optarg, 1, 5, 's'); >> + =A0 =A0 =A0 =A0 =A0 =A0s_arg =3D argtoi(optarg, 1, 6, 's'); >> =A0 =A0 =A0 =A0 =A0 =A0 break; >> =A0 =A0 =A0 =A0 case 't': >> =A0 =A0 =A0 =A0 =A0 =A0 t_arg =3D argtoi(optarg, 1, 0xffff, 't'); >> @@ -472,6 +472,8 @@ >> =A0 =A0 printf("default_selection=3DF%d (", mbr[OFF_OPT] + 1); >> =A0 =A0 if (mbr[OFF_OPT] < 4) >> =A0 =A0 =A0 printf("Slice %d", mbr[OFF_OPT] + 1); >> + =A0 =A0else if (mbr[OFF_OPT] =3D=3D 5) >> + =A0 =A0 =A0 =A0print("PXE"); >> =A0 =A0 else >> =A0 =A0 =A0 printf("Drive 1"); >> =A0 =A0 printf(")\n"); >> Index: sys/boot/i386/boot0/boot0.S >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> --- sys/boot/i386/boot0/boot0.S =A0 =A0 =A0 (revision 228359) >> +++ sys/boot/i386/boot0/boot0.S =A0 =A0 =A0 (working copy) >> @@ -413,6 +413,7 @@ >> =A0 =A0 =A0 3: >> #endif /* ONLY_F_KEYS */ >> #endif /* SIO */ >> +check_selection: >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 cmpb $0x5,%al =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 # F1..F6 or 1..6 ? >> #ifdef PXE /* enable PXE/INT18 using F6 */ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 jne 1f; >> @@ -421,7 +422,6 @@ >> #endif /* PXE */ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 jae beep =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 =A0# Not in F1..F5, beep >> >> -check_selection: >> =A0 =A0 =A0 /* >> =A0 =A0 =A0 =A0* We have a selection. =A0If it's a bad selection go back= to complain. >> =A0 =A0 =A0 =A0* The bits in MNUOPT were set when the options were print= ed. > > -------------------------------------------------- > Andrew Boyer =A0 =A0aboyer@averesystems.com > > > > > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org= " --=20 Craig Rodrigues rodrigc@crodrigues.org