Ubuntu

[MASTER] networkmanager display connections twice in intrepid

Reported by Nizar Kerkeni on 2008-08-30
210
This bug affects 17 people
Affects Status Importance Assigned to Milestone
hal (Ubuntu)
Medium
Unassigned
network-manager (Ubuntu)
Medium
Alexander Sack

Bug Description

Binary package hint: network-manager

1) ubuntu intrepid alpha 4 on amd64
after "close session" and login all connections are detected twice by network manager, nm-applet displays them twice too.

nizarus@vaio:~$ nm-tool

NetworkManager Tool

State: connected

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: e100
  State: unavailable
  Default: no
  HW Address: XXXXXXXXXX

  Capabilities:
    Supported: yes
    Carrier Detect: yes
    Speed: 10 Mb/s

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: iwl3945
  State: connected
  Default: yes
  HW Address: YYYYYYYY

  Capabilities:
    Supported: yes
    Speed: 54 Mb/s

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points(* = Current AP)
    *toto: Infra, YYYYYYYY, Freq 2427 MHz, Rate 54 Mb/s, Strength 99 WPA

  IPv4 Settings:
    Address: 192.168.0.13
    Prefix: 24 (255.255.255.0)
    Gateway: 192.168.0.1

    DNS: 192.168.1.254
    DNS: 192.168.0.1

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: e100
  State: unavailable
  Default: no
  HW Address: XXXXXXXX

  Capabilities:
    Supported: yes
    Carrier Detect: yes
    Speed: 10 Mb/s

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: iwl3945
  State: connected
  Default: no
  HW Address: YYYYYYYYYY

  Capabilities:
    Supported: yes
    Speed: 54 Mb/s

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points(* = Current AP)
    *toto: Infra, YYYYYYYYYY, Freq 2427 MHz, Rate 54 Mb/s, Strength 99 WPA

  IPv4 Settings:
    Address: 192.168.0.13
    Prefix: 24 (255.255.255.0)
    Gateway: 192.168.0.1

    DNS: 192.168.1.254
    DNS: 192.168.0.1

i've seen that too, but now i cant reproduce it anymore.

are you still affected by this problem?

please post your network-manager version.

Thanks

Nizar Kerkeni (nizarus) wrote :

i can't reproduce it in a case of normal use !!
i think, but not totally sure, that this happens when the linux kernel is updated !!
Actually i have network-manager version 0.7~~svn20080818t061112+eni0-0ubuntu1

I'm marking this invalid, as it appears to have been fix, and is not now reproducible.
If you encounter it again, please open this ticket again, and mark it as NEW.

Changed in network-manager:
status: New → Invalid
Mackenzie Morgan (maco.m) wrote :

Logging out and back in again or rebooting should fix this for anyone experiencing it. It's a side-effect of NetworkManager 0.7's first run.

Mario Limonciello (superm1) wrote :

Why is this bug marked invalid? This bug and it's duplicates are all a valid problem, and I've still encountered it.

Changed in network-manager:
status: Invalid → New
Alexander Sack (asac) wrote :

how can i reproduce this? i know it happens at some upgrades when things like hal get restarted, but i couldnt repro manually yet. any info appreciated.

Alexander Sack (asac) wrote :

visual glitch with low impact, but high confusion potential :)

Changed in network-manager:
importance: Undecided → Medium
status: New → Confirmed

Generally i've gotten it after resuming from suspend. I'll try to get a
reliable case to reproduce it.

On Sun, Nov 2, 2008 at 19:29, Alexander Sack <email address hidden> wrote:

> visual glitch with low impact, but high confusion potential :)
>
> ** Changed in: network-manager (Ubuntu)
> Importance: Undecided => Medium
> Status: New => Confirmed
>
> --
> [MASTER] networkmanager display connections twice in intrepid
> https://bugs.launchpad.net/bugs/262974
> You received this bug notification because you are a direct subscriber
> of a duplicate bug.
>

--
Mario Limonciello
<email address hidden>

On Mon, 2008-11-03 at 01:28 +0000, Alexander Sack wrote:
> how can i reproduce this? i know it happens at some upgrades when things
> like hal get restarted, but i couldnt repro manually yet. any info
> appreciated.

I believe that's the only way to reproduce it. When the update happens,
it has to rediscover what the hardware is. After a reboot or logging
out and back in again, it will know.

yes, suspend usually caused that for me... but now my suspend is broken again, so I cant test it

Martin G Miller (mgmiller) wrote :

This was first reported iln bug#279262, but really belongs here.

After an upgrade from Hardy to Intrepid and after removing many blank lines and extra cruft from /etc/network/interfaces, which finally got nm-applet working, I have a problem with what network manager displays. After several reboots, I have the network manager applet in the tray and it works, sort of. It shows my DHCP entry and my static IP entry twice.

It also kept defaulting to the Auto eth0 connection which is DHCP, even though I had unchecked "connect automatically" for that entry. I could switch between Auto eth0 and static IP connection 1 by clicking, but I had to select the same item in both spots, since it was listed twice in the left click drop down.

Since I never really use the DHCP, I deleted it from the "Edit Connections" choice off a right click. The "Edit Connections" interface now lists only 1 static IP conneciton, it shows the mac address as blank. and selecting the "system setting" check box does not remain selected. (I don't know what that choice is for, there is no pop up help for it).

If I right click the nm-applet icon and select "Connection Information", it shows 2 tabs. Left tab says Static IP Connection 1 (default) and right tab says Static IP Connection 1. They both show the same hardware address and IP address, etc. They are identical entries.

Left clicking the network applet show all the information twice. Clicking on either of the presented entries results in a pop up saying I am connected to that entry. There should not be 2 of them. Here is what it looks like:

Wired Network (ASUSTeK computer MCP785 [GeForce 8200] Ethernet)
 Static IP Connection 1
Wired Network (ASUSTeK computer MCP785 [GeForce 8200] Ethernet)
 Static IP Connection 1
-----------------------------------------------------
VPN Connections

Clicking on either of the lines that says Static IP Connection 1 results in the expected pop up of "you are now connected to,,,etc.)

To summarize, the issues now are:
1) Why does it default to auto eth0 DHCP if there is an entry for it but the "Connect Automatically" check box is deselected?

2) Why are all the entries listed twice on a left click of the nm-applet icon in the top tray?

This does not affect connectivity directly as long as I don't have a DHCP connection defined, but it does make for a confusing display.

Alexander Sack (asac) wrote :

my guess is that this is a hal bug. When you have this reproducible, could you please look at lshal output and search for eth0 (or whatever device is listed twice nm-applet), and see if that is associated with two udi's?

Alexander Sack (asac) wrote :

also if your wired is duplicated see if:

hal-find-by-capability --capability net.80203

gives too many entries.

If your wifi is duplicated, you can use:

hal-find-by-capability --capability net.80211

Alexander Sack (asac) wrote :

once we have verified that hal duplicates those entries, we need a reliably way to reproduce.

When mine are duplicated, both ethernet and wifi get duplicated in hal:

supermario@mlimonciello:~$ hal-find-by-capability --capability net.80203
/org/freedesktop/Hal/devices/net_00_1c_23_17_13_9c_0
/org/freedesktop/Hal/devices/net_00_1c_23_17_13_9c

supermario@mlimonciello:~$ hal-find-by-capability --capability net.80211
/org/freedesktop/Hal/devices/net_00_1c_bf_44_4f_ed_1
/org/freedesktop/Hal/devices/net_00_1c_bf_44_4f_ed

Restarting HAL solves the problem:

$ sudo /etc/init.d/hal restart
[sudo] password for supermario:
 * Restarting Hardware abstraction layer hald [
OK ]

supermario@mlimonciello:~$ hal-find-by-capability --capability net.80211
/org/freedesktop/Hal/devices/net_00_1c_bf_44_4f_ed

supermario@mlimonciello:~$ hal-find-by-capability --capability net.80203
/org/freedesktop/Hal/devices/net_00_1c_23_17_13_9c

On Mon, Nov 3, 2008 at 11:26, Alexander Sack <email address hidden> wrote:

> once we have verified that hal duplicates those entries, we need a
> reliably way to reproduce.
>
> --
> [MASTER] networkmanager display connections twice in intrepid
> https://bugs.launchpad.net/bugs/262974
> You received this bug notification because you are a direct subscriber
> of a duplicate bug.
>

--
Mario Limonciello
<email address hidden>

Martin G Miller (mgmiller) wrote :

I did an /etc/init.d/hal restart before I read the above.

After doing that, the duplication in the list went away. So did nm-applet and my network. On reboot, nm-applet came up and showed my 1 static IP and the auto eth0 DHCP connection I had deleted earlier. The auto eth0 DHCP was checked as "Connect Automatically".

Here is what I did:
I unchecked "Connect Automatically" for the auto eth0 connection

I checked "Connect Automatically" for the Static IP Connection 1.

Rebooted.

The auto eth0 was back up as the default connection.
Clicking on "Static IP Connection 1" in the list causes the system to correctly switch to that and display an appropriate pop up.

Here is the output of hal-find-by-capability --capability net.80203

marty@tux:~$ hal-find-by-capability --capability net.80203
/org/freedesktop/Hal/devices/net_00_22_15_a1_23_df

Only 1 entry.
Restarting hal seems to have fixed the double entry problem.

The only remaining issue now is...
On startup, why does it default to auto eth0 DHCP & reselect the "Connect Automatically" check box after it has been deselected and another connection is listed as "Connect Automatically?

Do I need to start another bug report for this?

Alexander Sack (asac) wrote :

I think its a hal bug or below when devices just duplicate in hal.

Changed in hal:
importance: Undecided → Medium
status: New → Triaged
Download full text (5.6 KiB)

I haven't closed the session, or resumed the system. I can see the wireless connections available listed twice (see attachment). Restarting hal does not fix the problem (see bellow).

gringo@lethe:~$ uptime
 12:26:29 up 1 day, 18:49, 7 users, load average: 0.33, 0.55, 0.53

gringo@lethe:~$ nm-tool

NetworkManager Tool

State: connected

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: tg3
  State: unmanaged
  Default: no
  HW Address: 00:00:00:00:00:00

  Capabilities:
    Supported: yes
    Carrier Detect: yes
    Speed: 100 Mb/s

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: iwl3945
  State: disconnected
  Default: no
  HW Address: 00:19:D2:3D:59:8B

  Capabilities:
    Supported: yes

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points
    ltknet: Infra, 00:1E:8C:2E:6A:26, Freq 2437 MHz, Rate 54 Mb/s, Strength 46 WPA2
    bici: Infra, 00:1F:C6:61:92:8F, Freq 2432 MHz, Rate 54 Mb/s, Strength 54 WPA2
    AlexR: Infra, 00:18:F8:4A:D2:BB, Freq 2462 MHz, Rate 54 Mb/s, Strength 45
    diana: Ad-Hoc, 02:1C:BF:01:DF:83, Freq 2462 MHz, Rate 54 Mb/s, Strength 43 WPA2
    Spike: Infra, 00:1E:E5:5B:AD:99, Freq 2422 MHz, Rate 54 Mb/s, Strength 38 WPA
    Wireless Network:Ad-Hoc, 76:C2:50:21:8D:EF, Freq 2462 MHz, Rate 11 Mb/s, Strength 35
    mariusssss: Infra, 00:21:91:71:1C:C6, Freq 2437 MHz, Rate 54 Mb/s, Strength 38 WPA
    Free Public WiFi:Ad-Hoc, 7A:9E:5C:19:A2:E7, Freq 2462 MHz, Rate 11 Mb/s, Strength 35

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: iwl3945
  State: disconnected
  Default: no
  HW Address: 00:19:D2:3D:59:8B

  Capabilities:
    Supported: yes

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points
    ltknet: Infra, 00:1E:8C:2E:6A:26, Freq 2437 MHz, Rate 54 Mb/s, Strength 46 WPA2
    bici: Infra, 00:1F:C6:61:92:8F, Freq 2432 MHz, Rate 54 Mb/s, Strength 54 WPA2
    AlexR: Infra, 00:18:F8:4A:D2:BB, Freq 2462 MHz, Rate 54 Mb/s, Strength 45
    diana: Ad-Hoc, 02:1C:BF:01:DF:83, Freq 2462 MHz, Rate 54 Mb/s, Strength 43 WPA2
    Spike: Infra, 00:1E:E5:5B:AD:99, Freq 2422 MHz, Rate 54 Mb/s, Strength 38 WPA
    Wireless Network:Ad-Hoc, 76:C2:50:21:8D:EF, Freq 2462 MHz, Rate 11 Mb/s, Strength 35
    mariusssss: Infra, 00:21:91:71:1C:C6, Freq 2437 MHz, Rate 54 Mb/s, Strength 38 WPA
    Free Public WiFi:Ad-Hoc, 7A:9E:5C:19:A2:E7, Freq 2462 MHz, Rate 11 Mb/s, Strength 35

gringo@lethe:~$ hal-find-by-capability --capability net.80203
/org/freedesktop/Hal/devices/net_00_19_b9_51_3d_64
gringo@lethe:~$ hal-find-by-capability --capability net.80211
/org/freedesktop/Hal/devices/net_00_19_d2_3d_59_8b

gringo@lethe:~...

Read more...

Alexander Sack (asac) wrote :

Lucian, thats interesteing and probably indicates a resume bug or something in NM ... but the root cause is surely that hal exposes the devices twice.

Daswebmastri (daswebmastri) wrote :

I know how to duplicate it. It happens only when I use Synaptic to add or remove a program, particularly VirtualBox OSE. I read that you can black list something, but it caused Ubuntu to not even detect wireless networks. Got that fixed, but...

Mario Limonciello (superm1) wrote :

I've got a common case that will always trigger it:

Run this:

sudo /sbin/udevadm trigger

This step is always ran by DKMS which is used for NVIDIA or Virtual Box OSE (hence why Daswebmastri reproduces it with vbox ose). I've not determined if this gets called somehow on some resumes or similar.

I confirm that:
* the bug appeared after a kernel update and nvidia driver installation
* restarting hal removed the duplicate
* udevadm trigger created the duplicate again.

Note also that I had both the wired and wireless card duplicated, but that each operation to remove or recreate the duplicate only workd on 1 duplicate at a time.

I.e. I needed to restart hal twice to remove both duplicates, and I needed to trigger udevadm twice to re-create both of them.

My mistake!!

Triggering udevadm creates both duplicate at one time.

Furthermore, restarting hal once is sufficient, but I need to restart NetworkManager as well.

Sven Hoffmeister (schaumkeks) wrote :

I can reproduce this even with an official Intrepid Live CD simply by restarting udev:
sudo /etc/init.d/udev restart

Restarting hal afterwards doesn't fix this for me.

kindofabuzz (kindofabuzz) wrote :
Download full text (3.3 KiB)

Mines is listed 3 times.

NetworkManager Tool

State: connected

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: tulip
  State: unavailable
  Default: no
  HW Address: 00:04:5A:8F:6C:E1

  Capabilities:
    Supported: yes
    Carrier Detect: yes

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: b43
  State: connected
  Default: yes
  HW Address: 00:1A:70:2E:18:2B

  Capabilities:
    Supported: yes
    Speed: 24 Mb/s

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points(* = Current AP)
    *dd-wrt: Infra, 00:1C:10:45:8D:94, Freq 2462 MHz, Rate 54 Mb/s, Strength 41 WPA2
    Wookie Web: Infra, 00:1F:33:CA:FA:3E, Freq 2437 MHz, Rate 54 Mb/s, Strength 33 WPA WPA2

  IPv4 Settings:
    Address: 192.168.1.103
    Prefix: 24 (255.255.255.0)
    Gateway: 192.168.1.1

    DNS: 192.168.1.1

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: tulip
  State: unavailable
  Default: no
  HW Address: 00:04:5A:8F:6C:E1

  Capabilities:
    Supported: yes
    Carrier Detect: yes

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: b43
  State: connected
  Default: no
  HW Address: 00:1A:70:2E:18:2B

  Capabilities:
    Supported: yes
    Speed: 24 Mb/s

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points(* = Current AP)
    *dd-wrt: Infra, 00:1C:10:45:8D:94, Freq 2462 MHz, Rate 54 Mb/s, Strength 41 WPA2
    Wookie Web: Infra, 00:1F:33:CA:FA:3E, Freq 2437 MHz, Rate 54 Mb/s, Strength 33 WPA WPA2

  IPv4 Settings:
    Address: 192.168.1.103
    Prefix: 24 (255.255.255.0)
    Gateway: 192.168.1.1

    DNS: 192.168.1.1

- Device: eth0 ----------------------------------------------------------------
  Type: Wired
  Driver: tulip
  State: unavailable
  Default: no
  HW Address: 00:04:5A:8F:6C:E1

  Capabilities:
    Supported: yes
    Carrier Detect: yes

  Wired Settings

- Device: wlan0 ----------------------------------------------------------------
  Type: 802.11 WiFi
  Driver: b43
  State: connected
  Default: no
  HW Address: 00:1A:70:2E:18:2B

  Capabilities:
    Supported: yes
    Speed: 24 Mb/s

  Wireless Settings
    WEP Encryption: yes
    WPA Encryption: yes
    WPA2 Encryption: yes

  Wireless Access Points(* = Current AP)
    *dd-wrt: Infra, 00:1C:10:45:8D:94, Freq 2462 MHz, Rate 54 Mb/s, Strength 41 WPA2
    Wookie Web: Infra, 00:1F:33:CA:FA:3E, Freq 2437 MH...

Read more...

Jamie Strandboge (jdstrand) wrote :

I see this on Jaunty as well. Happened after restarting udev. This also brought down my wireless connection. Network Manager then tried to connect twice, auto-connecting the first time, and presenting the WPA dialog the second time.

Nizar Kerkeni (nizarus) wrote :

I always get this issue after compiling virtualbox module in intrepid 64bits

Michael (michaeljt) wrote :

See also https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/298198.
@Nizar Kerkeni: me too (re the VirtualBox module on Intrepid 64bits).

Michael (michaeljt) wrote :

See also https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/308928, which is the crash I had after restarting hal to get rid of duplicate entries.

Michael (michaeljt) wrote :

Those of you who are seeing this in connection with VirtualBox, are you using a recent svn version? In my case this is related to the new net filter driver.

Michael (michaeljt) wrote :

Shoot me for not reading all the comments above. The udevadm trigger is what is causing it in my case too. This bug should probably be reassigned to dkms, as it should definitely not be calling that.

Mario Limonciello (superm1) wrote :

udevadm trigger is called so that the events can all intentionally be
replayed in case a piece of hardware is now supported by that module. How
else would you achieve this behavior?

On Wed, Dec 17, 2008 at 15:40, Michael <email address hidden> wrote:

> Shoot me for not reading all the comments above. The udevadm trigger is
> what is causing it in my case too. This bug should probably be
> reassigned to dkms, as it should definitely not be calling that.
>
> --
> [MASTER] networkmanager display connections twice in intrepid
> https://bugs.launchpad.net/bugs/262974
> You received this bug notification because you are a direct subscriber
> of a duplicate bug.
>

--
Mario Limonciello
<email address hidden>

Michael (michaeljt) wrote :

It still sounds a bit radical. Basically dkms is causing an additional add event to be sent for every device in the system. What are the benefits for the user? The disadvantages seem to be clear, as hal's device database is messed up, along with anything that depends on it (in this case, the network manager applet). And this for a situation in which nothing was even added to the system. Perhaps just restarting hal would be good enough? Then its database would be up-to-date. I don't think that hotplug events are absolutely necessary in this case. Alternatively (and more difficult) one could try to work out which devices had changed in sysfs and only trigger event replay for those (although one should probably find some way to get "remove" events for them before the "add" ones get sent).

By the way, I did some quick (random) checking, and udevtrigger also messes up the hal database in Ubuntu 8.04, and in Fedora 8. In Fedora 8 it also messes up networking. I really don't think that this command is intended to be used once the system is up and running.

Dmitry Korzhevin (korg) wrote :

I confirm this bug.

Ubuntu 8.10

Kernel: Linux korg-desktop 2.6.27-11-generic #1 SMP Thu Jan 8 08:38:33 UTC 2009 i686 GNU/Linux

Virtualbox 2.1.0-41146_Ubuntu_intrepid

NetworkManager 0.7~~svn20081018t105859-0ubuntu1.8.10.1 0

Steps to reproduce:

1. Install VirtualBox 2.1.0 i386 in Ubuntu 8.10
(http://download.virtualbox.org/virtualbox/2.1.0/virtualbox-2.1_2.1.0-41146_Ubuntu_intrepid_i386.deb)

2. Create new kernel module '/etc/init.d/vboxdrv setup'
3. After compilation of kernel virtualbox module you have more duplicated connections :)

Dayu (dayuhuangster) wrote :

I confirm this bug. I restarted hal. It does not fix this. This happens after I installed the pptp daemon for my network manager. I am not using Virtualbox.

Alexander Sack (asac) on 2009-01-20
Changed in network-manager:
assignee: nobody → asac
Michael (michaeljt) wrote :

See also http://www.virtualbox.org/ticket/3111. Are the side effects really worth the minor convenience factor?

ear9mrn (pete-nevill) wrote :

Can confirm this bug 2.6.27-11-generic. Every time I reboot I have an additional wired connection added "auth eth0". I have to manually delete it and switch to my saved static version. This is a serious pain, as it means I cannot remotely reboot my machine.....

Pete.

Michael (michaeljt) wrote :

Today's (yesterday's?) update to dkms should fix this, at least for me. Thanks Mario.

Alexander Sack (asac) wrote :

not networkmanager fault to display two entries when hal shows two entries. might be that NM could do better by cleaning its cache properly when hal gets restarted, but thats not the issue this bug is about.

Changed in network-manager (Ubuntu):
status: Confirmed → Invalid
Michael (michaeljt) wrote :

The bug is fixed now anyway, so it's no longer really relevant.

Changed in hal (Ubuntu):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

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