From owner-freebsd-questions Tue Aug 7 23:38:52 2001 Delivered-To: freebsd-questions@freebsd.org Received: from longfellow.nbrewer.com (nbrewer.dsl.visi.com [208.42.141.101]) by hub.freebsd.org (Postfix) with ESMTP id B9EAC37B403 for ; Tue, 7 Aug 2001 23:38:48 -0700 (PDT) (envelope-from chris@longfellow.nbrewer.com) Received: (from chris@localhost) by longfellow.nbrewer.com (8.11.4/8.11.4) id f786cEO61384; Wed, 8 Aug 2001 01:38:14 -0500 (CDT) (envelope-from chris) Date: Wed, 8 Aug 2001 01:38:14 -0500 From: Christopher Farley To: Christopher Hall Cc: questions@FreeBSD.ORG Subject: Re: rc.shutdown and SmartUPS Message-ID: <20010808013811.A61371@northernbrewer.com> Mail-Followup-To: Christopher Farley , Christopher Hall , questions@FreeBSD.ORG References: <200108080115.f781FnU45606@x4.tucheng.generalresources.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <200108080115.f781FnU45606@x4.tucheng.generalresources.com>; from hsw@acm.org on Wed, Aug 08, 2001 at 09:15:49AM +0800 Organization: Northern Brewer, St. Paul, MN Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Christopher Hall (hsw@acm.org) wrote: > After the UPS has been on battery power for a few minutes the program issues > a "shutdown -r now". For a while I considered forcing a reboot and then dealing with the shutdown during the boot-up. It seems kind of weird to be rebooting the computer while the UPS is screaming about its battery being critically low. My problem was a quirk with NUT. Of course, the disks are still mounted while the FreeBSD's shutdown script is waiting on NUT's UPS powerdown command. After a bit of experimenting (and using fsck -y), I finally discovered a reasonable and simple script for rc.shutdown. /path/to/ups/powerdown/command & sleep 2 Whether the sleep value needs to be tweaked for each computer remains to be seen... -- Christopher Farley www.northernbrewer.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message