From owner-freebsd-fs@FreeBSD.ORG Wed Jan 10 18:11:02 2007 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1CA9F16A403 for ; Wed, 10 Jan 2007 18:11:02 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (grnl-static-02-0046.dsl.iowatelecom.net [69.66.56.110]) by mx1.freebsd.org (Postfix) with ESMTP id A1EDE13C469 for ; Wed, 10 Jan 2007 18:11:01 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.13.8/8.13.8) with ESMTP id l0AHhc5m008224; Wed, 10 Jan 2007 11:43:38 -0600 (CST) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.13.8/8.13.8/Submit) id l0AHhc4n008223; Wed, 10 Jan 2007 11:43:38 -0600 (CST) (envelope-from brooks) Date: Wed, 10 Jan 2007 11:43:38 -0600 From: Brooks Davis To: Eric Anderson Message-ID: <20070110174337.GA7544@lor.one-eyed-alien.net> References: <45A3C96A.6030307@scottevil.com> <200701101139.l0ABdJ9K088810@lurza.secnetix.de> <45A485C6.2060405@scottevil.com> <45A5024F.10502@centtech.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="sm4nu43k4a2Rpi4c" Content-Disposition: inline In-Reply-To: <45A5024F.10502@centtech.com> User-Agent: Mutt/1.5.11 Cc: freebsd-fs@freebsd.org Subject: Re: skipping fsck with soft-updates enabled X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Jan 2007 18:11:02 -0000 --sm4nu43k4a2Rpi4c Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jan 10, 2007 at 09:12:15AM -0600, Eric Anderson wrote: > On 01/10/07 00:20, Scott Oertel wrote: > >Victor Loureiro Lima wrote: > >>From rc.conf man page: > >>--- > >>background_fsck_delay > >> (int) The amount of time in seconds to sleep before=20 > >>starting > >> a background fsck(8). It defaults to sixty seconds to= =20 > >>allow > >> large applications such as the X server to start=20 > >>before disk > >> I/O bandwidth is monopolized by fsck(8). > >>--- > >> > >>You can set the delay as long as you want, so it wont have to start > >>right away, in fact it can start as late as a year (if thats really > >>what you want ;)) > >> > >>att, > >>victor loureiro lima > >> > >>2007/1/10, Oliver Fromme : > >>>Scott Oertel wrote: > >>> > I am wondering what kind of problems would occur, besides lost=20 > >>>space, if > >>> > after a system crash a fsck is skipped. According to the=20 > >>>documentation, > >>> > with soft-updates enabled, the file system would be consistant, the= re > >>> > would just be lost resources to be recovered which I am assuming=20 > >>>can be > >>> > safely done at a later time to avoid long periods of downtime during > >>> > peek hours. > >>> > >>>I think that's exactly what the background fsck feature > >>>does. If you enable it (which is even the default), the > >>>fsck process doesn' start right away, so the system comes > >>>up in multi-user mode immediately. Then a snapshot is > >>>created on the file system, and fsck runs on the snap- > >>>shot, freeing the lost space in the file system. > >>> > >>>Of course, it only works reliably with soft-updates enabled, > >>>_and_ there must not be any unexpected inconsistencies. > >>>However, with some common setups (e.g. cheap disks lying > >>>about completed write operation) it is difficult to > >>>guarantee the consistency. Soft-updates is rather fragile > >>>when the hardware doesn't work exactly as it's supposed to. > >>>I've witnessed breakage in the past, and for that reason > >>>I always disable the background fsck feature. And it's the > >>>reason I'm looking forward to gjournal to become stable, > >>>because it seems to be less fragile in the presence of > >>>imperfect hardware. > >>> > >>>Best regards > >>> Oliver > >>> > >>>--=20 > >>>Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing > >>>Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd > >>>Any opinions expressed in this message may be personal to the author > >>>and may not necessarily reflect the opinions of secnetix in any way. > >>> > >>>"C++ is to C as Lung Cancer is to Lung." > >>> -- Thomas Funke > >>>_______________________________________________ > >The problem with background fsck is that on my machines, it doesn't work= =20 > >well. These machines have 8x750gb SATA drives and they are under extreme= =20 > >stress all the time. When you run fsck in the background each drive=20 > >takes 10+ minutes to create the snapshot file, during which time the=20 > >machine is completely unresponsive, and unstable. >=20 > What version of FreeBSD are you running? You might try gjournal, which= =20 > I've had great luck with, and Pawel (pjd@) is incredibly responsive to=20 > bug reports, etc. >=20 > >That is why I am wondering, if it is ok to skip the background fsck's,= =20 > >foreground fsck's and reschedule them for a later time, during non peak= =20 > >hours. >=20 > I think most people would be nervous to tell you 'sure, skip it until=20 > later', but I can tell you from experience that I myself have delayed=20 > fscking for weeks on end, to do exactly what you want. I've been thinking it would be useful to have a new background_fsck_delay value of CRON and have a cron job that can accomplish the background fsck during off hours if needed. -- Brooks --sm4nu43k4a2Rpi4c Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (FreeBSD) iD8DBQFFpSXJXY6L6fI4GtQRAm7RAJ9HOzb/UlQbXT+BJOoFEWvsAEzPggCg5HvW BK/HnggNuwOkRMauSXGXiQY= =toQP -----END PGP SIGNATURE----- --sm4nu43k4a2Rpi4c--