Re: systemd questions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2011-05-18 at 21:15 -0500, Robert Nichols wrote:
> On 05/18/2011 06:42 PM, Simo Sorce wrote:
> > On Wed, 2011-05-18 at 16:48 -0500, Robert Nichols wrote:
> >> On 05/18/2011 04:04 PM, Lennart Poettering wrote:
> >>> Host requests power down from UPS in 30s. Host then continues shut
> >>> down. If the host now ends up taking more time then expected for
> >>> shutting down it might still be busy at the time of the power going
> >>> away. It's a race between "UPS powering off" and "system finishing
> >>> shutdown". It's a bet that your system is faster than 30s when
> >>> unmounting the remaining file systems, syncing the MD/DM metadata to
> >>> disk, syncing ATA and so on (i.e. all the stuff the kernel does when you
> >>> invoke the reboot() syscall).
> >>
> >> Here's another race.  Host requests power down from UPS in 30s.  Host
> >> completes shutdown.  At some point during that 30s interval, commercial
> >> power is restored.  Result: Host shuts down and never restarts.  Sorry
> >> about that.
> >>
> >> The way I've always prevented that is to have the host do a reboot,
> >> not a shutdown, but send an immediate shutdown command to the UPS
> >> just before sending control to the BIOS for the reboot.
> >
> > What you should do is to configure the BIOS to always boot on power-up.
> >
> > This way the UPS will remove power, figure out power is returned,
> > reapply power and the BIOS will reboot the machine.
> 
> Telling my UPS to turn off merely shuts down the inverter.  If it is
> not currently running on the inverter (because commercial power is
> available), that is effectively a no-op, and power at the UPS output
> remains on.  Telling the BIOS to boot on power-up (which is how mine
> is configured, BTW) does nothing since _power_never_went_away_.  All
> the BIOS sees is a command to shut down, which it does.  And stays
> that way.  Absent manual intervention, the only thing that would bring
> the system back up would be a power failure long enough to exceed the
> capacity of the essentially unloaded UPS, and that would be _quite_ a
> long time.

IIRC some UPSs can be commanded to cycle power (ie interrupt all power
to the machine) on shutdown anyway. Perhaps not all models do that.

Simo.

-- 
Simo Sorce * Red Hat, Inc * New York

-- 
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/devel


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux