When using Qos together with Neutron trunk ports the max bandwidth limits are not applied, neither for ovs-hybrid, nor for ovs-firewall
The reason is that a new ovs bridge is created to handle the trunk (parent + subport) ports.
For instance:
Bridge "tbr-c5402c58-3"
Port "tpt-e739265b-2b"
Interface "tpt-e739265b-2b"
type: patch
options: {peer="tpi-e739265b-2b"}
Port "qvoe739265b-2b"
Interface "qvoe739265b-2b"
Port "spt-17c950c4-f5"
tag: 101
Interface "spt-17c950c4-f5"
type: patch
options: {peer="spi-17c950c4-f5"}
Port "tbr-c5402c58-3"
Interface "tbr-c5402c58-3"
type: internal
Then, the _set_egress_bw_limit_for_port (https://github.com/openstack/neutron/blob/master/neutron/agent/common/ovs_lib.py#L553) is applied to tpi-e739265b-2b or spi-17c950c4-f5 (depending on if the qos rule is applied to the parent or the subport ports, respectively). However, these are of patch type, i.e., they are fully virtual and the kernel does not know about them, therefore the QoS rules are not applied.
To reproduce it:
- Enable QoS devstack local.conf:
enable_plugin neutron https://github.com/openstack/neutron
enable_service q-qos
- Enable trunk in neutron.conf:
service_plugins = ... qos,trunk
- Create QoS rule
- Apply the qos rule to either parent or subport ports
- Test bandwidth limit (e.g., with iperf)
Thanks for reporting, one way to fix this could be to change the patch ports into internal ports, that should come with a little throughput degradation compared to no flows.