WiFi problems after waking up from sleep, Ubuntu 16.10

After installing Ubuntu 16.10 I occasionally had problems with WiFi after waking up from sleep.

But of course there’s a workaround (credit to Joakim Koed on askubuntu.com and the solution).

sudo bash -c 'cat >/etc/systemd/system/wake-up.service <<EOF
[Unit]
Description=Restart networkmanager at resume
After=suspend.target
After=hibernate.target
After=hybrid-sleep.target

[Service]
Type=oneshot
ExecStart=/bin/systemctl restart network-manager.service

[Install]
WantedBy=suspend.target
WantedBy=hibernate.target
WantedBy=hybrid-sleep.target
EOF'
sudo systemctl enable wake-up.service

Measure WiFi signal strength

When installing a wireless network in our cabins, I had to make some optimizations, like buying bigger antennas. To verify that the signal got better at some key areas I went around and checked the signal, with this little script:

Then I imported the result in Google Sheets and drew a really simple blueprint over the cabins and plotted the measured areas to see how good the signal was.