Auto wifi after resume

This is not strictly a peppermint problem as it has happened before on linux mint17 cinnamon.
http://linuxforums.org.uk/index.php?topic=11845.msg94633#msg94633 hope the link works.
I think its a conflict with my hardware.

when I resume by opening lid, a box requesting wi fi authorisation pops up, if I click on connect the box just keeps reappearing.
If I click on cancel then click on the button on panel, then click on my wifi connection it connects.

Because I want to keep pep 5 until the next LTS, it would be good if it could be sorted.

thanks in advance

Keith

When it resumes from suspend and asks for authorisatioon, leave it, just open a terminal and run:

nmcli nm enable false ; nmcli nm enable true

does wifi automatically authenticate ?

Effectively that’s disabling networking, then re-enabling it again.

If that works … maybe we can script it.

Hi Mark.

Yes that works :slight_smile:

Let’s try this…

Open a terminal and run:

sudo touch /etc/pm/sleep.d/nm-resume

then

sudo chmod +x /etc/pm/sleep.d/nm-resume

then

sudo gedit /etc/pm/sleep.d/nm-resume

When a BLANK file opens, make it read:-

#!/bin/sh

# This script gets NetworkManager out of suspend.
case $1 in
     suspend|suspend_hybrid|hibernate)
    # Nothing needs to go here.
        ;;
     resume|thaw)
    nmcli nm sleep false
        ;;
esac

SAVE the file … test resume from suspend

sorry for the delay (us old ones have to go to bed early) :wink:

copied and pasted your instructions (twice), but did not work.

after getting so close to a solution,
is it possible anyone knows how to proceed, because this OS is the so far the best I’ve used and it seems a shame one small problem is spoiling the experience.

Thanks in anticipation.

Keith

Can you post the result of:

ls /etc/pm/sleep.d

keith@keith-Lenovo-G550 ~ $ ls /etc/pm/sleep.d
10_grub-common nm-resume nm-resume.sh
10_unattended-upgrades-hibernate nm-resume~ nm-resume.sh~
keith@keith-Lenovo-G550 ~ $

thanks

It appears to be ignoring the syntax that used to work … I’m still looking for a way to run commands upon resume.

Meanwhile, get rid of all those nm-resume files so they don’t interfere with anything we try in the future

cd /etc/pm/sleep.d

then

sudo rm -v nm-resume*

I’ll get back to this if I find anything

OK