:: Re: [DNG] upowerd - why does it run…
Góra strony
Delete this message
Reply to this message
Autor: Marjorie Roome
Data:  
Dla: dng
Temat: Re: [DNG] upowerd - why does it run on a desktop
Hi Jim,

On Sat, 2023-04-15 at 20:40 +0100, Jim Jackson wrote:
>
> Hi all,
>
> just wondering is anyone knows why upowerd is needed on a non-
> batterydesktop? Nearly everything depends on it - just try to purge
> it!!!
>
> And there doesn't appear to be a clean way to deconfigure it from
> being started by dbus - are have I missed something?
>
> just curious
> Jim

If your running Gnome, or Xfce or Cinnamon (which uses some Gnome
components) as your DM I think it sits behind the DMs Power Managers.

So with these DMs it's used to control power management actions, like
when to suspend or hibernate or simply turn off the screen if idle as
set with the Power Manager. 

It may also act as middleware when you power off, restart, hibernate or
suspend from the DMs panel Power Off menu item.

My understanding is that you can do these power actions more directly
(not using upowerd) from these DMs but you will probably have to use
sudo or assign the user sudoers for the actions. 
I have a custom "Shutdown menu with icons" applet in my Cinnamon DM
which directly invokes these actions (preceded by a sudo so 'sudo pm-
hibernate' for example) but I have to assign users to my 'power' group
and assign the commands to user 'power ' in /etc/sudoers to use it.
When using upowerd it doesn't seem to use pm to control hibernate or
suspend as nothing appears in the pm logs.

--
Marjorie