Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 May 2002 12:45:43 +0100
From:      Kirk McKusick <mckusick@beastie.mckusick.com>
To:        Alfred Perlstein <bright@mu.org>
Cc:        fs@freebsd.org
Subject:   Re: softupdates durability enhancement? 
Message-ID:  <200205271145.g4RBjhC00460@beastie.mckusick.com>
In-Reply-To: Your message of "Fri, 08 Mar 2002 19:30:44 PST." <20020309033044.GC26621@elvis.mu.org> 

next in thread | previous in thread | raw e-mail | index | archive | help
	Date: Fri, 8 Mar 2002 19:30:44 -0800
	From: Alfred Perlstein <bright@mu.org>
	To: mckusick@freebsd.org
	Cc: fs@freebsd.org
	Subject: softupdates durability enhancement?
	User-Agent: Mutt/1.3.27i

	People were complaining about crashes after softupdates giving them
	truncated files after reboot.  I know from your earlier posts that
	this is actually more a bug in the way editors are prone to write
	out files than a real softupdates bug, I would also expect most
	logging filesystems to potentially have the same problem.

	One way to potentially reduce the chances of this are to more
	aggressively push out softdeps when the backlog is short.  Meaning
	that when the softdep clock is nearly empty you push things out
	faster and as the clock fills with dependancies you begin to delay
	them up until the point you are forced to begin sync'ing them.

	The idea is for workstation loads where people are editing single
	files you reduce the window of having the file at zero length and
	thereby you protect them a bit more against stupid editors that do
	unsafe/non-transactionalsafe in-place updates.

	-- 
	-Alfred Perlstein [alfred@freebsd.org]
	'Instead of asking why a piece of software is using "1970s technology,"
	 start asking why software is ignoring 30 years of accumulated wisdom.'
	Tax deductible donations for FreeBSD: http://www.freebsdfoundation.org/

This suggestion seems reasonable. The hooks are already in place:

	kern.filedelay: 30
	kern.dirdelay: 29
	kern.metadelay: 28

Setting them to 1 would cause things to be sync'ed out 1-2 seconds
after they were written. I am open to suggested heuristics for setting
them to lower values.

	Kirk McKusick

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200205271145.g4RBjhC00460>