Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#8307 - SUspend renders networkmanager inoperable

Attached to Project: Arch Linux
Opened by name withheld (Gullible Jones) - Sunday, 14 October 2007, 23:32 GMT
Last edited by Jan de Groot (JGC) - Friday, 09 May 2008, 13:27 GMT
Task Type Bug Report
Category Packages: Testing
Status Closed
Assigned To No-one
Architecture All
Severity High
Priority Normal
Reported Version 2007.08-2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

After resuming from software suspend, the network manager applet often shows no connection, and its right-click menu shows no available wired or wireless networks. This remains the case when pm-utils is configured to unload and reload the modules needed for networking (via /etc/pm/config.d/config or /etc/pm/config.d/modules, using SUSPEND_MODULES="[modules]"). At first I thought that pm-utils wasn't reloading the modules properly, but reloading ndiswrapper and sky2 did not fix the situation.

Furthermore, attempts to restart the networkmanager rc.d script always fail; restarting dhcdbd first is successful, but will not impact the later failure of networkmanager to restart.

(Notably, the rc.d script always shows *stopping* networkmanager as successful, even after a previous restart attempt has failed; it's pretty obvious that networkmanager is not running and cannot be started, so this is probably a minor bug in the script.)

Additional info:
* pm-utils 0.99.3-2; networkmanager 0.6.5-3
* using ndiswrapper for wireless, sky2 for wired connection


Steps to reproduce:

1. With networkmanager handling your connection, suspend with pm-utils, using the Gnome power management menu, hotkeys, the CLI, etc.
2. Resume from suspend. The network applet's menu will show no connections and nothing to connect to.
3. Open a terminal and restart the networkmanager rc.d script. No matter how many times you do this, it will always claim that stopping networkmanager was successful and starting it failed.
This task depends upon

Closed by  Jan de Groot (JGC)
Friday, 09 May 2008, 13:27 GMT
Reason for closing:  Fixed
Comment by Jan de Groot (JGC) - Monday, 15 October 2007, 05:48 GMT
I've seen this one on my laptop (ipw3495) too. Right-clicking the applet, deselect the "enable networking" and do the same operation again to select it and networkmanager starts working again. I still have to find out why it's failing.
Comment by name withheld (Gullible Jones) - Monday, 15 October 2007, 05:57 GMT
Hmm... IIRC I tried that and it failed. I'll see if it works (again?) but I'm pretty sure it doesn't, at least with me.
Comment by Allan McRae (Allan) - Monday, 15 October 2007, 08:29 GMT
I have "/etc/rc.d/networkmanager restart" in /etc/pm/sleep.d/000hacks. According to the pm-utils logs and the continued working of my network, networkmanager restarts fine.

Comment by name withheld (Gullible Jones) - Thursday, 25 October 2007, 21:41 GMT
FWIW this also seems to happen with the network script, though in a different way. After coming out of suspend, wired access is down, with dhcpcd apparently running on eth0. Restarting the network script succeeds (and outputs the contents of ifconfig for some reason), but doesn't bring back the wired connection; to do that, you have to run dhcpcd on eth0 after restarting the script. Reloading the ethernet module you use doesn't affect anything. It doesn't make a whole lot of sense to me.

(BTW, is there a way to specify to pm-utils which rc.d scripts to unload on suspend and reload on resume, as with modules (SUSPEND_MODULES="")?)
Comment by name withheld (Gullible Jones) - Saturday, 27 October 2007, 23:38 GMT
Hmm, pm-utils seems to have a special script for dealing with networkmanager. /usr/lib/pm-utils/sleep.d/10NetworkManager:

#!/bin/bash

. /usr/lib/pm-utils/functions

suspend_nm() {
# Tell NetworkManager to shut down networking
dbus-send --system \
--dest=org.freedesktop.NetworkManager \
/org/freedesktop/NetworkManager \
org.freedesktop.NetworkManager.sleep
}

resume_nm() {
# Wake up NetworkManager and make it do a new connection
dbus-send --system \
--dest=org.freedesktop.NetworkManager \
/org/freedesktop/NetworkManager \
org.freedesktop.NetworkManager.wake
}

case "$1" in
hibernate|suspend)
suspend_nm
;;
thaw|resume)
resume_nm
;;
*)
;;
esac

exit $?


Maybe there's some kind of problem with networkmanager and dbus --send?
Comment by name withheld (Gullible Jones) - Tuesday, 30 October 2007, 01:02 GMT
Update: it seems like there's an unresponsive session of NetworkManager running after suspend, which doesn't work and prevents the daemon from being restarted. Running 'killall -9 NetworkManager' as root, then starting the daemon again, makes things work.
Comment by Loic Nageleisen (lloeki) - Monday, 26 November 2007, 08:55 GMT
experiencing it here too. after resume, gnome nm-applet (btw weird name since it's not even a panel applet) icon disappears from tray
then I do:
$ sudo /etc/rc.d/networkmanager restart
:: Stopping NetworkManager [FAIL]
:: Starting NetworkManager [DONE]
and it comes back.

for now I'll use a pm hook to restart it
Comment by Loic Nageleisen (lloeki) - Monday, 26 November 2007, 09:01 GMT
well, if I use a pm-hook to restart nm, I experience the situation of gullible jones. that is it can't be restarted.
my pm hook is now:
if [ "$1" == "resume" ] || [ "$1" == "thaw" ]; then
killall -9 NetworkManager
/etc/rc.d/networkmanager restart
fi
Comment by Riri (chicha) - Friday, 09 May 2008, 12:56 GMT
Hello !

A new version of Networkmanager is out : 0.6.6-1
Is this problem still valid ?

Thank you very much !
Comment by name withheld (Gullible Jones) - Friday, 09 May 2008, 13:19 GMT
Nope. Works fine currently.

Loading...