This bug has been migrated to another issue tracking site. It has been closed here and may no longer be being monitored.

If you would like to get updates for this issue, or to participate in it, you may do so at Red Hat Issue Tracker .
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 2127834 - Updating portgroup of ovs interface should fail
Summary: Updating portgroup of ovs interface should fail
Keywords:
Status: CLOSED MIGRATED
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libvirt
Version: 9.1
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Virtualization Maintenance
QA Contact: yalzhang@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-09-19 08:18 UTC by Fangge Jin
Modified: 2023-09-22 15:52 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-09-22 15:52:54 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker   RHEL-7299 0 None Migrated None 2023-09-22 15:52:45 UTC
Red Hat Issue Tracker RHELPLAN-134245 0 None None None 2022-09-19 08:24:47 UTC

Description Fangge Jin 2022-09-19 08:18:30 UTC
Description of problem:
Update portgroup of ovs interface, the port tag is cleared unexpectedly.

Version-Release number of selected component (if applicable):
libvirt-8.5.0-6.el9.x86_64
openvswitch2.15-2.15.0-70.el9fdp.x86_64


How reproducible:
100%

Steps to Reproduce:
1. Create an openvswitch bridge
# ovs-vsctl show
ce606951-de6b-4515-9280-44b2a6766a57
    Bridge "ovsbr0"
        Port "ovsbr0"
            Interface "ovsbr0"
                type: internal
        Port "eno8303"
            Interface "eno8303"
    ovs_version: "2.15.6"

2. Create an openvswitch network:
<network>
  <name>ovs-net</name>
  <uuid>1546c287-e22f-41c5-8eef-12ccb8a54af6</uuid>
  <forward mode='bridge'/>
  <bridge name='ovsbr0'/>
  <vlan trunk='yes'>
    <tag id='42' nativeMode='untagged'/>
    <tag id='47'/>
  </vlan>
  <virtualport type='openvswitch'>
    <parameters interfaceid='09b11c53-8b5c-4eeb-8f00-d84eaa0aaa4f'/>
  </virtualport>
  <portgroup name='dontpanic'>
    <vlan>
      <tag id='42'/>
    </vlan>
  </portgroup>
</network>

3. Start a vm

4. Attach a openvswitch interface to vm:
# virsh attach-interface vm111 --type network --source ovs-net --model virtio
Interface attached successfully

# virsh dumpxml vm111 --xpath //interface
<interface type="bridge">
  <mac address="52:54:00:07:7e:14"/>
  <source network="ovs-net" portid="555b1703-8f01-4f74-b15d-674b0c5e695a" bridge="ovsbr0"/>
  <vlan trunk="yes">
    <tag id="42" nativeMode="untagged"/>
    <tag id="47"/>
  </vlan>
  <virtualport type="openvswitch">
    <parameters interfaceid="09b11c53-8b5c-4eeb-8f00-d84eaa0aaa4f"/>
  </virtualport>
  <target dev="vnet3"/>
  <model type="virtio"/>
  <alias name="net0"/>
  <address type="pci" domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</interface>

# ovs-vsctl show
ce606951-de6b-4515-9280-44b2a6766a57
    Bridge ovsbr0
        Port ovsbr0
            Interface ovsbr0
                type: internal
        Port vnet3
            tag: 42
            trunks: [42, 47]
            Interface vnet3
        Port eno8303
            Interface eno8303
    ovs_version: "2.15.6"

5. Update interface portgroup:
# cat ovs-inc.xml
<interface type="network">
  <mac address="52:54:00:e9:a0:ba"/>
  <source network='ovs-net' portgroup='dontpanic'/>
  <model type="virtio"/>
  <address type="pci" domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</interface>


# virsh update-device vm111 ovs-inc.xml
Device updated successfully

6. Check the updated interface:
# virsh dumpxml vm111 --xpath //interface
<interface type="bridge">
  <mac address="52:54:00:e9:a0:ba"/>
  <source network="ovs-net" portgroup="dontpanic" portid="a31b4f86-cfe7-4951-b23a-1f6465df7345" bridge="ovsbr0"/>
  <vlan>
    <tag id="42"/>
  </vlan>
  <virtualport type="openvswitch">
    <parameters interfaceid="09b11c53-8b5c-4eeb-8f00-d84eaa0aaa4f"/>
  </virtualport>
  <target dev="vnet4"/>
  <model type="virtio"/>
  <alias name="net0"/>
  <address type="pci" domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</interface>

# ovs-vsctl show                       
ce606951-de6b-4515-9280-44b2a6766a57
    Bridge ovsbr0
        Port ovsbr0
            Interface ovsbr0
                type: internal
        Port eno8303
            Interface eno8303
        Port vnet4
            Interface vnet4
    ovs_version: "2.15.6"


Actual results:
When updating interface portgroup, ovs port tag is cleared.

Expected results:
Updating interface portgroup should fail like:
# virsh update-device rhel interface.xml 
error: Failed to update device from interface.xml
error: internal error: Unable to set vlan configuration on port vnet4

Additional info:
1. Check the syslog:
ovs-vsctl[286450]: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --if-exists clear Port vnet4 tag -- --if-exists clear Port vnet4 trunk -- --if-exists clear Port vnet4 vlan_mode

Comment 1 Michal Privoznik 2022-09-19 10:54:46 UTC
Oh, I see the problem: the vlan setting is inherited from the network, it's not part of the interface XML and yet, libvirt clears the the vlan setting.

Comment 2 RHEL Program Management 2023-09-22 15:51:09 UTC
Issue migration from Bugzilla to Jira is in process at this time. This will be the last message in Jira copied from the Bugzilla bug.

Comment 3 RHEL Program Management 2023-09-22 15:52:54 UTC
This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated.  Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "RHEL-" followed by an integer.  You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

"Bugzilla Bug" = 1234567

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.


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