SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello, I have Slackware-current 64-bit with Plasma 5 (5.19.1)
installed.
I cannot use Suspend to RAM as it kills touchpad.
However Hybrid Sleep (run from console) works well.
I was trying to enable Hybrid Sleep in Plasma 5, however it does not work:
Closing lid just logs user out
Selecting from KDE Menu is not possible (missing option)
also
selecting Hybernate from KDE menu only logs user out.
system is capable to hibernate and hybrid hibernate:
pm-hibernate
pm-suspend-hybrid
from console work
lilo.conf has
append="resume=/dev/sda2"
o.k.
so I see that there is some interest in the topic but no real solution..
I would not pursue hibernate/suspend-hybrid if suspend to RAM worked properly.
Unfortunately on my laptop suspend to RAM kills touchpad and I have to restart system to regain control over mouse.
Hibernate does not remove psmouse module so after restoring from hibernation all works including touchpad. Suspend-hybrid is just hibernation to RAM so restoring system is as fast as from suspend to RAM.
Even though Plasma has options for hibernate and hybrid-suspend neither works.
There are some references that indicate that it is possible to make hibernate/hybrid-suspend work under kde but all references point to systemd distros.
I found as old as 2016 kde bug report tackling this problem but in 2020 kde still can't do basic stuff (hibernate after lid close or hibernate on battery after time of inactivity.
If some good soul knows how to resolve this issue I would be grateful to learn hot to make kde hibernate.
o.k.
so I see that there is some interest in the topic but no real solution..
I would not pursue hibernate/suspend-hybrid if suspend to RAM worked properly.
Unfortunately on my laptop suspend to RAM kills touchpad and I have to restart system to regain control over mouse.
Hibernate does not remove psmouse module so after restoring from hibernation all works including touchpad. Suspend-hybrid is just hibernation to RAM so restoring system is as fast as from suspend to RAM.
Even though Plasma has options for hibernate and hybrid-suspend neither works.
There are some references that indicate that it is possible to make hibernate/hybrid-suspend work under kde but all references point to systemd distros.
I found as old as 2016 kde bug report tackling this problem but in 2020 kde still can't do basic stuff (hibernate after lid close or hibernate on battery after time of inactivity.
If some good soul knows how to resolve this issue I would be grateful to learn hot to make kde hibernate.
From what I read, the part from systemd which do this hibernation business is systemd-logind.
And this particular systemd-logind is already used by Mr. Hameleers' Plasma5 and Mr. Workman's XFCE-next as the stand alone elogind , then that information regarding systemd based distributions may apply with some modifications.
Last edited by LuckyCyborg; 08-03-2020 at 02:03 PM.
From what I read, the part from systemd which do this hibernation business is systemd-logind.
And this particular systemd-logind is already used by Mr. Hameleers' Plasma5 and Mr. Workman's XFCE-next as the stand alone elogind , then that information regarding systemd based distributions may apply with some modifications.
I did try to configure /etc/elogind/logind.conf
Based on web suggestions I enabled some options https://wiki.archlinux.org/index.php...nation_request
with Plasma power options either enabled or disabled.
No luck unfortunately.
After today's Plasma upgrade (5.19.4) even suspend is not working anymore.
I can still put system to hybrid-suspend from command line though.
I did try to configure /etc/elogind/logind.conf
Based on web suggestions I enabled some options https://wiki.archlinux.org/index.php...nation_request
with Plasma power options either enabled or disabled.
No luck unfortunately.
After today's Plasma upgrade (5.19.4) even suspend is not working anymore.
I can still put system to hybrid-suspend from command line though.
Thank you for responding.
Considering that elogind is a quite new and experimental addition to Slackware, using Plasma5 and XFCE-next builds as testing playground, may be a need for some fine tuning to be complete integrated in Slackware. However, from my experience, it works like a charm as suspend and hibernate.
BUT, there is a trick: you should always use also the DBUS and PolKit shipped by Plasma5 or XFCE-next, as the counterparts from Slackware does not have support for elogind.
How those packages tends to be updated quite often by Mr. Volkerding - see the latest story of mozjs68 which certainly broken the polkit shipped initially by latest Plasma5, the things can go nuts regarding Plasma5 power management.
So, I suggest you to ensure that you synced and upgraded the latest packages from Plasma5, with great attention to polkit-0.117-x86_64-1alien.txz which was released later by Mr. Hameleers, and that you do not rollback by mistake to the Slackware stock packages.
Until Slackware finally replace ConsoleKit2 with elogind, we should be careful about those things.
Last edited by LuckyCyborg; 08-03-2020 at 06:01 PM.
Considering that elogind is a quite new and experimental addition to Slackware, using Plasma5 and XFCE-next builds as testing playground, may be a need for some fine tuning to be complete integrated in Slackware. However, from my experience, it works like a charm as suspend and hibernate.
BUT, there is a trick: you should always use also the DBUS and PolKit shipped by Plasma5 or XFCE-next, as the counterparts from Slackware does not have support for elogind.
How those packages tends to be updated quite often by Mr. Volkerding - see the latest story of mozjs68 which certainly broken the polkit shipped initially by latest Plasma5, the things can go nuts regarding Plasma5 power management.
So, I suggest you to ensure that you synced and upgraded the latest packages from Plasma5, with great attention to polkit-0.117-x86_64-1alien.txz which was released later by Mr. Hameleers, and that you do not rollback by mistake to the Slackware stock packages.
Until Slackware finally replace ConsoleKit2 with elogind, we should be careful about those things.
Thank you for the advice.
I my case the problem was that any modification of logind.conf leads to such behavior: lougout instead of suspend to RAM. So restoring logind.conf to its pristine state fixed the issue with logout instead of suspend.
I think that kde has buggy power management (by design/wontfix or not):
Only thing that I can do from kde/plasma is suspend to RAM and this is not working properly (touchpad after waking up from suspend to RAM is off and the only option is to restart system to get back touchpad).
On the other hand
pm-suspend works perfectly (touchpad working after system waking up)
pm-hibernate works
pm-suspend-hybrid works
So I created symlinks on the desktop to easily put system to sleep when on battery. The only drawback is that system will not go to sleep after period of inactivity but there is nothing I can do about it.
This would conclude current thread as I don't see any good way of fixing the problem.
I have tested today all the ways of hibernation from latest Plasma5, and they works as expected. Including even the hybrid-sleep.
In other hand, please note that Plasma5 relies on elogind for this hibernation business. And it does NOT use the pm-utils , but rather does its power management jobs alone.
I suggest you to test the things using directly the "loginctl" before to blame the power management from Plasma5.
This console utility named "loginctl" supports commands like
Code:
System Commands:
reload Reload the elogind config file
poweroff [TIME] [WALL...] Turn off the machine
reboot [TIME] [WALL...] Reboot the machine
suspend Suspend the machine to memory
hibernate Suspend the machine to disk
hybrid-sleep Suspend the machine to memory and disk
suspend-then-hibernate Suspend the system, wake after a period of
time and put it into hibernate
Last edited by LuckyCyborg; 08-04-2020 at 09:46 AM.
I have tested today all the ways of hibernation from latest Plasma5, and they works as expected. Including even the hybrid-sleep.
In other hand, please note that Plasma5 relies on elogind for this hibernation business. And it does NOT use the pm-utils , but rather does its power management jobs alone.
I suggest you to test the things using directly the "loginctl" before to blame the power management from Plasma5.
This console utility named "loginctl" supports commands like
Code:
System Commands:
reload Reload the elogind config file
poweroff [TIME] [WALL...] Turn off the machine
reboot [TIME] [WALL...] Reboot the machine
suspend Suspend the machine to memory
hibernate Suspend the machine to disk
hybrid-sleep Suspend the machine to memory and disk
suspend-then-hibernate Suspend the system, wake after a period of
time and put it into hibernate
loginctl suspend disables my touchpad
this is a bug (incomplete implementation - see suspend exercise below) in KDE otherwise, pm-suspend would not work either. However pm-suspend works and turns touchad on after weaking up.
I assume that pm works with my touchpad because it removes psmouse module before suspending/hybernating and loads psmouse module back at resume. Probably this is not something that kde/loginctl do.
if I run from konsole
Quote:
sudo modprobe -r psmouse
followed by
Quote:
loginctl suspend
then after weaking up system
Quote:
sudo modprobe psmouse
my touchpad works.
pm has this script (removing module before suspend and loading after resume) implemented, kde/plasma/loginctl do not
probably hibernate and suspend-hybrid in kde/plasma/loginctl also have something missing that would put to sleep my system.
In contrast pm just works.
I do not see any difference in opening konsole and issuing
loginct suspend
vs
pm-suspend
neither will automatically suspend OS after time of inactivity
Well, the difference is that you can issue as user (from group "power") those power management commands of loginctl, while the pm-utils commands needs the root account.
And even more importantly, I suspect that the "pm-utils" package will be removed once "elogind" is added to Slackware, because it super-seed the first.
Did you do not want to learn how to deal with this business, before be the case that you must deal with?
Quote:
Originally Posted by broch
also
loginctl suspend disables my touchpad similar to K Menu -> Leave -> Suspend
this is a bug in KDE otherwise, pm-suspend would not work either. However pm-suspend works and turns touchad on after weaking up.
It seems that KDE power has issue with my hardware and because pm works, so KDE issue is just a bug for me (as it is limited in therms of recognized hardware).
From my own experiences, neither elogind or Plasma5 will disable your touchpad. You blame erroneous both of those software.
The kernel itself fails to handle your touchpad when its driver wakes up. This usually could be fixed by removing the kernel module and reinserting it after wakeup.
Quote:
Originally Posted by broch
I assume that pm works with my touchpad because it removes psmouse module before suspending/hybernating and loads psmouse modele back at resume. Probably this is not something that kde/loginctl do.
There's the true explanation of WHY your pm-utils apparently works properly.
That's because YOU, dear Comrade Broch, previously you instructed the pm-utils to reload the "psmouse" kernel module with a shiny variable named SUSPEND_MODULES, right?
Your issue is that elogind does not use the pm-utils, then also your elogind should be instructed about reloading this particular kernel module which fails to wake-up in a proper way.
The bad news is that elogind has no shiny variable SUSPEND_MODULES, the good news is that you can create hooks as scripts put in /lib64/elogind/system-sleep
As an example, you can imagine an script /lib64/elogind/system-sleep/modules with a content like this:
Code:
#!/bin/bash
case $1/$2 in
pre/*)
# Put here any commands you want to be run when suspending or hibernating.
echo "Removing 'psmouse' for $2..."
modprobe -r psmouse
;;
post/*)
# Put here any commands you want to be run when resuming from suspension or thawing from hibernation.
echo "Waking up from $2 , adding 'psmouse' ..."
modprobe psmouse
;;
esac
BTW, this script must be executable. See there for futher details:
Well, the difference is that you can issue as user (from group "power") those power management commands of loginctl, while the pm-utils commands needs the root account.
And even more importantly, I suspect that the "pm-utils" package will be removed once "elogind" is added to Slackware, because it super-seed the first.
Did you do not want to learn how to deal with this business, before be the case that you must deal with?
From my own experiences, neither elogind or Plasma5 will disable your touchpad. You blame erroneous both of those software.
The kernel itself fails to handle your touchpad when its driver wakes up. This usually could be fixed by removing the kernel module and reinserting it after wakeup.
There's the true explanation of WHY your pm-utils apparently works properly.
That's because YOU, dear Comrade Broch, previously you instructed the pm-utils to reload the "psmouse" kernel module with a shiny variable named SUSPEND_MODULES, right?
Your issue is that elogind does not use the pm-utils, then also your elogind should be instructed about reloading this particular kernel module which fails to wake-up in a proper way.
The bad news is that elogind has no shiny variable SUSPEND_MODULES, the good news is that you can create hooks as scripts put in /lib64/elogind/system-sleep
As an example, you can imagine an script /lib64/elogind/system-sleep/modules with a content like this:
Code:
#!/bin/bash
case $1/$2 in
pre/*)
# Put here any commands you want to be run when suspending or hibernating.
echo "Removing 'psmouse' for $2..."
modprobe -r psmouse
;;
post/*)
# Put here any commands you want to be run when resuming from suspension or thawing from hibernation.
echo "Waking up from $2 , adding 'psmouse' ..."
modprobe psmouse
;;
esac
BTW, this script must be executable. See there for futher details:
In my humble opinion, this is the proper way to deal with your issue.
Hello LuckyCyborg,
Just wanted to thank you for help:
I found some old scripts dating from 2018 that probably interfered with hibernate and hybrid sleep.
After removing them all (hibernate and hybrid sleep) works .
Also your script for RAM suspend is better than mine so this works too.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.