Bug 1172734 - NetworkManager Regression: teamd can no longer create a team device.
Summary: NetworkManager Regression: teamd can no longer create a team device.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: NetworkManager
Version: 21
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Lubomir Rintel
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-12-10 16:03 UTC by colin
Modified: 2015-02-23 09:14 UTC (History)
6 users (show)

Fixed In Version: NetworkManager-0.9.10.1-1.2.20150109git.fc21
Clone Of:
Environment:
Last Closed: 2015-02-23 09:14:34 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
excert from /var/log/messages (5.46 KB, text/plain)
2014-12-10 16:03 UTC, colin
no flags Details
Journal output showing failure (34.09 KB, text/plain)
2015-02-16 22:47 UTC, Dan Mossor [danofsatx]
no flags Details

Description colin 2014-12-10 16:03:08 UTC
Created attachment 966887 [details]
excert from /var/log/messages

Description of problem:

while NetworkManager running cannot create a team device.
teamd -d succeeds, but the device is immediately disapeared.

Version-Release number of selected component (if applicable):

[root@localhost ~]# yum info NetworkManager
Loaded plugins: langpacks
Installed Packages
Name        : NetworkManager
Arch        : x86_64
Epoch       : 1
Version     : 0.9.10.0
Release     : 14.git20140704.fc21

[root@localhost ~]# yum info teamd
Loaded plugins: langpacks
Installed Packages
Name        : teamd
Arch        : x86_64
Version     : 1.14
Release     : 1.fc21


How reproducible:

Always.

Steps to Reproduce:

1.Test system is F21 Server KVM with functioning Linux Bridged eth0 and functioning OVS-bridged eth1

2.Try to create a team device e.g. 'teamd -d'
3.no team device exists in 'ip link'

Actual results:
/var/log/messages shows device created and immediately destroyed by NetworkManager

Expected results:

team device should be created and useable. 

Additional info:
teamd device creation is fully functional on Fedora 21 after executing 
systemctl stop NetworkManager.service

This seems to be a NetworkManager regression as I have it working under F20.
Initially raised problem on teamd mailing list where 
Jiri Pirko suggetsed that I contact NetworkManager folks.

Another potential data point: nmcli however was able to create a team device- (not that that was much use to me with thi Regression)
see:
 
https://lists.fedorahosted.org/pipermail/libteam/2014-December/000330.html

Comment 1 Dan Williams 2014-12-10 17:00:39 UTC
This is clearly an NM bug and NM should not be doing this.  NM should be treating the team interface as an externally-created interface that NM does not touch until the user requests NM to do so (if ever).

Comment 2 Lubomir Rintel 2014-12-11 10:21:16 UTC
Taking this. I've done changes related to this in master and will backport the fix.

Comment 3 Lubomir Rintel 2014-12-16 16:32:18 UTC
lr/teamd-rh1172734 ready for review.

Comment 4 Lubomir Rintel 2014-12-16 16:35:06 UTC
Also, the connection assumption does not really work without: https://github.com/jpirko/libteam/commit/870be5ad91ca0bf380dc3ffcad919ec94ff28958

Comment 5 Dan Winship 2015-01-05 16:16:08 UTC
If you want nm_device_team_watch_dbus() to be called for all NMDeviceTeam objects, you should override constructed() and do it there, rather than doing it from the _new* methods.

Other than that, looks good.

Comment 6 Lubomir Rintel 2015-01-07 15:03:34 UTC
(In reply to Dan Winship from comment #5)
> If you want nm_device_team_watch_dbus() to be called for all NMDeviceTeam
> objects, you should override constructed() and do it there, rather than
> doing it from the _new* methods.

Okay, that avoid some code duplication too.

Done.

> Other than that, looks good.

Updated branch: lr/teamd-rh1172734

Comment 7 Dan Winship 2015-01-08 13:18:03 UTC
looks good, although:

>+	if (G_OBJECT_CLASS (nm_device_team_parent_class)->constructed)
>+		G_OBJECT_CLASS (nm_device_team_parent_class)->constructed (object);

You don't actually need the if(); GObjectClass defines a dummy constructed() method, specifically so that you can chain up without needing to check that it's non-NULL first.

Comment 8 Lubomir Rintel 2015-01-08 15:39:59 UTC
Pushed to master

8c32ea9 libnm-glib/nm-client: zero the CheckConnectivityData structure
15acfac team: improve handling of externally managed devices (rh #1172734)
03a5a85 team: get configuration only when teamd appears on bus for externally added interfaces
744e35e Revert "team: start teamd when ensuring team connection else teamdctl_connect() fails"

Backported to 0.9.10 branch as well; along with a related fix by Thomas

colin, the package is being built here:
http://koji.fedoraproject.org/koji/taskinfo?taskID=8560171

I didn't submit an update yet, but we'll hopefully be releasing a new version of 0.9.10 branch along with a Fedora package update soon.

Comment 9 colin 2015-01-09 12:30:26 UTC
Great!

I can test the fix on the test VM which triggered this bug.

@Lubomir I don't see any installables at that link, just src rpms ?

Will check back later.

 
Colin.

Comment 10 Lubomir Rintel 2015-01-09 13:27:02 UTC
(In reply to colin from comment #9)
> Great!
> 
> I can test the fix on the test VM which triggered this bug.
> 
> @Lubomir I don't see any installables at that link, just src rpms ?

The green links are links to successful rebuilds of a src rpm for a particular architecture. Please follow one that ends with your architecture name and you'll be able to download binary packages.

It's a "scratch build", the links will expire in around a week I think.

Comment 11 Lubomir Rintel 2015-01-13 11:19:20 UTC
Seems like this was fixed by FEDORA-2015-0529 update NetworkManager-0.9.10.1-1.2.20150109git.fc21 [1]. I intended to wait for an upstream release, but seems like Jirka was faster.


[1] https://admin.fedoraproject.org/updates/FEDORA-2015-0529/NetworkManager-0.9.10.1-1.2.20150109git.fc21

Comment 12 Dan Mossor [danofsatx] 2015-02-16 22:47:20 UTC
Created attachment 992383 [details]
Journal output showing failure

Comment 13 Dan Mossor [danofsatx] 2015-02-16 22:47:53 UTC
This problem has reappeared in NetworkManager-0.9.10.1-1.4.20150115git.fc21.x86_64
 - With NetworkManager enabled, the devices managed by teamd are deactivated. I have attached my journal output showing the attempt to start the device with 'nmcli con up team0' which results in an immediate deactivation, the turning off of NetworkManager, and the activation of the interface with 'teamd -g -f /etc/teamd.d/team0.conf -d'

Comment 14 Dan Mossor [danofsatx] 2015-02-16 23:51:04 UTC
Reopening for continued regression. If a new bug needs to be submitted, I will do so.

Comment 15 Lubomir Rintel 2015-02-23 09:14:34 UTC
(In reply to Dan Mossor from comment #14)
> Reopening for continued regression. If a new bug needs to be submitted, I
> will do so.

Please submit a separate bug -- this seems to be a different issue. Your team daemon has been terminated because a connection was activated on it:

Feb 17 22:40:06 hp3.example.net NetworkManager[880]: <info>  (team0): disconnecting for new activation request.

Unfortunately the log is incomplete so I can't find out what caused it to be activated -- whether it was an user request or autoactivation. In case you'll open another bug, please attach a more complete log, preferrably from the NetworkManager startup.

The NetworkManager 1.0 which will be included in Fedora 22 will handle the externally created devices a bit more robustly. Maybe the issue you're experiencing can be avoided with a configuration change though.

Thank you.


Note You need to log in before you can comment on or make changes to this bug.