X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id AFAAFD1C47A for ; Wed, 13 Aug 2003 06:13:54 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 77460-08 for ; Wed, 13 Aug 2003 03:12:16 -0300 (ADT) Received: from lakemtai09.cox.net (lakemtai09.cox.net [68.1.17.123]) by svr1.postgresql.org (Postfix) with ESMTP id E631DD1C4C7 for ; Wed, 13 Aug 2003 03:13:39 -0300 (ADT) Received: from lhosts ([68.11.66.83]) by lakemtao03.cox.net (InterMail vM.5.01.04.05 201-253-122-122-105-20011231) with ESMTP id <20030813033038.JZTS23518.lakemtao03.cox.net@lhosts> for ; Tue, 12 Aug 2003 23:30:38 -0400 Subject: Re: Perfomance Tuning From: Ron Johnson To: PgSQL Performance ML In-Reply-To: <200308121839.h7CIdtF07858@candle.pha.pa.us> References: <200308121839.h7CIdtF07858@candle.pha.pa.us> Content-Type: text/plain Message-Id: <1060745432.30778.39.camel@haggis> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.3 Date: 12 Aug 2003 22:30:33 -0500 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200308/227 X-Sequence-Number: 3044 On Tue, 2003-08-12 at 13:39, Bruce Momjian wrote: > OK, I got some hard evidence. Here is a discussion on the Linux kernel > mailing list with postings from Allen Cox (ac Linux kernels) and Stephen > Tweedie (ext3 author). > > http://www.tux.org/hypermail/linux-kernel/1999week14/subject.html#start > > Search for "softupdates and ext2". > > Here is the original email in the thread: > > http://www.tux.org/hypermail/linux-kernel/1999week14/0498.html > > Summary is at: > > http://www.tux.org/hypermail/linux-kernel/1999week14/0571.html > > and conclusion in: > > http://www.tux.org/hypermail/linux-kernel/1999week14/0504.html > > I now remember the issue --- ext2 makes all disk changes asynchonously > (unless you mount it via sync, which is slow). This means that the file > system isn't always consistent on disk. > > UFS has always sync metadata (file/directory creation) to the disk so > the disk was always consistent, but doesn't sync the data to the disk, > for performance reasons. With soft updates, the metadata writes are > delayed, and written to disk in an order that keeps the file system > consistent. > > Is this enough evidence, or should I keep researching? This is all 4 years old, though. Isn't that why the ext3 "layer" was created, and filesystems like reiserFS, XFS and (kinda) JFS were added to Linux? > --------------------------------------------------------------------------- > > Neil Conway wrote: > > On Tue, Aug 12, 2003 at 12:52:46AM -0400, Bruce Momjian wrote: > > I don't use Linux and was just repeating what I had heard from others, > > > and read in postings. I don't have any first-hand experience with ext2 > > > (except for a laptop I borrowed that wouldn't boot after being shut > > > off), but others on this mailing list have said the same thing. > > > > Right, and I understand the need to answer users asking about > > which filesystem to use, but I'd be cautious of bad-mouthing > > another OSS project without any hard evidence to back up our > > claim (of course if we have such evidence, then fine -- I > > just haven't seen it). It would be like $SOME_LARGE_OSS > > project saying "Don't use our project with PostgreSQL, as > > foo@bar.org had data corruption with PostgreSQL 6.3 on > > UnixWare" -- kind of annoying, right? > > > > > > (a) ext3 does metadata-only journalling by default > > > > > > If that is true, why was I told people have to mount their ext3 file > > > systems with metadata-only. Again, I have no experience myself, but why > > > are people telling me this? > > > > Perhaps they were suggesting that people mount ext2 using > > data=writeback, rather than the default of data=ordered. > > > > BTW, I've heard from a couple different people that using > > ext3 with data=journalled (i.e. enabling journalling of both > > data and metadata) actually makes PostgreSQL faster, as > > it means that ext3 can skip PostgreSQL's fsync request > > since ext3's log is flushed to disk already. I haven't > > tested this myself, however. > > > > -Neil -- +---------------------------------------------------------------+ | Ron Johnson, Jr. Home: ron.l.johnson@cox.net | | Jefferson, LA USA | | | | "Man, I'm pretty. Hoo Hah!" | | Johnny Bravo | +---------------------------------------------------------------+