Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Now nmstate supports unmanaged interfaces, this works well if an unmanaged iface is committed as a subordinate/slave, but if it's a base iface, say vlan, nmstate will get failed.
Version-Release number of selected component (if applicable):
nmstate-1.0.0-0.1.el8.noarch
nispor-1.0.1-2.el8.x86_64
NetworkManager-1.30.0-0.2.el8.x86_64
DISTRO=RHEL-8.4.0-20201130.n.0
Linux sun-x5-2l-1.gsslab.rdu2.redhat.com 4.18.0-255.el8.x86_64 #1 SMP Fri Nov 27 08:05:28 EST 2020 x86_64 x86_64 x86_64 GNU/Linux
How reproducible:
100%
Steps to Reproduce:
ip link add dummy4 type dummy
ip link set dummy4 up
echo "---
interfaces:
- name: dummy4.100
type: vlan
state: up
vlan:
base-iface: dummy4
id: 100" | nmstatectl set
Actual results:
failed
Expected results:
No failure
Additional info:
Traceback (most recent call last):
File "/usr/bin/nmstatectl", line 11, in <module>
load_entry_point('nmstate==1.0.0', 'console_scripts', 'nmstatectl')()
File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 70, in main
return args.func(args)
File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 280, in apply
args.save_to_disk,
File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 309, in apply_state
save_to_disk=save_to_disk,
File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 71, in apply
_apply_ifaces_state(plugins, net_state, verify_change, save_to_disk)
File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 104, in _apply_ifaces_state
plugin.apply_changes(net_state, save_to_disk)
File "/usr/lib/python3.6/site-packages/libnmstate/nm/plugin.py", line 181, in apply_changes
NmProfiles(self.context).apply_config(net_state, save_to_disk)
File "/usr/lib/python3.6/site-packages/libnmstate/nm/profiles.py", line 59, in apply_config
self._ctx.wait_all_finish()
File "/usr/lib/python3.6/site-packages/libnmstate/nm/context.py", line 222, in wait_all_finish
raise tmp_error
libnmstate.error.NmstateLibnmError: Activate profile uuid:8b66f857-3154-4866-9afa-3ac7f7ada651 iface:dummy4.100 type: vlan failed: error=nm-manager-error-quark: Activation failed because the device is unmanaged (7)
Comment 1Fernando F. Mancera
2021-05-06 10:40:01 UTC
Hi Mingyu, I think this is correct. If an interface is unmanaged and not mentioned explicitly on the desired state then Nmstate should fail with that message. Why do you think this is wrong? Thanks!
(In reply to Fernando F. Mancera from comment #1)
> Hi Mingyu, I think this is correct. If an interface is unmanaged and not
> mentioned explicitly on the desired state then Nmstate should fail with that
> message. Why do you think this is wrong? Thanks!
If I remember correctly, nmstate was ever designed to automatically control unmanaged interface when needed, and this bug was filed in that old time :)
However, to fix the later issue https://bugzilla.redhat.com/show_bug.cgi?id=1932247 changed this behavior, so it's correct now.
Should we close it as NOTABUG or CURRENTRELEASE ?
Comment 3Fernando F. Mancera
2021-05-16 08:11:47 UTC
(In reply to Mingyu Shi from comment #2)
> (In reply to Fernando F. Mancera from comment #1)
> > Hi Mingyu, I think this is correct. If an interface is unmanaged and not
> > mentioned explicitly on the desired state then Nmstate should fail with that
> > message. Why do you think this is wrong? Thanks!
>
> If I remember correctly, nmstate was ever designed to automatically control
> unmanaged interface when needed, and this bug was filed in that old time :)
> However, to fix the later issue
> https://bugzilla.redhat.com/show_bug.cgi?id=1932247 changed this behavior,
> so it's correct now.
>
> Should we close it as NOTABUG or CURRENTRELEASE ?
Thanks for explaining! I would say CURRENTRELEASE as this was the behavior before but now is fixed.
Comment 4Fernando F. Mancera
2021-05-16 08:13:57 UTC
Well, thinking more about it, I think NOTABUG could be better. Because before it was a bug but as the design of Nmstate changed now is the expected behavior. If someone finds this bug should be able to understand that this is the expected behavior. Thank you!
Description of problem: Now nmstate supports unmanaged interfaces, this works well if an unmanaged iface is committed as a subordinate/slave, but if it's a base iface, say vlan, nmstate will get failed. Version-Release number of selected component (if applicable): nmstate-1.0.0-0.1.el8.noarch nispor-1.0.1-2.el8.x86_64 NetworkManager-1.30.0-0.2.el8.x86_64 DISTRO=RHEL-8.4.0-20201130.n.0 Linux sun-x5-2l-1.gsslab.rdu2.redhat.com 4.18.0-255.el8.x86_64 #1 SMP Fri Nov 27 08:05:28 EST 2020 x86_64 x86_64 x86_64 GNU/Linux How reproducible: 100% Steps to Reproduce: ip link add dummy4 type dummy ip link set dummy4 up echo "--- interfaces: - name: dummy4.100 type: vlan state: up vlan: base-iface: dummy4 id: 100" | nmstatectl set Actual results: failed Expected results: No failure Additional info: Traceback (most recent call last): File "/usr/bin/nmstatectl", line 11, in <module> load_entry_point('nmstate==1.0.0', 'console_scripts', 'nmstatectl')() File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 70, in main return args.func(args) File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 280, in apply args.save_to_disk, File "/usr/lib/python3.6/site-packages/nmstatectl/nmstatectl.py", line 309, in apply_state save_to_disk=save_to_disk, File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 71, in apply _apply_ifaces_state(plugins, net_state, verify_change, save_to_disk) File "/usr/lib/python3.6/site-packages/libnmstate/netapplier.py", line 104, in _apply_ifaces_state plugin.apply_changes(net_state, save_to_disk) File "/usr/lib/python3.6/site-packages/libnmstate/nm/plugin.py", line 181, in apply_changes NmProfiles(self.context).apply_config(net_state, save_to_disk) File "/usr/lib/python3.6/site-packages/libnmstate/nm/profiles.py", line 59, in apply_config self._ctx.wait_all_finish() File "/usr/lib/python3.6/site-packages/libnmstate/nm/context.py", line 222, in wait_all_finish raise tmp_error libnmstate.error.NmstateLibnmError: Activate profile uuid:8b66f857-3154-4866-9afa-3ac7f7ada651 iface:dummy4.100 type: vlan failed: error=nm-manager-error-quark: Activation failed because the device is unmanaged (7)