Physical network max-bw QoS is applied on the localnet port
The test ``QosTestExternalNetwork.test_dscp_bwlimit_external_network``
is checking the QoS max-bw rules, using "iperf3" between two VMs. Since
[1][2], the QoS min and max BW rules for LSPs in LS that have associated
a physical network (and a localnet port) are defined in the LSP.options
dictionary. The QoS values are set in the localnet port interface using
"tc" commands.
If the "iperf3" is done between VMs in the same compute node, this
traffic won't cross the localnet port and the QoS rules won't be
applied.
The method ``_test_both_bwlimit_dscp`` checks the bandwidth between the
"sender" and "receiver" VMs, that are explicitly created in two
different compute nodes.
This method is also validating the DSCP mark, using the aforementioned
VMs. The code below the method call is redundant and removed.
[1]https://review.opendev.org/c/openstack/neutron/+/934418
[2]87514ac042
Closes-Bug: #2099755
Change-Id: I68e6730b19a81f2e9ca6c951e8920e650d7488c2
This commit is contained in:
parent
98b5177a87
commit
8c3bb22f49
@ -1007,12 +1007,6 @@ class QosTestExternalNetwork(QosBaseTest):
|
||||
def setUp(self):
|
||||
super(QosTestExternalNetwork, self).setUp()
|
||||
self.ensure_external_network_is_shared()
|
||||
ext_vm = self._create_server(
|
||||
network=self.external_network,
|
||||
create_floating_ip=False)
|
||||
self.ext_vm_ssh_client = ssh.Client(
|
||||
ext_vm['port']['fixed_ips'][0]['ip_address'], self.username,
|
||||
pkey=self.keypair['private_key'])
|
||||
|
||||
@testtools.skipUnless(
|
||||
CONF.compute.min_compute_nodes > 1,
|
||||
@ -1032,37 +1026,6 @@ class QosTestExternalNetwork(QosBaseTest):
|
||||
self._test_both_bwlimit_dscp(
|
||||
vms, max_kbps, dscp_mark, CONF.network.public_network_id)
|
||||
|
||||
LOG.debug('testing BW limit from a VM instances connected to the '
|
||||
'external network (receiver) to an Ext VM')
|
||||
# we need to test ingress from the Ext VM PoV because the BW limit
|
||||
# egress rule is associated to the receiver VM instance
|
||||
self._validate_bw_limit({'ssh_client': self.ext_vm_ssh_client},
|
||||
vms['receiver'], egress=False,
|
||||
bw_limit=max_kbps * 1000,
|
||||
protocol=constants.PROTO_NAME_TCP)
|
||||
|
||||
server_port = self.client.list_ports(
|
||||
device_id=vms['receiver']['id'])['ports'][0]
|
||||
server_ip = server_port['fixed_ips'][0]['ip_address']
|
||||
LOG.debug('testing DSCP mark from the test device (undercloud) to '
|
||||
'a VM instance connected to the external network')
|
||||
# undercloud's interface towards the receiver IP
|
||||
interface = utils.get_route_interface(
|
||||
self.ext_vm_ssh_client, server_ip)
|
||||
# tcpdump filter to capture marked ping reply
|
||||
filtrs = '"(ip and (ip[1] & 0xfc) >> 2 == {}) and src host {}"'.format(
|
||||
dscp_mark, server_ip)
|
||||
remote_capture = capture.TcpdumpCapture(
|
||||
self.ext_vm_ssh_client, interface, filtrs)
|
||||
self.useFixture(remote_capture)
|
||||
time.sleep(10)
|
||||
self.check_remote_connectivity(
|
||||
self.ext_vm_ssh_client, server_ip, ping_count=1)
|
||||
time.sleep(5)
|
||||
remote_capture.stop()
|
||||
msg = 'Not found packets with expected DSCP value'
|
||||
self.assertFalse(remote_capture.is_empty(), msg)
|
||||
|
||||
|
||||
class QosTestSriovBaseTest(QosBaseTest):
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user