GNOME Bugzilla – Bug 696004
NetworkManager reports an active connection that doesn't exist
Last modified: 2013-09-23 15:29:04 UTC
It happened to me that after clicking on the off switch for wireless in the UI, the icon got stuck to connected, and gnome-shell started complaining about an active connection with no access point. After some debugging, I tracked this down to NetworkManager, as you can see from the following data: node /org/freedesktop/NetworkManager/ActiveConnection { node /org/freedesktop/NetworkManager/ActiveConnection/0 { interface org.freedesktop.NetworkManager.Connection.Active { properties: readonly o Master = '/'; readonly b Vpn = false; readonly b Default6 = false; readonly b Default = false; readonly u State = 0; readonly ao Devices = ['/org/freedesktop/NetworkManager/Devices/1']; readonly s Uuid = 'ec117e08-6e79-4588-8713-5e0231a235a0'; readonly o SpecificObject = '/org/freedesktop/NetworkManager/AccessPoint/0'; readonly o Connection = '/org/freedesktop/NetworkManager/Settings/2'; }; }; }; node /org/freedesktop/NetworkManager/Devices { node /org/freedesktop/NetworkManager/Devices/0 { interface org.freedesktop.NetworkManager.Device { properties: readonly ao AvailableConnections = []; readonly u DeviceType = 1; readonly b FirmwareMissing = false; readwrite b Autoconnect = true; readonly b Managed = true; readonly o Dhcp6Config = '/'; readonly o Ip6Config = '/'; readonly o Dhcp4Config = '/'; readonly o Ip4Config = '/'; readonly o ActiveConnection = '/'; readonly (uu) StateReason = (20, 2); readonly u State = 20; readonly u Ip4Address = 0; readonly u Capabilities = 3; readonly s FirmwareVersion = '1.7-7'; readonly s DriverVersion = '2.1.4-k'; readonly s Driver = 'e1000e'; readonly s IpInterface = ''; readonly s Interface = 'em1'; readonly s Udi = '/sys/devices/pci0000:00/0000:00:19.0/net/em1'; }; interface org.freedesktop.NetworkManager.Device.Wired { properties: readonly b Carrier = false; readonly u Speed = 0; readonly s PermHwAddress = '00:26:B9:99:47:E6'; readonly s HwAddress = '00:26:B9:99:47:E6'; }; }; node /org/freedesktop/NetworkManager/Devices/1 { interface org.freedesktop.NetworkManager.Device { properties: readonly ao AvailableConnections = []; readonly u DeviceType = 2; readonly b FirmwareMissing = false; readwrite b Autoconnect = true; readonly b Managed = true; readonly o Dhcp6Config = '/'; readonly o Ip6Config = '/'; readonly o Dhcp4Config = '/'; readonly o Ip4Config = '/'; readonly o ActiveConnection = '/'; readonly (uu) StateReason = (20, 0); readonly u State = 20; readonly u Ip4Address = 1677830336; readonly u Capabilities = 1; readonly s FirmwareVersion = '8.83.5.1 build 33692'; readonly s DriverVersion = '3.8.2-206.fc18.x86_64'; readonly s Driver = 'iwlwifi'; readonly s IpInterface = ''; readonly s Interface = 'wlan0'; readonly s Udi = '/sys/devices/pci0000:00/0000:00:1c.1/0000:0c:00.0/net/wlan0'; }; interface org.freedesktop.NetworkManager.Device.Wireless { properties: readonly u WirelessCapabilities = 191; readonly o ActiveAccessPoint = '/'; readonly u Bitrate = 0; readonly u Mode = 2; readonly s PermHwAddress = '00:21:6A:9D:18:CE'; readonly s HwAddress = '00:21:6A:9D:18:CE'; }; }; }; As you see, the ActiveConnection hierarchy believes that the system is connected, and provides me with an access point, while the Devices hierarchy disagrees. For the record, the system was not connected when I collected this, and ifconfig told me there was no wlan0 at all (probably caused by rfkill masking) This is on NetworkManager-0.9.8.0-1.fc18.x86_64. (Note: I believe this is a possible explanation for bug 676285)
That's the raw dbus info, right? ie, not coming from libnm-glib? Clearly a bug in NM, could be caused by a refcounting problem. If you get into this situation again, can you check the org.freedesktop.NetworkManager.ActiveConnections property of /org/freedesktop/NetworkManager to see if the AC is listed there, or if that property is empty?
Yes, that was a raw dump of gdbus introspect. I'll check if I bump into this issue again.
I have a similar problem here, see this comment: https://bugzilla.gnome.org/show_bug.cgi?id=676285#c12 Even with the cable unplugged and WiFi hardware killswitch off, I get this: $ gdbus introspect --system --dest org.freedesktop.NetworkManager --object-path /org/freedesktop/NetworkManager --recurse --only-properties interface org.freedesktop.NetworkManager { properties: readonly u State = 20; readonly s Version = '0.9.8.0'; readonly ao ActiveConnections = ['/org/freedesktop/NetworkManager/ActiveConnection/42', '/org/freedesktop/NetworkManager/ActiveConnection/41']; readonly b WimaxHardwareEnabled = true; readwrite b WimaxEnabled = true; readonly b WwanHardwareEnabled = true; readwrite b WwanEnabled = true; readonly b WirelessHardwareEnabled = false; readwrite b WirelessEnabled = false; readonly b NetworkingEnabled = true; }; [...] $ gdbus introspect --system --dest org.freedesktop.NetworkManager --object-path /org/freedesktop/NetworkManager/ActiveConnection --recurse --only-properties node /org/freedesktop/NetworkManager/ActiveConnection { node /org/freedesktop/NetworkManager/ActiveConnection/41 { interface org.freedesktop.NetworkManager.Connection.Active { properties: readonly o Master = '/'; readonly b Vpn = false; readonly b Default6 = false; readonly b Default = false; readonly u State = 0; readonly ao Devices = ['/org/freedesktop/NetworkManager/Devices/1']; readonly s Uuid = 'b92f3302-ee0f-4a7a-a9db-2e8bcbfe505e'; readonly o SpecificObject = '/org/freedesktop/NetworkManager/AccessPoint/2347'; readonly o Connection = '/org/freedesktop/NetworkManager/Settings/21'; }; }; node /org/freedesktop/NetworkManager/ActiveConnection/42 { interface org.freedesktop.NetworkManager.Connection.Active { properties: readonly o Master = '/'; readonly b Vpn = false; readonly b Default6 = false; readonly b Default = false; readonly u State = 0; readonly ao Devices = ['/org/freedesktop/NetworkManager/Devices/0']; readonly s Uuid = '1a3485c7-3d34-470e-a508-0d156e46e3c6'; readonly o SpecificObject = '/'; readonly o Connection = '/org/freedesktop/NetworkManager/Settings/8'; }; }; }; $ gdbus introspect --system --dest org.freedesktop.NetworkManager --object-path /org/freedesktop/NetworkManager/Devices --recurse --only-properties node /org/freedesktop/NetworkManager/Devices { node /org/freedesktop/NetworkManager/Devices/0 { interface org.freedesktop.NetworkManager.Device { properties: readonly ao AvailableConnections = []; readonly u DeviceType = 1; readonly b FirmwareMissing = false; readwrite b Autoconnect = true; readonly b Managed = true; readonly o Dhcp6Config = '/'; readonly o Ip6Config = '/'; readonly o Dhcp4Config = '/'; readonly o Ip4Config = '/'; readonly o ActiveConnection = '/'; readonly (uu) StateReason = (20, 40); readonly u State = 20; readonly u Ip4Address = 184592576; readonly u Capabilities = 3; readonly s FirmwareVersion = ''; readonly s DriverVersion = '2.3LK-NAPI'; readonly s Driver = 'r8169'; readonly s IpInterface = ''; readonly s Interface = 'em1'; readonly s Udi = '/sys/devices/pci0000:00/0000:00:1c.0/0000:01:00.0/net/em1'; }; interface org.freedesktop.NetworkManager.Device.Wired { properties: readonly b Carrier = false; readonly u Speed = 100; readonly s PermHwAddress = 'YYYY'; readonly s HwAddress = 'YYYY'; }; }; node /org/freedesktop/NetworkManager/Devices/1 { interface org.freedesktop.NetworkManager.Device { properties: readonly ao AvailableConnections = []; readonly u DeviceType = 2; readonly b FirmwareMissing = false; readwrite b Autoconnect = true; readonly b Managed = true; readonly o Dhcp6Config = '/'; readonly o Ip6Config = '/'; readonly o Dhcp4Config = '/'; readonly o Ip4Config = '/'; readonly o ActiveConnection = '/'; readonly (uu) StateReason = (20, 0); readonly u State = 20; readonly u Ip4Address = 201369792; readonly u Capabilities = 1; readonly s FirmwareVersion = 'N/A'; readonly s DriverVersion = '3.6.2-2.fc18.x86_64'; readonly s Driver = 'brcmsmac'; readonly s IpInterface = ''; readonly s Interface = 'wlan0'; readonly s Udi = '/sys/devices/pci0000:00/0000:00:1c.1/0000:02:00.0/bcma0:0/net/wlan0'; }; interface org.freedesktop.NetworkManager.Device.Wireless { properties: readonly u WirelessCapabilities = 63; readonly o ActiveAccessPoint = '/'; readonly u Bitrate = 0; readonly u Mode = 2; readonly s PermHwAddress = 'XXXX'; readonly s HwAddress = 'XXXX'; }; }; };
Pretty sure this got fixed in 0.9.8 and later with d709903d88864b96d6a94425cba8cfb6c9efaccf and thus this is a dupe of bug 676285. *** This bug has been marked as a duplicate of bug 676285 ***