Suspension on my laptop (closing the lid) causes Wifi to not be available.
Hi, this is a long lasting problem that I didn't really manage to fix when I started using linux (Mint, Cinnamon). But now that I've been using it regularly for half a year and I have more experience in fiddling around, I'm trying to get it resolved.
Whenever I suspend the laptop (or close the lid, which does it automatically) the Wifi and sometimes an external monitor don't work anymore, I don't know what the problem is. The wifi is fixed by powering on and off again. To fix the monitor sometimes even powering off and on again didn't fix it, I usually waited for the next day and it worked again.
I've no idea of how to fix this (Linux Mint forums didn't help at the time)
Laptop is an MSI GS65-Stealth-Thin-8RF running Linux Mint, with Cinnamon Desktop
I'm not sure what the question here is. Are you wondering which level of suspension you want your laptop to go into when you close the lid?
You should understand ACPI sleep states when trying to setup whatever active states you want your machine to be in when you close the lid, because there is a chain of events that happen when you do so. Your machine may only support one, or a few states (s0-s3) that may not allow this. The first step is above, and the second is understanding what state your machine is being put into once you close that lid, so start there with Mint configuration and how it's dealing with the lid closing.
Is your laptop, by any chance, an HP? I had the same issue with wifi and finally, after about a year of frustration, found the solution HERE. To save a click, here's the part that worked for me, with the disclaimer that I don't honestly know how this works, but by the time I found it I was frustrated enough to run random code from the internet with sudo privileges on my main machine:
EDIT: on closer look, it's not much of a solution. I assume you've tried restarting the network service and that doesn't work either? Possibly you could automate the airplane mode key twice by triggering that after waking from suspend....
Do you have Nvidia GPU? I am not sure if that could be related, but sometimes my old laptop would behave funky after resuming it from sleep when using nouveau driver. Although generally I just wouldn't get any video output. But I could never get past login screen, and it sounds unlikely it would affect WiFi, but who knows?
Any additional details you can add would go a long way towards troubleshooting. That desktop are you using (ex: Gnome, KDE, etc) and what model of laptop, the full hardware specs including CPU, GPU, WiFi model, etc. Finally, you'll want to look at the system logs to see if there's anything useful in there after resuming from sleep (journalctl).
I'm trying to get the logs, but it's difficoult to paste them all here, I got a few on this link. But they all seem from 20 October, wierd. https://sharetext.me/nqz5mfph2y
I must have just missed that originally, I was commenting before coffee.
I see you have the combination graphics (Optimus is what it was originally called IIRC) which has a history of sleep wake issues, that might be a good place to start on the monitor search.
It's been a while, but if I recall correctly Linux has always had issues with resuming from suspend. I would set it to not suspend, make closing the lid do nothing.
Mhm, but it doesn't sound great. If you forget it's on, you put it in a backpack to then get it out at around 300 degrees. Sounds like a very bad idea.