NetworkManager/clients/cli
Beniamino Galvani 2a8181bcd7 core,libnm: don't touch device TC configuration by default
NetworkManager supports a very limited set of qdiscs. If users want to
configure a unsupported qdisc, they need to do it outside of
NetworkManager using tc.

The problem is that NM also removes all qdiscs and filters during
activation if the connection doesn't contain a TC setting. Therefore,
setting TC configuration outside of NM is hard because users need to
do it *after* the connection is up (for example through a dispatcher
script).

Let NM consider the presence (or absence) of a TC setting in the
connection to determine whether NM should configure (or not) qdiscs
and filters on the interface. We already do something similar for
SR-IOV configuration.

Since new connections don't have the TC setting, the new behavior
(ignore existing configuration) will be the default. The impact of
this change in different scenarios is:

 - the user previously configured TC settings via NM. This continues
   to work as before;

 - the user didn't set any qdiscs or filters in the connection, and
   expected NM to clear them from the interface during activation.
   Here there is a change in behavior, but it seems unlikely that
   anybody relied on the old one;

 - the user didn't care about qdiscs and filters; NM removed all
   qdiscs upon activation, and so the default qdisc from kernel was
   used. After this change, NM will not touch qdiscs and the default
   qdisc will be used, as before;

 - the user set a different qdisc via tc and NM cleared it during
   activation. Now this will work as expected.

So, the new default behavior seems better than the previous one.

https://bugzilla.redhat.com/show_bug.cgi?id=1928078
(cherry picked from commit a48edd0410)
2021-06-17 16:51:25 +02:00
..
agent.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
common.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
common.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00
connections.c nmcli: invoke ReloadConnections() D-Bus method asynchronously 2021-06-10 18:09:52 +02:00
connections.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00
devices.c cli: fix leak in print_wifi_connection() 2021-06-04 21:30:49 +02:00
devices.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00
general.c nmcli: invoke Reload() D-Bus method asynchronously 2021-06-10 18:09:03 +02:00
generate-docs-nm-settings-nmcli.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
generate-docs-nm-settings-nmcli.xml.in core,libnm: don't touch device TC configuration by default 2021-06-17 16:51:25 +02:00
meson.build all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
nmcli-completion cli: make nmcli do its own command completion 2017-02-13 16:32:15 +01:00
nmcli.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
nmcli.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00
polkit-agent.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
polkit-agent.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00
settings.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
settings.h all: move shared/nm-meta-setting.[hc] to libnm-core and clients 2021-02-09 12:38:19 +01:00
utils.c all: add "libnm/nm-default-client.h" as replacement for "nm-default.h" 2021-02-09 12:38:17 +01:00
utils.h all: update deprecated SPDX license identifiers 2021-01-05 09:46:21 +01:00