From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 31 20:41:06 2006 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9804916A407 for ; Sun, 31 Dec 2006 20:41:06 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.freebsd.org (Postfix) with ESMTP id 452E813C457 for ; Sun, 31 Dec 2006 20:41:06 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from fledge.watson.org (fledge.watson.org [209.31.154.41]) by cyrus.watson.org (Postfix) with ESMTP id 85CD84949D; Sun, 31 Dec 2006 15:41:04 -0500 (EST) Date: Sun, 31 Dec 2006 20:41:04 +0000 (GMT) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: Tim Kientzle In-Reply-To: <45981346.3050201@freebsd.org> Message-ID: <20061231203829.O7974@fledge.watson.org> References: <200612301119.kBUBJNno062104@lurza.secnetix.de> <20061230123256.V18740@fledge.watson.org> <45981346.3050201@freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-hackers@freebsd.org, Oliver Fromme Subject: Re: Init.c, making it chroot X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 Dec 2006 20:41:06 -0000 On Sun, 31 Dec 2006, Tim Kientzle wrote: > Robert Watson wrote: >> ... It used to be that only certain file systems could be used as a root >> file system, because only they knew how to bypass the lookup procedure to >> find their device node, short-circuiting to the in-kernel device list. > > So why are the MD_ROOT and NFS_ROOT options still around? It sounds like > there must still be something special about root-capable file systems. NFS_ROOT has to do with extracting the root mount configuration information from the interface list, loader environment, prior to the file system mount process so that NFS knows where to go to find a file system, configure networking, etc. MD_ROOT has to do with setting up the md device to mount the root file system from in memory without having mdconfig run. A glance at the md(4) source code suggests that it also tweaks the default root device to be "ufs:/dev/md0". This is not actually a file system option so much as an option in the behavior of the md(4) device driver. At least, this is my understanding from a very casual glance at the source. In both cases, we now use the single vfs_mount VFSOP. Robert N M Watson Computer Laboratory University of Cambridge