GNOME Bugzilla – Bug 699755
bonding: NM repeatedly fails to finish a bonding connection with a slave
Last modified: 2013-05-07 20:58:37 UTC
I'm installing current master (commit 0a5f272) via Gentoo's live ebuild directly from git with the following configuration and the bond configuration activation just cycles and fails every time. I would like to know whether I'm doing something wrong or there's a bug in NetworkManager. /etc/NetworkManager/system-connections/Bond: [connection] id=Bond uuid=0334e9e3-f813-4650-b1ae-21ba0616e393 interface-name=testbond type=bond [bond] interface-name=testbond /etc/NetworkManager/system-connections/Slave: [connection] id=Slave uuid=a842e207-1116-4efe-8727-c1062534fff4 type=ethernet master=0334e9e3-f813-4650-b1ae-21ba0616e393 slave-type=bond [ethernet] mac=f0:de:f1:b8:6a:ee Log output (1 round): NetworkManager[11509]: <info> Auto-activating connection 'Bond'. NetworkManager[11509]: <info> Activation (testbond) starting connection 'Bond' NetworkManager[11509]: <info> (testbond): device state change: disconnected -> prepare (reason 'none') [30 40 0] NetworkManager[11509]: <info> Activation (testbond) Stage 1 of 5 (Device Prepare) scheduled... NetworkManager[11509]: <info> Activation (testbond) Stage 1 of 5 (Device Prepare) started... NetworkManager[11509]: <info> (testbond): taking down device. NetworkManager[11509]: <info> (testbond): bringing up device. NetworkManager[11509]: <info> Activation (testbond) Stage 2 of 5 (Device Configure) scheduled... NetworkManager[11509]: <info> Activation (testbond) Stage 1 of 5 (Device Prepare) complete. NetworkManager[11509]: <info> Activation (testbond) Stage 2 of 5 (Device Configure) starting... NetworkManager[11509]: <info> (testbond): device state change: prepare -> config (reason 'none') [40 50 0] NetworkManager[11509]: <info> Activation (testbond) Stage 2 of 5 (Device Configure) successful. NetworkManager[11509]: <info> Activation (testbond) Stage 3 of 5 (IP Configure Start) scheduled. NetworkManager[11509]: <info> Activation (testbond) Stage 2 of 5 (Device Configure) complete. NetworkManager[11509]: <info> Activation (testbond) Stage 3 of 5 (IP Configure Start) started... NetworkManager[11509]: <info> (testbond): device state change: config -> ip-config (reason 'none') [50 70 0] NetworkManager[11509]: <info> (testbond): IPv4 config waiting until carrier is on NetworkManager[11509]: <info> (testbond): IPv6 config waiting until carrier is on NetworkManager[11509]: <info> Activation (testbond) Stage 3 of 5 (IP Configure Start) complete. NetworkManager[11509]: <info> (eth0): carrier now ON (device state 30) NetworkManager[11509]: <info> Auto-activating connection 'Slave'. NetworkManager[11509]: <info> Activation (eth0) starting connection 'Slave' NetworkManager[11509]: <info> (eth0): device state change: disconnected -> prepare (reason 'none') [30 40 0] NetworkManager[11509]: <info> Activation (eth0) Stage 1 of 5 (Device Prepare) scheduled... NetworkManager[11509]: <info> Activation (eth0) Stage 1 of 5 (Device Prepare) started... NetworkManager[11509]: <info> Activation (eth0) Stage 2 of 5 (Device Configure) scheduled... NetworkManager[11509]: <info> Activation (eth0) Stage 1 of 5 (Device Prepare) complete. NetworkManager[11509]: <info> Activation (eth0) Stage 2 of 5 (Device Configure) starting... NetworkManager[11509]: <info> (eth0): device state change: prepare -> config (reason 'none') [40 50 0] NetworkManager[11509]: <info> Activation (eth0) Stage 2 of 5 (Device Configure) successful. NetworkManager[11509]: <info> Activation (eth0) Stage 3 of 5 (IP Configure Start) scheduled. NetworkManager[11509]: <info> Activation (eth0) Stage 2 of 5 (Device Configure) complete. NetworkManager[11509]: <info> Activation (eth0) Stage 3 of 5 (IP Configure Start) started... NetworkManager[11509]: <info> (eth0): device state change: config -> ip-config (reason 'none') [50 70 0] NetworkManager[11509]: <info> (eth0): taking down device. NetworkManager[11509]: <info> (testbond): enslaved bond slave eth0 NetworkManager[11509]: <info> Activation (eth0) connection 'Slave' enslaved, continuing activation NetworkManager[11509]: <info> (testbond): IPv4 config waiting until carrier is on NetworkManager[11509]: <info> (testbond): IPv6 config waiting until carrier is on NetworkManager[11509]: <info> Activation (eth0) Stage 3 of 5 (IP Configure Start) complete. NetworkManager[11509]: <info> (eth0): device state change: ip-config -> secondaries (reason 'none') [70 90 0] NetworkManager[11509]: <info> (eth0): device state change: secondaries -> activated (reason 'none') [90 100 0] NetworkManager[11509]: <info> Activation (eth0) successful, device activated. NetworkManager[11509]: <info> (eth0): carrier now ON (device state 100) NetworkManager[11509]: <info> (testbond): carrier now ON (device state 70) NetworkManager[11509]: <warn> (testbond): unhandled IPv4 config method; will fail NetworkManager[11509]: <info> (testbond): device state change: ip-config -> failed (reason 'none') [70 120 0] NetworkManager[11509]: <warn> Activation (testbond) failed for connection 'Bond' NetworkManager[11509]: <info> (testbond): released bond slave eth0 (success 1) NetworkManager[11509]: <info> (eth0): bringing up device. NetworkManager[11509]: <warn> Activation (eth0) connection 'Slave' master failed NetworkManager[11509]: <info> (testbond): IPv6 config waiting until slaves are ready NetworkManager[11509]: <info> (eth0): carrier now ON (device state 100) NetworkManager[11509]: <info> (eth0): device state change: activated -> failed (reason 'dependency-failed') [100 120 50] NetworkManager[11509]: <warn> Activation (eth0) failed for connection 'Slave' NetworkManager[11509]: <info> (testbond): device state change: failed -> disconnected (reason 'none') [120 30 0] NetworkManager[11509]: <info> (testbond): deactivating device (reason 'none') [0] NetworkManager[11509]: <info> (eth0): device state change: failed -> disconnected (reason 'none') [120 30 0] NetworkManager[11509]: <info> (eth0): deactivating device (reason 'none') [0] NetworkManager[11509]: <info> Auto-activating connection 'Bond'.
What's the 'nmcli con list uuid <uuid>' output for that slave connection?
Pavel confirmed that the connection has no IPv4 setting, which is expected, and points to a bug in the core daemon.
So the issue is the master; due to some recent changes some settings plugins aren't sending an IP config setting, which should default to "auto" for all devices except slaves. Unfortunately that now triggers some older code, which wasn't updated for that.
First pass at this is in dcbw/master-ip-config-fix
looks good. the only thing I'd say is that here: > const char *method = NM_SETTING_IP4_CONFIG_METHOD_AUTO; > ... > ... >+ if (priv->master) /* eg, device is a slave */ > method = NM_SETTING_IP4_CONFIG_METHOD_DISABLED; >+ else if (s_ip4) >+ method = nm_setting_ip4_config_get_method (s_ip4); > I think it would make things more obvious if you put the default value here as well: else method = NM_SETTING_IP4_CONFIG_METHOD_AUTO; rather than initializing it at the top. likewise for ipv6
Fixed and merged.