[gpm] Defaults for reboot and shutdown
Richard Hughes
hughsient at gmail.com
Fri Dec 9 11:21:19 PST 2005
(switching to HAL list)
On Fri, 2005-12-09 at 01:08 -0500, David Zeuthen wrote:
> On Sun, 2005-12-04 at 21:59 +0000, Richard Hughes wrote:
> > On Sun, 2005-12-04 at 22:34 +0100, Jaap Haitsma wrote:
> > > Hi,
> > >
> > > The current defaults for reboot and shutdown point to
> > >
> > > /usr/bin/reboot
> > > and
> > > usr/bin/halt -p
> > >
> > > as reboot and halt are usually in the /sbin directory
> >
> > Not on fedora, and I'm sure other distros do this differently as well
> > (ick). I really wanted Shutdown() in HAL for the compatibility scripts
> > we could use (like we do for Suspend() and Hibernate()) so we don't have
> > to do all this per-distro-foo (checking for files existing in different
> > places) in g-p-m itself. I think David thought it didn't belong in HAL,
> > but suspend and hibernate did. David, is this still your opinion? I'm
> > looking to add suspend to ram, and suspend to disk into the logout
> > dialogue (perhaps) and would rather replace the hacky configure and
> > runtime detection stuff with simple dbus methods.
>
> Well, as long as it's used responsibly [1] I don't really see a problem
> with HAL offering Shutdown() and Reboot() along with Suspend() and
> Hibernate() that we already got. It's better to hide all the nasty
> per-OS / per-distro hacks in one place after all.
>
> Cheers,
> David
>
> [1] : e.g. g-p-m only calls Shutdown() when there really is very little
> power left and we can't hibernate. Sounds OK to me for the GNOME logout
> dialog to use Shutdown() on HAL instead of figuring out where what
> binary to invoke on distro X, Y and Z [2]. And Debian (at least Ubuntu,
> but I haven't checked for some time) ships a HAL that runs unprivileged
> [3] so good luck with writing the script to make HAL do anything useful
> there :-)
>
> [2] : But you'll need to anyway, probably, as all of GNOME (except e.g.
> g-v-m and g-p-m) needs to have fallbacks for when HAL is not available.
>
> [3] : And every time I ask them exactly what specific attack vectors
> they try to avoid they never answer me :-)
Initial patch attached.
Comments please,
Richard.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hal-add-shutdown-reboot.patch
Type: text/x-patch
Size: 3475 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20051209/4819776a/hal-add-shutdown-reboot.bin
More information about the hal
mailing list