Hide Forgot
Created attachment 1767600 [details] Reproducer Description of problem: Setting of static DNS with dynamic IP results in verification error. Version-Release number of selected component (if applicable): nmstate-1.1.0-0.20210330.1343gitc4e66f3.el8.noarch nispor-1.0.1-4.el8.x86_64 NetworkManager-1.30.3-27812.copr.5eadbb29c7.el8.x86_64 How reproducible: 100% Steps to Reproduce: 1. Have default route with dns on unrelated interface e.g. eth0 2. Run reproducer script Actual results: Traceback (most recent call last): File "/usr/bin/nmstatectl", line 11, in <module> load_entry_point('nmstate==1.1.0', 'console_scripts', 'nmstatectl')() File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 73, in main return args.func(args) File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 326, in set return apply(args) File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 343, in apply args.save_to_disk, File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 407, in apply_state save_to_disk=save_to_disk, File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 78, in apply _apply_ifaces_state(plugins, net_state, verify_change, save_to_disk) File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 134, in _apply_ifaces_state _verify_change(plugins, net_state) File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 147, in _verify_change net_state.verify(current_state) File "/usr/lib/python3.6/site-packages/libnmstate/net_state.py", line 75, in verify self._dns.verify(current_state.get(DNS.KEY)) File "/usr/lib/python3.6/site-packages/libnmstate/dns.py", line 196, in verify {DNS.KEY: cur_dns.config}, libnmstate.error.NmstateVerificationError: desired ======= --- dns-resolver: server: - 1.1.1.1 current ======= --- dns-resolver: search: [] server: [] difference ========== --- desired +++ current @@ -1,4 +1,4 @@ --- dns-resolver: - server: - - 1.1.1.1 + search: [] + server: [] Expected results: Should configure desired state. Additional info: The same flow was working with nmstate-0.3.
Upstream PR: https://github.com/nmstate/nmstate/pull/1580
Patch merged!
Created attachment 1782209 [details] pre-tested.log Pretested with versions: nmstate-1.1.0-0.20210511.1358git3463c8e.el8.noarch nispor-1.0.1-4.el8.x86_64 NetworkManager-1.32.0-0.2.el8.x86_64 Linux mshi-rhel-850-20210328d2 4.18.0-301.1.el8.x86_64 #1 SMP Mon Mar 29 15:21:06 EDT 2021 x86_64 x86_64 x86_64 GNU/Linux Check the attachment: veth0 is with a default route and unmanaged, applied DNS 1.1.1.1 and dummy0(DHCP without manual dns), 1.1.1.1 was written into dummy0 profile while veth0 stayed unmanaged
Verified with versions: nmstate-1.1.0-0.1.el8.noarch nispor-1.1.0-1.el8.x86_64 NetworkManager-1.32.0-0.4.el8.x86_64
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 (nmstate bug fix and enhancement update), 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-2021:4157