Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 29 Jun 2010 15:07:33 -0700
From:      Garrett Cooper <yanefbsd@gmail.com>
To:        FreeBSD-Hackers <freebsd-hackers@freebsd.org>
Subject:   Set default pxeboot vfs.root.mountfrom to nfs?
Message-ID:  <AANLkTikXM7hWW6lXSzOwKuwT58a_5dFB6Dl9HFE0NDKw@mail.gmail.com>

next in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
Hi Hackers,
    I realize this is a trivial patch, but it's a minor item that I
found kind of fascinating (and not thoroughly documented elsewhere
because many examples are booting mfsroots instead of directly booting
off nfs roots), but I'm proposing that pxeboot default to
vfs.root.mountfrom="nfs" to reduce the need for special case
loader.conf files just for pxe booting (and thus, enable
out-of-the-box netbooting ^o^!!!).
    Thoughts?
Thanks!
-Garrett

[-- Attachment #2 --]
Index: boot/i386/libi386/pxe.c
===================================================================
--- boot/i386/libi386/pxe.c	(revision 209563)
+++ boot/i386/libi386/pxe.c	(working copy)
@@ -308,6 +308,7 @@
 		}
 		setenv("boot.nfsroot.server", inet_ntoa(rootip), 1);
 		setenv("boot.nfsroot.path", rootpath, 1);
+		setenv("vfs.root.mountfrom", "nfs", 0);
 		setenv("dhcp.host-name", hostname, 1);
 	}
     }

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTikXM7hWW6lXSzOwKuwT58a_5dFB6Dl9HFE0NDKw>