1

I am running Xubuntu 14.04 LTS on Dell Vostro 5470. Wifi connects automatically after starting the laptop. The main problem is that wifi is turned off by default when waking the laptop from suspend after closing the lid. I tried

sudo rfkill list all

both bluetooth and wifi are soft-blocked. I would like the wifi to automatically reconnect after waking the laptop without using FN key.

Thanks in advance

6
  • Will the wireless restart if you do: sudo service network-manager restart?
    – chili555
    Mar 23, 2016 at 19:16
  • Wifi connects fine after restarting the service, however pressing FN key to enable networking after suspend results in failing connecting to the wifi network. :( Mar 24, 2016 at 10:26
  • Isn't your question how to enable networking again without using the Fn key? That's what I am trying to fix. Please close the lid; allow the computer to suspend; open the lid and do: sudo service network-manager restart Does the wireless start again if you do nothing else? If so, I think I can fix it.
    – chili555
    Mar 24, 2016 at 13:37
  • Yes, everything is as you say Mar 24, 2016 at 13:48

1 Answer 1

0

I suggest you try:

gksudo gedit /usr/lib/pm-utils/sleep.d/99restartNM

Use nano or kate or leafpad if you don't have the text editor gedit.

Write the following file:

#!/bin/bash

case "$1" in
  hibernate)
    # put commands to run on hibernation here
    ;;
  thaw)
    # put commands to run when returning from hibernation here
    ;;
  suspend)
    # put commands to run on suspend here
    ;;
  resume) 
    # put commands to run when returning from suspension
    service network-manager restart
    ;;
esac

Proofread carefully and give special attention to spacing and punctuation; save and close the text editor. Reboot and test.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .