Bug 1546805 - deleting value of tc.qdisc prevents connection upping
Summary: deleting value of tc.qdisc prevents connection upping
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: NetworkManager
Version: 7.5
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: rc
: ---
Assignee: Beniamino Galvani
QA Contact: Desktop QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-02-19 16:10 UTC by Vladimir Benes
Modified: 2019-08-06 13:16 UTC (History)
7 users (show)

Fixed In Version: NetworkManager-1.16.2-0.1.20190328git8ec0954570.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-08-06 13:16:20 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:2302 None None None 2019-08-06 13:16:36 UTC

Description Vladimir Benes 2018-02-19 16:10:44 UTC
Description of problem:
when there was something like 
tc.qdiscs:                              root fq_codel

set

I cannot activate (even save) connection after calling
nmcli> set tc.qdiscs 
Enter 'qdiscs' value: 
nmcli> sa
Connection 'testeth1' (a161f176-1f42-4b34-aa03-0f55294fe8d9) successfully updated.
nmcli> ac
Error: connection is not saved. Type 'save' first.

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

Comment 2 Beniamino Galvani 2018-05-07 07:17:14 UTC
In editor_menu_main() after the connection was saved we do:

  con_tmp = nm_client_get_connection_by_uuid (nmc->client,
                                              nm_connection_get_uuid (connection));
  ...

  /* Replace local connection with the remote one to be sure they are equal.
   * This mitigates problems with plugins not preserving some properties or
   * adding ipv{4,6} settings when not present.
   */
  if (con_tmp) {
    gs_free char *s_name = NULL;

    if (menu_ctx.curr_setting)
      s_name = g_strdup (nm_setting_get_name (menu_ctx.curr_setting));

    /* Update settings in the local connection */
    nm_connection_replace_settings_from_connection (connection,
                                                    NM_CONNECTION (con_tmp));

This works under the assumption that after the Update2() D-Bus method
returns, the local NMRemoteConnection is already updated with the new
values. Indeed, the NMSettingsConnection on server first emits the
"Updated" signal and then returns to Update2().

However, the Updated signal doesn't include the setting values and so
libnm has to fire an asynchronous
nmdbus_settings_connection_call_get_setting() to fetch the new
settings. This terminates after the Update2() method returns and thus
the initial assumption is not respected. As a consequence, the
"working" copy of the connection in the editor is different from the
NMRemoteConnection and it's not possible to save it because it's
considered dirty.

At the moment I'm not sure how to fix this.

Comment 3 Beniamino Galvani 2018-11-02 17:16:45 UTC
Fix at:

https://github.com/NetworkManager/NetworkManager/pull/244

Comment 4 Beniamino Galvani 2018-11-20 14:44:43 UTC
Merged upstream as 8af4f76 and backported to nm-1-14.

Comment 7 errata-xmlrpc 2019-08-06 13:16:20 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:2302


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