From owner-freebsd-hackers Tue Feb 6 10:10:41 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from urban.iinet.net.au (urban.iinet.net.au [203.59.24.231]) by hub.freebsd.org (Postfix) with ESMTP id B969237B503 for ; Tue, 6 Feb 2001 10:10:19 -0800 (PST) Received: from elischer.org (reggae-14-23.nv.iinet.net.au [203.59.77.23]) by urban.iinet.net.au (8.8.7/8.8.7) with ESMTP id CAA16233; Wed, 7 Feb 2001 02:08:35 +0800 Message-ID: <3A802F6E.D4582D54@elischer.org> Date: Tue, 06 Feb 2001 09:07:58 -0800 From: Julian Elischer X-Mailer: Mozilla 4.7 [en] (X11; U; FreeBSD 5.0-CURRENT i386) X-Accept-Language: en, hu MIME-Version: 1.0 To: Mike Silbersack Cc: Rik van Riel , Poul-Henning Kamp , Charles Randall , "'Matt Dillon'" , Dan Phoenix , Alfred Perlstein , Jos Backus , freebsd-hackers@FreeBSD.ORG, mckusick@mckusick.com Subject: Re: soft updates and qmail (RE: qmail IO problems) References: Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Mike Silbersack wrote: > > On Tue, 6 Feb 2001, Rik van Riel wrote: > > > The system call used to guarantee this is fsync (and friends?); > > if qmail doesn't use it but makes assumptions that aren't true > > on any decent OS out there ... > > > > regards, > > > > Rik > > Well, the various qmail programs do seem to fsync (though I'm not sure if > it's in the right places.) In any case, this link seems to throw some > light on the situation: > > ftp://elektroni.ee.tut.fi/pub/qmail_linux_metadata_message > > Now, I have no clue if this is correct or not, but the core of the > explanation given on that page seems to be: > > --- > > So what is this all about? qmail relies on the BSD semantics of immediate > update of directories on the disk when link(), unlink(), open() and > rename() calls are used. But Linux writes them to the disk asynchronously. > My library loaded before libc changes those calls to do the corresponding > directory writes too. Then qmail should be reliable against power outages > also in Linux. > > --- > > So, does anyone know if that is a correct assertion to make, and if > softupdates does indeed break it? kirk said (but I have not completely checked it) that if you fsync a file, it will effectively fsync all the way back to the root of the filesystem. I don't know how true this is, but cerainly the inode is updated before fsync returns. I cannot tell if any directory entries pointing at that file that have not yet been sync'd are forced out before it returns.... > > Mike "Silby" Silbersack > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message -- __--_|\ Julian Elischer / \ julian@elischer.org ( OZ ) World tour 2000-2001 ---> X_.---._/ v To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message