From owner-freebsd-amd64@FreeBSD.ORG Mon May 23 17:44:18 2005 Return-Path: X-Original-To: freebsd-amd64@freebsd.org Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7282D16A41C for ; Mon, 23 May 2005 17:44:18 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from mail24.sea5.speakeasy.net (mail24.sea5.speakeasy.net [69.17.117.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 139C743D53 for ; Mon, 23 May 2005 17:44:18 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: (qmail 11248 invoked from network); 23 May 2005 17:44:17 -0000 Received: by simscan 1.1.0 ppid: 11233, pid: 11242, t: 0.1225s scanners: clamav: 0.84/m:31/d:888 Received: from gate.funkthat.com (HELO hydrogen.funkthat.com) ([69.17.45.168]) (envelope-sender ) by mail24.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 23 May 2005 17:44:17 -0000 Received: from hydrogen.funkthat.com (knwluz@localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.12.10/8.11.6) with ESMTP id j4NHiG2g076790; Mon, 23 May 2005 10:44:16 -0700 (PDT) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.12.10/8.12.10/Submit) id j4NHiGQZ076789; Mon, 23 May 2005 10:44:16 -0700 (PDT) Date: Mon, 23 May 2005 10:44:15 -0700 From: John-Mark Gurney To: Sven Willenberger Message-ID: <20050523174415.GI959@funkthat.com> Mail-Followup-To: Sven Willenberger , freebsd-stable@freebsd.org, freebsd-amd64@freebsd.org References: <1116860293.10083.43.camel@lanshark.dmv.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1116860293.10083.43.camel@lanshark.dmv.com> User-Agent: Mutt/1.4.1i X-Operating-System: FreeBSD 4.2-RELEASE i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: freebsd-stable@freebsd.org, freebsd-amd64@freebsd.org Subject: Re: Manipulating disk cache (buf) settings X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 May 2005 17:44:18 -0000 Sven Willenberger wrote this message on Mon, May 23, 2005 at 10:58 -0400: > We are running a PostgreSQL server (8.0.3) on a dual opteron system with > 8G of RAM. If I interpret top and vfs.hibufspace correctly (which show > values of 215MB and 225771520 (which equals 215MB) respectively. My > understanding from having searched the archives is that this is the > value that is used by the system/kernel in determining how much disk > data to cache. This is incorrect... FreeBSD merged the vm and buf systems a while back, so all of memory is used as a disk cache.. The buf cache is still used for filesystem meta data (and for pending writes of files, but those buf's reference the original page, not local storage)... Just as an experiment, on a quiet system do: dd if=/dev/zero of=somefile bs=1m count=2048 and then read it back in: dd if=somefile of=/dev/null bs=1m and watch systat or iostat and see if any of the file is read... You'll probably see that none of it is... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not."