Bug 1970051 - [SRIOV] min BW placement enforcement fails when NIC does not support dataplane enforcement
Summary: [SRIOV] min BW placement enforcement fails when NIC does not support dataplan...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-neutron
Version: 16.2 (Train)
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ga
: 16.2 (Train on RHEL 8.4)
Assignee: Rodolfo Alonso
QA Contact: Roman Safronov
URL:
Whiteboard:
Depends On: 1972774 1983792 1983958
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-09 17:11 UTC by Roman Safronov
Modified: 2022-08-17 13:31 UTC (History)
4 users (show)

Fixed In Version: openstack-neutron-15.3.5-2.20210608154811.ed0dab6.el8ost.1
Doc Type: No Doc Update
Doc Text:
Clone Of: 1937432
Environment:
Last Closed: 2021-09-15 06:39:15 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker OSP-4496 0 None None None 2022-08-17 13:31:56 UTC
Red Hat Product Errata RHSA-2021:3488 0 None None None 2021-09-15 06:39:27 UTC

Description Roman Safronov 2021-06-09 17:11:34 UTC
+++ This bug was initially created as a clone of Bug #1937432 +++

Description of problem:
We are testing min BW placement enforcement on a setup with Intel NICs that don't support min BW dataplane enforcement.

When the sriov agent's qos extension is enabled, the sriov agent tries to apply QoS dataplane enforcements.

Due to this, when a server is created using a direct/VF port that has a qos-policy with a minimum bw rule, the following errors are shown by the sriov agent logs:
2021-03-10 14:52:31.065 111774 DEBUG neutron.plugins.ml2.drivers.mech_sriov.agent.eswitch_manager [req-e3eeb9fe-ed86-450a-85c9-9279a452cb18 - - - - -] Setting 1000 Mbps limit for port 2 set_device_rate /usr/lib/python3.6/site-packages/neutron/plugins/ml2/drivers/mech_sriov/agent/eswitch_manager.py:240
2021-03-10 14:52:31.187 114571 DEBUG oslo.privsep.daemon [-] privsep: Exception during request[140011213354704]: Invalid parameter/value used on interface enp5s0f0, namespace None. _process_cmd /usr/lib/python3.6/site-packages/oslo_privsep/daemon.py:490
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/neutron/privileged/agent/linux/ip_lib.py", line 299, in _run_iproute_link
    return ip.link(command, index=idx, **kwargs)
  File "/usr/lib/python3.6/site-packages/pyroute2/iproute/linux.py", line 1163, in link
    msg_flags=msg_flags)
  File "/usr/lib/python3.6/site-packages/pyroute2/netlink/nlsocket.py", line 373, in nlm_request
    return tuple(self._genlm_request(*argv, **kwarg))
  File "/usr/lib/python3.6/site-packages/pyroute2/netlink/nlsocket.py", line 864, in nlm_request
    callback=callback):
  File "/usr/lib/python3.6/site-packages/pyroute2/netlink/nlsocket.py", line 376, in get
    return tuple(self._genlm_get(*argv, **kwarg))
  File "/usr/lib/python3.6/site-packages/pyroute2/netlink/nlsocket.py", line 701, in get
    raise msg['header']['error']
pyroute2.netlink.exceptions.NetlinkError: (22, 'Invalid argument')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/oslo_privsep/daemon.py", line 485, in _process_cmd
    ret = func(*f_args, **f_kwargs)
  File "/usr/lib/python3.6/site-packages/neutron/privileged/agent/linux/ip_lib.py", line 73, in sync_inner
    return input_func(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/oslo_privsep/priv_context.py", line 247, in _wrap
    return func(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/neutron/privileged/agent/linux/ip_lib.py", line 448, in set_link_vf_feature
    return _run_iproute_link("set", device, namespace=namespace, vf=vf_config)
  File "/usr/lib/python3.6/site-packages/neutron/privileged/agent/linux/ip_lib.py", line 301, in _run_iproute_link
    _translate_ip_device_exception(e, device, namespace)
  File "/usr/lib/python3.6/site-packages/neutron/privileged/agent/linux/ip_lib.py", line 279, in _translate_ip_device_exception
    raise InvalidArgument(device=device, namespace=namespace)
neutron.privileged.agent.linux.ip_lib.InvalidArgument: Invalid parameter/value used on interface enp5s0f0, namespace None.



There is a workaround for this: disabling qos extension from the sriov agent, but then, no BW limit dataplane enforcement can be done (and this is supported by our Intel NICs).



Version-Release number of selected component (if applicable):
RHOS-16.2-RHEL-8-20210525.n.0


How reproducible:
100%


Steps to Reproduce:
1. create qos policy and qos rule
  openstack network qos policy create guaranteed_min_bw
  openstack network qos rule create --type minimum-bandwidth --min-kbps 1000000 --egress guaranteed_min_bw

2. create a direct port associated to the previous qos policy
  openstack port create --qos-policy guaranteed_min_bw --vnic-type direct --network nova port-direct-0


3. create a server with that port
  openstack server create --port port-direct-0 --image tempest_image --flavor 200 vm-0

Comment 6 Roman Safronov 2021-07-20 06:37:16 UTC
Verification of this bug is blocked by https://bugzilla.redhat.com/show_bug.cgi?id=1983792

Comment 9 Roman Safronov 2021-07-25 08:44:00 UTC
Verified on puddle: RHOS-16.2-RHEL-8-20210722.n.0 which uses openstack-neutron-15.3.5-2.20210608154812.el8ost.2.noarch.rpm   
Verified that min BW placement enforcement works.

Comment 13 errata-xmlrpc 2021-09-15 06:39:15 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 (Important: Red Hat OpenStack Platform 16.2 (openstack-neutron) security 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/RHSA-2021:3488


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