loads duplicated symbols from NMSettings

Bug #1499904 reported by Mathieu Trudel-Lapierre
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
network-manager (Ubuntu)
Fix Released
Critical
Mathieu Trudel-Lapierre

Bug Description

When starting NM with the ofono settings plugin enabled:

Sep 25 17:06:03 demeter NetworkManager[28346]: <info> Loaded settings plugin ifupdown: (C) 2008 Canonical Ltd. To report bugs please use the NetworkManager mailing list. (/usr/lib/x86_64-linux-gnu/NetworkManager/libnm-settings-plugin-ifupdown.so)
Sep 25 17:06:03 demeter NetworkManager[28346]: <info> Loaded settings plugin keyfile: (c) 2007 - 2015 Red Hat, Inc. To report bugs please use the NetworkManager mailing list.
Sep 25 17:06:03 demeter NetworkManager[28346]: (NetworkManager:28346): GLib-GObject-WARNING **: cannot register existing type 'NMSetting'
Sep 25 17:06:03 demeter NetworkManager[28346]: (NetworkManager:28346): GLib-CRITICAL **: g_once_init_leave: assertion 'result != 0' failed
Sep 25 17:06:03 demeter NetworkManager[28346]: (NetworkManager:28346): GLib-GObject-CRITICAL **: g_type_register_static: assertion 'parent_type > 0' failed
Sep 25 17:06:03 demeter NetworkManager[28346]: (NetworkManager:28346): libnm-util-CRITICAL **: _nm_register_setting: assertion 'type != G_TYPE_INVALID' failed
Sep 25 17:06:03 demeter NetworkManager[28346]: (NetworkManager:28346): GLib-CRITICAL **: g_once_init_leave: assertion 'result != 0' failed

These errors come from the ofono plugin itself; it then freezes when requests are sent, which is expected since it cannot complete initialization.

Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

[New Thread 0xb32ff340 (LWP 26481)]

(NetworkManager:26470): GLib-GObject-WARNING **: cannot register existing type 'NMSetting'

(NetworkManager:26470): GLib-CRITICAL **: g_once_init_leave: assertion 'result != 0' failed

(NetworkManager:26470): GLib-GObject-CRITICAL **: g_type_register_static: assertion 'parent_type > 0' failed

(NetworkManager:26470): libnm-util-CRITICAL **: _nm_register_setting: assertion 'type != G_TYPE_INVALID' failed

(NetworkManager:26470): GLib-CRITICAL **: g_once_init_leave: assertion 'result != 0' failed
^C
Program received signal SIGINT, Interrupt.
0xb6940620 in syscall () from /lib/arm-linux-gnueabihf/libc.so.6
(gdb) bt full
#0 0xffffffff in syscall () at /lib/arm-linux-gnueabihf/libc.so.6
#1 0xffffffff in g_cond_wait (cond=cond@entry=0xb6a86c84 <g_once_cond>, mutex=mutex@entry=0xb6a86c7c <g_once_mutex>)
    at /build/glib2.0-hi_vf7/glib2.0-2.45.8/./glib/gthread-posix.c:1397
        sampled = 207
#2 0xffffffff in g_once_init_enter (location=location@entry=0xb2ae985c <g_define_type_id.volatile>)
    at /build/glib2.0-hi_vf7/glib2.0-2.45.8/./glib/gthread.c:663
        value_location = 0xb2ae985c <g_define_type_id.volatile>
        need_init = 0
#3 0xffffffff in nm_setting_get_type () at nm-setting.c:64
        g_define_type_id__volatile = 0
#4 0xffffffff in nm_setting_adsl_get_type () at nm-setting-adsl.c:58
        g_define_type_id = <optimized out>
        g_define_type_id__volatile = 0
#5 0xffffffff in register_setting () at nm-setting-adsl.c:63
#6 0xffffffff in () at /lib/ld-linux-armhf.so.3
#7 0x00000000 in ()

Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

Looks like this is because the plugin was linking against libnm-util. In the new scheme of things, it's not necessary and we should link against libnm-core anyway (which is already done); doing so now causes NMSettings initialization to attempt to happen twice.

Changed in network-manager (Ubuntu):
status: New → In Progress
importance: Undecided → Critical
assignee: nobody → Mathieu Trudel-Lapierre (mathieu-tl)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package network-manager - 1.0.4-0ubuntu4

---------------
network-manager (1.0.4-0ubuntu4) wily; urgency=medium

  [ Mathieu Trudel-Lapierre ]
  * d/p/0001-wwan-add-support-for-using-oFono-as-a-modem-manager.patch:
    Pre-initialize reason for ofono state changes to NULL; this avoids getting
    to nm_device_set_state with an invalid reason string. (LP: #1499906)
  * d/p/0001-wwan-add-support-for-using-oFono-as-a-modem-manager.patch:
    cleanup ip_string_to_network_address() to work as its NMModemBroadband
    version, and start setting NM_MODEM_IP4_METHOD to _STATIC so IP, prefix,
    gateway and DNS get properly applied on an oFono modem as it comes up.
  * debian/NetworkManager.conf: re-enable the ofono plugin (fixes a regression).
  * debian/patches/add_ofono_settings_support.patch: don't link against
    libnm-glib as this would cause type duplication and crashes. (LP: #1499904)
  * debian/patches/lp1496434_warn_on_invalid_new_link.patch: don't outright
    crash by dereferencing a NULL pointer if a device can't get created by its
    NMDeviceFactory; we should warn though, as we want to know about these
    failures; but no need to make all of NM sad. (LP: #1496434)

  [ Tony Espy ]
  * d/p/0002-wifi-cull-the-scan-list-before-signalling-ScanDone-b.patch:
    Fix duplicate 'LastSeen' PropertiesChanged signals being generated
    after every scan. The 'Last-Seen' property is now only updated when
    a scan finishes, and schedule_scanlist_cull is no longer triggered
    new_bss_cb or updated_bss_cb. (LP: #1480877)
  * d/p/add_ofono_settings_support.patch: Fix memory leaks in plugin.
  * d/p/add_ofono_settings_support.patch: Remove unused plugin DBus code.
  * d/p/CVE-2015-1322.patch: Drop CVE which applied to removed DBus code
    in ofono settings plugin.

 -- Mathieu Trudel-Lapierre <email address hidden> Sat, 26 Sep 2015 00:02:02 -0400

Changed in network-manager (Ubuntu):
status: In Progress → Fix Released
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.