Hmm, for some reason that doesn't work when the command is bound to a shortcut key. I'll try the other suggestion... sudo 'pm-suspend'PaulR wrote: Tue Sep 12, 2023 9:21 amThat suspends the system instantly but I can only wake it up using the power button, the keyboard is 'dead'. I wouldn't mind that though provided it works consistently. I'll hook it up to the hotkey and see how it goes.Charlie Brown wrote: Mon Sep 11, 2023 3:33 pm You can try this first in a terminal, in case of success change your hotkey etc..
Code: Select all
sudo sh -c 'echo mem > /sys/power/state'
Thanks again Charlie Brown!
Suspend command keyboard shortcut [Solved]
Re: Suspend command keyboard shortcut
Re: Suspend command keyboard shortcut
@PaulR I'm not sure why it's not working for you. I created a shortcut on a new MX-23 XFCE install and it works.
You do not have the required permissions to view the files attached to this post.
This is my Fluxbox . There are many others like it, but this one is mine. My Fluxbox is my best friend. It is my life.
I must master it as I must master my life. Without me, my Fluxbox is useless. Without my Fluxbox, I am useless.
I must master it as I must master my life. Without me, my Fluxbox is useless. Without my Fluxbox, I am useless.
Re: Suspend command keyboard shortcut
I guess you're using either a wireless or a usb keyboard (I wish you could try with an older PS/2 connection).
At least out of curiosity (and it may be a good feedback for devs) you can try all of these when booted with systemd , and especially there.
At least out of curiosity (and it may be a good feedback for devs) you can try all of these when booted with systemd , and especially
Code: Select all
systemctl suspend
Re: Suspend command keyboard shortcut
... You can even try:
(the hybrid one does them together: either to ram and to disk)
Code: Select all
sudo pm-hibernate
Code: Select all
sudo pm-suspend-hybrid
Re: Suspend command keyboard shortcut
@siamhie It's always worked ok in the past, just this last few weeks it's been acting up.
@Charlie Brown It's a USB keyboard, I've been using the same one for maybe 3 or 4 years.
It worked faultlessly all day yesterday using but first time I tried it today the problem recurred - mouse cursor frozen and keyboard inoperable. The power button brought up the log out dialog but I couldn't choose any of the options so it was a case of holding in the power button to turn off.
I've decided to change tack: I've removed the shortcut and will use the power button to suspend instead... I just need to get used to that after years of pressing the [Pause] key!
@Charlie Brown It's a USB keyboard, I've been using the same one for maybe 3 or 4 years.
It worked faultlessly all day yesterday using
Code: Select all
sudo 'pm-suspend'
I've decided to change tack: I've removed the shortcut and will use the power button to suspend instead... I just need to get used to that after years of pressing the [Pause] key!
Re: Suspend command keyboard shortcut
PaulR wrote: Thu Sep 14, 2023 2:33 am @siamhie It's always worked ok in the past, just this last few weeks it's been acting up.
It worked faultlessly all day yesterday usingbut first time I tried it today the problem recurred - mouse cursor frozen and keyboard inoperable. The power button brought up the log out dialog but I couldn't choose any of the options so it was a case of holding in the power button to turn off.Code: Select all
sudo 'pm-suspend'
@PaulR Try this. Create another user account (MX User Manager) and see if you can replicate the issue.
This is my Fluxbox . There are many others like it, but this one is mine. My Fluxbox is my best friend. It is my life.
I must master it as I must master my life. Without me, my Fluxbox is useless. Without my Fluxbox, I am useless.
I must master it as I must master my life. Without me, my Fluxbox is useless. Without my Fluxbox, I am useless.
Re: Suspend command keyboard shortcut
Thanks for the suggestion but it isn't really practical; since the problem is intermittent I'd have to be logged in as that user for possibly a day or more at a time to see if it recurs and I have stuff to do in my usual account.siamhie wrote: Thu Sep 14, 2023 11:20 am @PaulR Try this. Create another user account (MX User Manager) and see if you can replicate the issue.
Re: Suspend command keyboard shortcut
Using the power button for suspend has worked for three days without fault. However, I just pressed it, the screen blanked then came back on after a short pause and the mouse and keyboard were inoperable. Maybe I should try MX23.
Re: Suspend command keyboard shortcut
Nothing to lose to try post #4 and it takes just a few minutes since it's a desktop (though the problem is just when suspending). Of course the rest is up to you.
Re: Suspend command keyboard shortcut
Checked this, all seems ok.Charlie Brown wrote: Sun Sep 17, 2023 5:49 am Nothing to lose to try post #4 and it takes just a few minutes since it's a desktop (though the problem is just when suspending). Of course the rest is up to you.
I've switched to a wireless mouse rather than the USB one I was using. Now when I press the power button to suspend, the screen blanks for a very short time then comes back on as per post #28. However, the wireless mouse continues to work but the keyboard is inoperable - very confusing. I wonder if it's possible to suspend from a live USB so I could try MX23 or some other distro to see what happens...?