Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 299650 - net-misc/networkmanager: restart /etc/init.d/netmount every time a new connection is made
Summary: net-misc/networkmanager: restart /etc/init.d/netmount every time a new connec...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Robert Piasek (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-01-04 18:07 UTC by Fabio Erculiani (RETIRED)
Modified: 2012-04-06 15:01 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
NetworkManager up-down script (01-netmount-up-down.rc,445 bytes, patch)
2010-01-04 18:08 UTC, Fabio Erculiani (RETIRED)
Details | Diff
new NetworkManager nfs script (01-netmount-up-down.rc,636 bytes, text/plain)
2010-02-23 23:35 UTC, Fabio Erculiani (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Fabio Erculiani (RETIRED) gentoo-dev 2010-01-04 18:07:55 UTC
Following "man NetworkManager" /etc/NetworkManager/dispatcher.d/ hooks creation. I made a rough (read: suboptimal) hook to make NetworkManager to restart netmount service every time a new network connection is made.
Of course there's a lot of room for improvements because the attached script is a  WORKSFORME one.
Lazy NetworkManager users will be happy to see some better integration by the way (with better > almost nothing).

Just place the attached file into that dir and restart NetworkManager. In "sabayon" overlay there's a patched networkmanager version containing that "fix".

Reproducible: Always

Steps to Reproduce:
Comment 1 Fabio Erculiani (RETIRED) gentoo-dev 2010-01-04 18:08:43 UTC
Created attachment 215188 [details, diff]
NetworkManager up-down script
Comment 2 Fabio Erculiani (RETIRED) gentoo-dev 2010-02-23 23:35:11 UTC
Created attachment 220897 [details]
new NetworkManager nfs script

After some testing, I realized that the currently attached script causes issues when nfs shares are not available and suspend-to-ram requests apparently because socket used by nfs is blocking (and kernel complains about it aborting STR).
So I made a (probably) even more rough version of it which works independently from netmount.

Comments? Rants?
Comment 3 SpanKY gentoo-dev 2010-07-05 05:08:17 UTC
why exactly do you want netmount restarted when reconnecting ?  sounds like a terrible idea to me.  i move between WAPs and wired systems and dont need to restart netmount when i'm on the same LAN.  all my NFS/CIFS mounts work fine.

obviously moving between LANs wouldnt work, but neither would restarting the init.d script.
Comment 4 Fabio Erculiani (RETIRED) gentoo-dev 2010-07-08 11:39:54 UTC
It works pretty well here when moving between different LANs. If you have a better solution to deal with NFS blocking sockets, just write it here.
Fact is: we have a problem that could lead user application to dead lock.
Comment 5 Pacho Ramos gentoo-dev 2012-04-06 15:01:01 UTC
This should be fixed in latest 0.9.x versions in the tree