Another issue and my hacky solution:
Wi-fi often stopped working after resuming from suspend or hibernation in the same area, even though network-manager showed the laptop still connected to the same network. Disconnecting and reconnecting to the same network gets it working again, but it is annoying.
Previously, I was using
this fix in the wiki, but it didn't work in MX 19, even when I changed the driver to the new one for MX 19, from "iwlwifi" to "iwlmvm". In fact, the wiki method broke hibernation--the machine just got to 4% and then locked up.

Unloading and reloading the driver manually resulted in a disconnect and reconnect, as I wanted, so I put a scriptlet named "wifi-fix" in usr/local/bin:
Code: Select all
#!/bin/sh
rmmod iwlmvm
sleep 1
modprobe iwlmvm
and then noticed touchpad-indicator, which we have installed by default, installs
/etc/pm/sleep.d/00_check_touchpad_status, so I added my scriptlet to it:
Code: Select all
#!/bin/sh
#copy to /etc/pm/sleep.d
LOGFILE="/var/log/sleep.log"
case "$1" in
resume|thaw)
echo "Resumed normal from suspend at `date`" >> "$LOGFILE"
/usr/bin/python3 /opt/extras.ubuntu.com/touchpad-indicator/share/touchpad-indicator/check_touchpad_status.py resume
/usr/local/bin/wifi-fix
echo "Touchpad enabled"
;;
esac
and that works to quickly unload and reload the driver after a resume. I assume that editing the original touchpad-indicator file, but saving it as another file, something like "30_wi-fi_fix_after_resume", with the touchpad-indicator parts removed will also work, along with just putting the rmmod and modprobe commands directly in that file, but haven't tested that. Maybe one of our scripting gurus can help with that.