[PATCH 0/2] virDomain: fix problems when setting qos on ovs managed interface

zhangjl02 jx8zjs at 126.com
Mon Aug 9 02:05:58 UTC 2021

Two problems are found and fixed below:
1. Ingress rules is not clean on previous version of virNetDevOpenvswitchInterfaceClearQos.
2. If errors occurs when removing inbound qos on multi interfaces vm, some rules may not be delete as aspected.

Fix by:
Instead of cleaning all qos rules each time new qos is set, tx and rx's qos are set or cleaned respectively.
Replace virReportError with VIR_WARN to let the cleaning process continue when error occurs.
Add ifname into ovs querying statements, which will reduce failure of removing qos on the other interfaces of the same vm.

Test virNetDevOpenvswitchInterfaceSetQos and virNetDevOpenvswitchInterfaceClearQos with dryrun method.
Since commands in tests are not actually run, it is difficult to emulate some complex senario, such as set and then update qos.
So basic tests are added in patches.

Jinsheng Zhang (2):
  virDomain: interface: add  virNetDevOpenvswitchInterfaceClearTxQos and
  tests: add test on virNetDevOpenvswitchInterfaceSetQos  and

 src/libvirt_private.syms         |   2 +
 src/util/virnetdevopenvswitch.c  |  69 +++++++++--
 src/util/virnetdevopenvswitch.h  |   7 ++
 tests/virnetdevopenvswitchtest.c | 196 ++++++++++++++++++++++++++++++-
 4 files changed, 262 insertions(+), 12 deletions(-)


More information about the libvir-list mailing list