On Sun 17 May 2020 at 00:02:20 (+1000), elvis wrote: > On 16/5/20 10:15 pm, Henning Follmann wrote: > > On Fri, May 15, 2020 at 11:39:44AM -0700, Chris Rhodin wrote: > > > > > > I've installed Debian Buster on a desktop system I use as a server. I > > > also > > > occasionally use this as a regular desktop system so it has a monitor, > > > keyboard, and GUI. During installation I selected the ssh server in > > > tasksel (so during installation there was some indication this was a > > > server). > > > > > > The problem I have is that when the console screen goes black and locks, > > > the system becomes unresponsive to network activity. If I have an ssh > > > session running when this occurs it stops responding. It doesn't kick me > > > off, the ssh connection is still there. If I then go to the console and > > > shake the mouse the screen lights up and the ssh session starts responding > > > like nothings wrong, until the console goes to sleep again. > > > > > > Searching online I found this command which seems to solve the problem: > > > > > > sudo systemctl mask sleep.target suspend.target hibernate.target > > > hybrid-sleep.target > > > > > > So my question is what is the correct way to manage this? Is there a > > > document that goes over the various power states and how they impact > > > running services? > > > > > Just disable following targets: > > > > systemctl mask sleep.target suspend.target hibernate.target > > hybrid-sleep.target > > > > That will avoid the system going to sleep. > > Instead of doing that, wouldn't the "correct" way involve editing > /etc/systemd/sleep.conf ? > > I ask because I edited the file and the system seems to have still > gone to sleep.. what is the point of a conf file if you still have to > mess with the base unit files?
The Dell that's just become available for my use (manufactured 2013) has CMOS settings which might be relevant; I've not come across these before. Deep Sleep Control enabled in S4 and S5 → disabled USB Wake Support enabled Wake on LAN/WLAN disabled → LAN Only Block Sleep disabled → Block Sleep (S3 State) Once or twice, the machine would go to sleep, and the only way to wake it up (having a unified wireless keyboard/mouse) was to press the power button, whereupon it would promptly shut down. That seems to be cured with these settings. (But I am ignorant on such things, so it could all be mere cargo-cult.) I've not made any configuration changes to sleep.conf. I do set RESUME=none in initramfs (swap is random-encrypted), and I also have \e[9;16] in /etc/issue, since buster, for blanking the screen. "Wake on LAN" is deceptive: I use that to wake it up when it's switched off. When it had gone to sleep, I couldn't login with ssh, nor would wakeonlan wake it up. (It's ethernet-connected, no wifi.) Cheers, David.