From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 15 12:50:03 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 06DB916A4CE for ; Fri, 15 Oct 2004 12:50:03 +0000 (GMT) Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by mx1.FreeBSD.org (Postfix) with SMTP id 3D0C143D1D for ; Fri, 15 Oct 2004 12:50:02 +0000 (GMT) (envelope-from dwmalone@maths.tcd.ie) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 15 Oct 2004 13:49:48 +0100 (BST) Date: Fri, 15 Oct 2004 13:49:48 +0100 From: David Malone To: Oliver Fromme Message-ID: <20041015124948.GA66898@walton.maths.tcd.ie> References: <200410141427.i9EERcTF056740@lurza.secnetix.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200410141427.i9EERcTF056740@lurza.secnetix.de> User-Agent: Mutt/1.5.6i Sender: dwmalone@maths.tcd.ie cc: freebsd-hackers@FreeBSD.ORG Subject: Re: NFS + VM question X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Oct 2004 12:50:03 -0000 On Thu, Oct 14, 2004 at 04:27:38PM +0200, Oliver Fromme wrote: > On the other hand, the kernel should know that the mounts > come from the same NFS source, so it might actually be able > to handle it efficiently (i.e. share). But I really don't > know. Any FreeBSD kernel hacker can enlighten me? Since the server could actually hand out different content depending on the mount instance, I don't think the NFS client could make these assumptions. If you try NFS mounting /usr a few times and then time how long it takes to cat a cached file, you'll see this. > If the memory isn't shared in this situation, is there a > way to change the design so it can be shared? chroot and > NFS are "musts", though. I don't think there is an easy way to get this caching to happen, short of using hard links or some kind of union mount instead of NFS. David. > /usr/bin/time cat /usr/X11R6/bin/Xvfb > /dev/null 0.17 real 0.00 user 0.03 sys > /usr/bin/time cat /usr/X11R6/bin/Xvfb > /dev/null 0.02 real 0.00 user 0.02 sys > /usr/bin/time cat /usr/X11R6/bin/Xvfb > /dev/null 0.02 real 0.00 user 0.02 sys > /usr/bin/time cat /mnt1/X11R6/bin/Xvfb > /dev/null 0.21 real 0.00 user 0.04 sys > /usr/bin/time cat /mnt1/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.03 sys > /usr/bin/time cat /mnt1/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.02 sys > /usr/bin/time cat /mnt2/X11R6/bin/Xvfb > /dev/null 0.21 real 0.00 user 0.04 sys > /usr/bin/time cat /mnt2/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.03 sys > /usr/bin/time cat /mnt2/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.03 sys > /usr/bin/time cat /mnt3/X11R6/bin/Xvfb > /dev/null 0.21 real 0.00 user 0.04 sys > /usr/bin/time cat /mnt3/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.03 sys > /usr/bin/time cat /mnt3/X11R6/bin/Xvfb > /dev/null 0.03 real 0.00 user 0.03 sys