I am affected by the bug that occasionally my wifi connection is broken on resume from suspend. The problem manifests as follows:


enter image description here

What are possible commands I can try to run from the command-line to reset my wifi connection without having to restart my system?


Please open a terminal and do:

sudo gedit  /etc/systemd/system/wifi-resume.service

Use nano or kate or leafpad if you don't have the text editor gedit. A new empty file will open. Add the following:

Description=Local system resume actions

ExecStart=/bin/systemctl restart network-manager.service


Proofread carefully twice, save and close the text editor. Now do:

sudo chmod +x  /etc/systemd/system/wifi-resume.service

And next:

sudo systemctl enable wifi-resume.service

Reboot and let us know if the problem is solved.

  • Does this depend on systemd | upstart? – Pilot6 Mar 3 '16 at 14:37
  • 1
    This is the systemd method. – chili555 Mar 3 '16 at 20:41
  • 1
    Worked for me on 16.04. Anyway, before applying this new service, it is advisable to first run /bin/systemctl restart network-manager.service natively in the shell and see if it helps. If not, this extra service does neither. – Tik0 Jan 19 '18 at 7:06
  • 1
    This did not work for me on 18.04. – Russell Richie Jun 19 '18 at 20:21
  • 1
    @RussellRichie I suggest that you start your own new question. – chili555 Jun 19 '18 at 20:30

The command is

sudo service network-manager restart

You can try

sudo /etc/init.d/network-manager restart
dhclient wlan0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.