After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 346615 - Network disable/enable not remembered after suspend
Network disable/enable not remembered after suspend
Status: RESOLVED FIXED
Product: NetworkManager
Classification: Platform
Component: general
0.7.x
Other Linux
: Normal normal
: ---
Assigned To: Dan Williams
Dan Williams
: 560143 622362 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-07-05 07:39 UTC by Wouter Bolsterlee (uws)
Modified: 2010-06-26 17:57 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Wouter Bolsterlee (uws) 2006-07-05 07:39:46 UTC
NetworkManager always enables the network after a suspend, even if it was explicitly disabled before the suspend:

1. Disable the network from the menu
2. Suspend your laptop
3. Wake up some time later (next train, in my case)

Expected:
4. Still a disabled network

Actual:
4. NM start scanning for wlan access points and connects to the train station's AP, eating my precious laptop battery power!
Comment 1 Wouter Bolsterlee (uws) 2006-07-05 07:40:22 UTC
Oh, this is NM 0.6.3
Comment 2 Wouter Bolsterlee (uws) 2006-09-20 11:15:54 UTC
Is this related to #353431 ?
Comment 3 Christopher Aillon 2007-06-09 16:04:56 UTC
No, they aren't related.  This seems to be a bug.  Basically, when you click the option in the applet, it sends the "sleep" or "wake" signals to the daemon.  The same happens when you suspend/resume...
Comment 4 Cosimo Cecchi 2008-11-18 09:49:01 UTC
This is still an issue with the 0.7 SVN snapshot used in Ubuntu Intrepid.
Comment 5 Dan Williams 2009-03-04 18:39:32 UTC
*** Bug 560143 has been marked as a duplicate of this bug. ***
Comment 6 Arnaud Faucher 2009-08-04 23:36:18 UTC
This bug does not affect me anymore. Can anybody else confirm ?
Comment 7 Dan Williams 2009-11-03 01:34:39 UTC
It still should be a problem if your suspend/resume support is properly working.  suspending via pm-utils tells NM to sleep, resuming tells NM to wake up.  So we're really overloading the sleep state here with both suspend/resume and networking enabled functionality.

You might check whether your pm-utils hooks (/usr/lib64/pm-utils/sleep.d/55NetworkManager or /usr/lib for 32-bit) use --print-reply in the dbus-send calls, which is necessary for proper suspend/resume support.  If they aren't there's a well-known dbus bug that looses the D-Bus message from dbus-send if dbus-send exits too quickly, causing NM to never get the sleep/wake messages.  But fixing that will bring back your problem of the enabled state getting reverted on resume.
Comment 8 Per Ångström 2010-02-08 14:55:22 UTC
I can easily reproduce this in NetworkManager Applet 0.7.998, Ubuntu 10.4 Alpha 2+.

My /usr/lib64/pm-utils/sleep.d/55NetworkManager script does use --print-reply.
Comment 9 Dan Williams 2010-02-09 01:11:00 UTC
(In reply to comment #8)
> I can easily reproduce this in NetworkManager Applet 0.7.998, Ubuntu 10.4 Alpha
> 2+.
> 
> My /usr/lib64/pm-utils/sleep.d/55NetworkManager script does use --print-reply.

Ah, right.  So the problem is that right now suspend/resume *is* Networking Enabled; that's what the pm-utils scripts poke.  It's a fairly large fix internally to add /another/ device block and make sure that the logic is correct for all the state changes.  So I think the behavior here is expected, but is obviously a bug.  It's been this way since 0.6 so it's not a really regression, but does need to get fixed because it's annoying.
Comment 10 Uqbar 2010-05-04 16:35:06 UTC
In NM 0.8, disabling the wireless network is not persistent after a boot.
I would expect that settings are kept between reboots.
Comment 11 Dan Williams 2010-05-06 22:59:19 UTC
(In reply to comment #10)
> In NM 0.8, disabling the wireless network is not persistent after a boot.
> I would expect that settings are kept between reboots.

Yeah, though that's a different bug than this one.
Comment 12 Dan Williams 2010-05-22 17:58:54 UTC
5ca1a9d546be81b54e57d525b54ff92597de6115 (0.7.x)
ee3ece9dac985034c5c1f81a6769b40fd7856579 (0.8.1)
fa70542c618665cf203a2b71fa0e504f759f7902 (master)
Comment 13 Dan Williams 2010-05-22 18:35:31 UTC
Applet commits:

7f247224c41754b8e76f0efb7e3cb593d7926ad8 (0.7.x)
f9a9bfc4d63a138ac81ee4f6d84b3d5d87bff250 (0.8.1)
adf56461a7859280f8ea1520c9689e9383fab3f6 (master)
Comment 14 Dan Williams 2010-06-26 17:49:58 UTC
*** Bug 622362 has been marked as a duplicate of this bug. ***
Comment 15 Uqbar 2010-06-26 17:57:13 UTC
(In reply to comment #11)
> (In reply to comment #10)
> > In NM 0.8, disabling the wireless network is not persistent after a boot.
> > I would expect that settings are kept between reboots.
> 
> Yeah, though that's a different bug than this one.

Really?
It sounds very similar while still different.
Anyway, also GNOME logoff/logon won't retain the disabled status.