From owner-freebsd-stable Wed Jun 16 19:43:46 1999 Delivered-To: freebsd-stable@freebsd.org Received: from mtiwmhc03.worldnet.att.net (mtiwmhc03.worldnet.att.net [204.127.131.38]) by hub.freebsd.org (Postfix) with ESMTP id 0ECC414FD6 for ; Wed, 16 Jun 1999 19:43:35 -0700 (PDT) (envelope-from jedgar@fxp.org) Received: from earth.fxp ([12.77.192.88]) by mtiwmhc03.worldnet.att.net (InterMail v03.02.07.07 118-134) with ESMTP id <19990617024334.SLBQ15914@earth.fxp>; Thu, 17 Jun 1999 02:43:34 +0000 Date: Wed, 16 Jun 1999 22:43:32 -0400 (EDT) From: "Chris D. Faulhaber" X-Sender: jedgar@earth.fxp To: Stefan `Sec` Zehl Cc: Dag-Erling Smorgrav , freebsd-stable@FreeBSD.ORG Subject: Re: / not properly unmounted ? In-Reply-To: <19990616142937.A24601@matrix.42.org> Message-ID: MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-7369224-929587412=:301" Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. Send mail to mime@docserver.cac.washington.edu for more info. --0-7369224-929587412=:301 Content-Type: TEXT/PLAIN; charset=US-ASCII On Wed, 16 Jun 1999, Stefan `Sec` Zehl wrote: > On Wed, Jun 16, 1999 at 02:24:44PM +0200, Dag-Erling Smorgrav wrote: > > Stefan `Sec` Zehl writes: > > > WARNING: / was not properly dismounted > > > and a subsquent fsck happens which has no (visible) effect. > > > > > > I do use 'halt -p' to turn off my box. > > > > Either don't use 'halt -p', or disable write caching on your disk > > drives - or hack the kernel to pause for five seconds or something > > before switching off the power. > Okay...sounds like fun... I added a sysctl variable (machdep.powerdown_delay) to allow the disk cache to flush by itself before APM powering the system off. After applying the attached patch (tested on 3.2-STABLE) and installing a new kernel, just use 'sysctl -w machdep.powerdown_delay=5' for a 5 second delay. I don't know if this is appropriate for actual inclusion into the kernel...if so, I can see about merging it into -CURRENT and/or changing to a more appropriate sysctl level (i.e. kern, hw). ----- Chris D. Faulhaber | All the true gurus I've met never System/Network Administrator, | claimed they were one and always Reality Check Information, Inc. | pointed to someone better. --0-7369224-929587412=:301 Content-Type: TEXT/PLAIN; charset=US-ASCII; name="powerdown_delay.diff" Content-Transfer-Encoding: BASE64 Content-ID: Content-Description: Content-Disposition: attachment; filename="powerdown_delay.diff" LS0tIC9zeXMvaTM4Ni9hcG0vYXBtLmMub3JpZwlUaHUgRGVjIDEwIDE4OjM2 OjE0IDE5OTgNCisrKyAvc3lzL2kzODYvYXBtL2FwbS5jCVdlZCBKdW4gMTYg MjI6MzQ6NDMgMTk5OQ0KQEAgLTM5LDYgKzM5LDcgQEANCiAjaW5jbHVkZSA8 dm0vcG1hcC5oPg0KICNpbmNsdWRlIDxzeXMvc3lzbG9nLmg+DQogI2luY2x1 ZGUgPGkzODYvYXBtL2FwbV9zZXR1cC5oPg0KKyNpbmNsdWRlIDxzeXMvc3lz Y3RsLmg+DQogDQogI2lmZGVmIFZNODYNCiAjaW5jbHVkZSA8bWFjaGluZS9w c2wuaD4NCkBAIC0xMTgsNiArMTE5LDkgQEANCiANCiBzdGF0aWMgaW50IGFw bV9lcnJubzsNCiANCitzdGF0aWMgaW50IHBvd2VyZG93bl9kZWxheSA9IDA7 DQorU1lTQ1RMX0lOVChfbWFjaGRlcCwgT0lEX0FVVE8sIHBvd2VyZG93bl9k ZWxheSwgQ1RMRkxBR19SVywgJnBvd2VyZG93bl9kZWxheSwgMCwgIiIpOw0K Kw0KIHN0YXRpYyBpbnQNCiBhcG1faW50KHVfbG9uZyAqZWF4LCB1X2xvbmcg KmVieCwgdV9sb25nICplY3gsIHVfbG9uZyAqZWR4KQ0KIHsNCkBAIC0yNTQs NiArMjU4LDcgQEANCiAJLyogTm90IGhhbHRpbmcgcG93ZXJpbmcgb2ZmLCBv ciBub3QgYWN0aXZlICovDQogCWlmICghKGhvd3RvICYgUkJfUE9XRVJPRkYp IHx8ICFhcG1fc29mdGMuYWN0aXZlKQ0KIAkJcmV0dXJuOw0KKwlERUxBWSgx MDAwMDAwICogcG93ZXJkb3duX2RlbGF5KTsNCiAJZWF4ID0gKEFQTV9CSU9T IDw8IDgpIHwgQVBNX1NFVFBXU1RBVEU7DQogCWVieCA9IFBNRFZfQUxMREVW Ow0KIAllY3ggPSBQTVNUX09GRjsNCg== --0-7369224-929587412=:301-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message