Network Manager IPv6+IPv4 and if-up.d scripts

Bug #1164879 reported by Jose Andres Arias Velichko
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Linux Mint
New
Undecided
Unassigned
NetworkManager
New
Undecided
Unassigned
network-manager (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

I've several scripts which runs when my interface is brought up/down. Depending on the network my laptop is connected to, it starts/applys different settings. This scripts are located in /etc/network/{if-up.d,if-post-down.d}.
Recently we have implemented IPv6 in our company and I've noticed that the scripts topped to work.
Investigating, I've found that a IPv6 is configured automatically first and later eth0 receives IPv4 address, but this time the scripts are not called again.
So, the problem is when the script runs, we don't have IPv4 adress yet, and when we receive IPv4 address, the scripts are not called again.
And this is not an expected behaviour.

As a workarround, I've set to ignore "IPv6" in a network manager. But this problem may affect all the scripts located in /etc/network/if-up.d/, such as "000resolvconf avahi-autoipd avahi-daemon ntpdate openssh-server samba upstart wpasupplicant", not only my homemade scritps.

Step to reproduce the problem:
1. Get the mixed environment (IPv6/IPv4), with a DHCP for IPv4 and auto-configuration for IPv6. The IPv4 DHCP server is slower than IPv6 configuration.
2. Allow the Network manager to connect.
3. The scripts only will run once, when IPv6 address wil lbe received (Or I suppouse if IPv4 is faster, then only when IPv4 address is received, but not tested).

My Linuxmint version:
lsb_release -a
No LSB modules are available.
Distributor ID: LinuxMint
Description: Linux Mint 14 Nadia
Release: 14
Codename: nadia

Thanks in advance

Revision history for this message
Steve Dodd (anarchetic) wrote :

Also seeing this on Ubuntu 14.04. Mixed network, have an if-up.d script to restart minidlna - but sometimes it gets restarted after an IPv6 address has been obtained but before an IPv4 address is configured.

Revision history for this message
Phillip Sz (phillip-sz) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. Please execute the following command, as it will automatically gather debugging information, in a terminal:
apport-collect BUGNUMBER
When reporting bugs in the future please use apport by using 'ubuntu-bug' and the name of the package affected. You can learn more about this functionality at https://wiki.ubuntu.com/ReportingBugs.

Revision history for this message
Michael Schaller (misch-9) wrote :

This is the upstream bug https://bugzilla.gnome.org/show_bug.cgi?id=689741.
Please read the upstream discussion and chime in.

If you backport the following commit then your scripts should get the data:
http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=11f9855223966c4fd927fe83e2cd9a623a74acad

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in network-manager (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.