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.
Bug 1966944 - changing a veth peer name, the old peer is removed but the new one is unmanaged
Summary: changing a veth peer name, the old peer is removed but the new one is unmanaged
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: nmstate
Version: 9.2
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: beta
: ---
Assignee: Fernando F. Mancera
QA Contact: Mingyu Shi
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-02 08:12 UTC by Mingyu Shi
Modified: 2023-05-09 08:19 UTC (History)
6 users (show)

Fixed In Version: nmstate-2.2.1-1.el9
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-05-09 07:30:59 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
log (108.53 KB, text/plain)
2021-06-02 08:12 UTC, Mingyu Shi
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker NMT-520 0 None None None 2023-05-09 00:26:45 UTC
Red Hat Product Errata RHBA-2023:2190 0 None None None 2023-05-09 07:31:13 UTC

Description Mingyu Shi 2021-06-02 08:12:30 UTC
Created attachment 1788638 [details]
log

Description of problem:
When creating a veth pair with nmstate, the local and the peer ifaces are both managed(even though you haven't explicitly listed the peer iface under `interfaces` key). But when changing the peer's name, the old peer is removed, while the new one is unmanaged.

Version-Release number of selected component (if applicable):
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

How reproducible:
100%

Steps to Reproduce:
# At creation, both veth0 and veth0_ep are managed
echo "interfaces:
- name: veth0
  type: veth
  state: up
  veth:
    peer: veth0_ep" | nmstatectl apply -

# At changing, newpeer is created, unmanged
echo "interfaces:
- name: veth0
  type: veth
  state: up
  veth:
    peer: newpeer" | nmstatectl apply -
nmcli con
nmcli dev

# This is exactly same with the 1st step, but veth0_ep is managed
echo "interfaces:
- name: veth0
  type: veth
  state: up
  veth:
    peer: veth0_ep" | nmstatectl apply -
nmcli con
nmcli dev

Actual results:
The old peer is removed while the new one is unmanaged

Expected results:
IMHO:
1. Once created, the peer is not allowed to change
or
2. The peer can be changed and make the new one controlled automatically
or
3. Like #bz1932247 , in anytime, user should explicitly list peer iface under `interfaces` key, otherwise it won't been managed. It's not convenient but gives a consistent experience.

Additional info:

Comment 8 Mingyu Shi 2022-11-30 03:04:44 UTC
Verified with:
nmstate-2.2.1-1.el9.x86_64
NetworkManager-1.41.4-2.el9.x86_64
Linux dell-per740-80.rhts.eng.pek2.redhat.com 5.14.0-197.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Nov 16 14:31:27 EST 2022 x86_64 x86_64 x86_64 GNU/Linux
DISTRO=RHEL-9.2.0-20221118.4

Nmstate removes the old veth pair, creates a new one and managed.

Comment 10 errata-xmlrpc 2023-05-09 07:30:59 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 (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-2023:2190


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