Arch Linux

Please read this before reporting a bug:

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

REPEAT: Do NOT report bugs for outdated packages!

FS#31037 - [netcfg] pm-utils integration does not suspend/resume net-auto-wireless

Attached to Project: Arch Linux
Opened by Matt Phipps (garaden) - Monday, 06 August 2012, 22:54 GMT
Last edited by Jouke Witteveen (jouke) - Friday, 10 August 2012, 20:26 GMT
Task Type Feature Request
Category Packages: Core
Status Closed
Assigned To Jouke Witteveen (jouke)
Architecture All
Severity Low
Priority Low
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 1
Private No


Description: netcfg includes /usr/lib/pm-utils/sleep.d/50netcfg which does a nice job of suspending and resuming netcfg profiles using "netcfg all-suspend" and "netcfg all-resume". Unfortunately, net-auto-wireless is confused by pm-utils suspending and resuming wireless profiles under its nose, so upon resume, wpa_actiond dies. I've attached a patched version of 50netcfg that should fix the problem.

Additional info:
* Package version: netcfg 2.8.8-1, wpa_actiond 1.3-1, wpa_supplicant 1.0-1, pm-utils 1.4.1-5

IIRC if you're lucky enough to resume in the same network you were in when you suspended, then your profile will come back up OK but roaming won't work. If not, then nothing works until you restart net-auto-wireless at which point it will complain that wpa_actiond died a premature death.

Steps to reproduce:
1. Start net-auto-wireless.
2. Suspend with pm-suspend.
3. Resume (presumably with pm-resume). Note that wpa_actiond has died unexpectedly.
This task depends upon

Closed by  Jouke Witteveen (jouke)
Friday, 10 August 2012, 20:26 GMT
Reason for closing:  Won't fix
Additional comments about closing:  We either need a really good solution or stick with the current, minimal setup.
Comment by Matt Phipps (garaden) - Monday, 06 August 2012, 23:09 GMT Comment by Jouke Witteveen (jouke) - Thursday, 09 August 2012, 15:48 GMT
We used to have a more complex file:
This was buggy and unmaintained.

Currently we ship /usr/share/doc/netcfg/contrib/pm-utils.handler as a suggested more complex script. You can always override the default file by creating /etc/pm/sleep.d/50netcfg (either empty, disabling the default, or containing a better script). This file will survive netcfg upgrades.

As it is very hard to get this right for all situations, I would like to keep the oversimplified default script until someone comes up with a holy grail. Use cases and system configurations differ greatly between netcfg users, so I would suggest to write your own pm-utils script in the aforementioned location. A script tailored to your own situation would usually only be a few lines.
Comment by Matt Phipps (garaden) - Thursday, 09 August 2012, 17:18 GMT
That makes sense. I'd never actually noticed the "contrib" directory: I'm especially sad to have missed the "logging" one, which looks really useful!

That said, I don't think the "contrib" directory is mentioned anywhere^H^H^H^H^H^H^H^Hright in NETCFG(8) under "Files". Whoops, must have glossed right over that one.

Thanks for your help!