Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id 23E1B2E0086 for ; Thu, 15 May 2008 11:59:11 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 42026-01-5 for ; Thu, 15 May 2008 11:58:56 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from relay-2.mail.nethere.net (relay-2.mail.nethere.net [66.63.128.162]) by developer.postgresql.org (Postfix) with ESMTP id 93DFC2E00DD for ; Thu, 15 May 2008 11:57:08 -0300 (ADT) Received: from scan-2.mail.nethere.net (scan-2.mail.nethere.net [66.63.128.133]) by relay-2.mail.nethere.net (Postfix) with ESMTP id 4CB2B12D3B9; Thu, 15 May 2008 07:57:04 -0700 (PDT) Received: from mta-1.mail.nethere.net by scan-2.mail.nethere.net with LMTP id VqKs36+N+f2J; Thu, 15 May 2008 07:57:04 -0700 (PDT) Received: from lisa-james-computer.local (wsip-68-224-174-233.sd.sd.cox.net [68.224.174.233]) by mta-1.mail.nethere.net (Postfix) with ESMTP id 175A5F1815; Thu, 15 May 2008 07:57:03 -0700 (PDT) Message-ID: <482C4F3D.6010808@emolecules.com> Date: Thu, 15 May 2008 07:57:01 -0700 From: Craig James User-Agent: Thunderbird 2.0.0.14 (Macintosh/20080421) MIME-Version: 1.0 To: Matthew Wakeling CC: "pgsql-performance@postgresql.org" Subject: Re: which ext3 fs type should I use for postgresql References: <1210846262.16664.41.camel@philippe-desktop> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200805/213 X-Sequence-Number: 30181 Matthew Wakeling wrote: > Probably of more use are some of the other settings: > > -m reserved-blocks-percentage - this reserves a portion of the filesystem > that only root can write to. If root has no need for it, you can kill > this by setting it to zero. The default is for 5% of the disc to be > wasted. This is not a good idea. The 5% is NOT reserved for root's use, but rather is to prevent severe file fragmentation. As the disk gets full, the remaining empty spaces tend to be small spaces scattered all over the disk, meaning that even for modest-sized files, the kernel can't allocate contiguous disk blocks. If you reduce this restriction to 0%, you are virtually guaranteed poor performance when you fill up your disk, since those files that are allocated last will be massively fragmented. Worse, the fragmented files that you create remain fragmented even if you clean up to get back below the 95% mark. If Postgres happened to insert a lot of data on a 99% full file system, those blocks could be spread all over the place, and they'd stay that way forever, even after you cleared some space. Craig