rodlie / powerkit

Desktop Independent Power Manager

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support: Schedule shutdown/suspend

rodlie opened this issue · comments

Add option to schedule shutdown/suspend like a "cron" job.

Can you also make hibernate and brightness settings easier to access via powerkit?
:)

You need to be more specific :)

You can adjust the brightness with the mouse wheel on the systray. It currently only do +1/-1, I should add a settings for that.

I can add a right click context menu with "suspend", "hibernate", "restart", "shutdown"?

No I mean, editing bootloader is needed to support hibernate, and udev permissions are required... its a bit lets say odd that it doesn't work out of box.

powerkit is a user application, it can't modify anything on the system.

However, powerkit 1.1 will feature a additional daemon called powerkitd, it's a on-demand (elevated) service that can set/write the RTC alarm and brightness if the user can't access the files in /sys. So it will be better.

Regarding hibernation, this is something the distro should setup during installation, and nothing I will do anything with (check what kind of bootloader is used, where the config file is, modify it accordingly, how to update the bootloader config, check that swap partition/file is large enough to save ram etc). I would rather open a issue with the distro your are using and request hibernation setup as a feature request during install (would be as simple as : if swap >= ram then add swap partition to kernel cmdline during bootloader setup).

Okay, well... my laptop could hibernate when using xfce just installing it's xfce4-power-manager.
It seems to be different though with Lumina.
I don't even know which files to modify, and where they are located in my distro. :/

maybe your system works without the resume= cmdline in the kernel, I can add an option to bypass the check for valid kernel cmdline.

@FrostKnight :Could you post the output of cat /proc/cmdline?

Just to let you know, I am using libreboot with FDE so it will look a bit odd...

When i used this command I saw this:

BOOT_IMAGE=/boot/vmlinuz-linux-libre-lts root=/dev/matrix/rootvol cryptdevice=/dev/sda1:root cryptkey=rootfs:/etc/mykeyfile

But yeah, even knowing this I could hibernate within xfce4 if need be. Lumina is a different animal though. ;)

All the documentation online refers to resume=whatever, if you don't have that you will not be able to hibernate (to-disk). I also checked the source for xfce-power-manager and didn't find anything useful.

I can remove the check for resume= and give you a custom version you could try(?), but note trying to hibernate without resume= fail on my machines.

btw, Lumina has nothing to do with power management, it's handled by powerkit.

Download https://github.com/rodlie/powerkit/archive/test1.tar.gz , this will not check for valid resume=

Note this might not work (so don't hibernate while doing something important).

xfce uses /usr/sbin/pm-hibernate to hibernate, so probably something in that script that does something. powerkit does not use pm-utils.

this issue got very off-topic, close (see #22 ). Please post new issues if it's not related.

By the way: https://github.com/rodlie/powerkit/archive/test1.tar.gz

worked perfectly. I tried it once so far, and nothing bad happened. It loaded like normally only from hibernation. :)

Nice. Please report back if you get any issues with hibernation. I will add a option to bypass the kernel check, will add it to the stable branch this weekend so you get the fix as soon as possible (1.1/master is not ready for production yet).