Bug 1572578 - QuotasTest.test_detail_quotas failing for OVN
Summary: QuotasTest.test_detail_quotas failing for OVN
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: python-neutron-tests-tempest
Version: 13.0 (Queens)
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: z2
: 13.0 (Queens)
Assignee: Lucas Alvares Gomes
QA Contact: Eran Kuris
URL:
Whiteboard:
: 1575844 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-27 10:45 UTC by Lucas Alvares Gomes
Modified: 2019-09-09 13:15 UTC (History)
12 users (show)

Fixed In Version: python-neutron-tests-tempest-0.0.1-0.20180419105838.f33d59b.el7ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-08-29 16:20:28 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
OpenStack gerrit 564757 0 None MERGED Make test_detail_quota() test more generic 2020-05-18 10:02:02 UTC
Red Hat Product Errata RHBA-2018:2596 0 None None None 2018-08-29 16:20:51 UTC

Description Lucas Alvares Gomes 2018-04-27 10:45:38 UTC
Description of problem:

The tempest test neutron_tempest_plugin.api.admin.test_quotas.QuotasTest.test_detail_quotas is failing for OVN with:

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/tempest/common/utils/__init__.py", line 107, in wrapper
    return func(*func_args, **func_kwargs)
  File "/usr/lib/python2.7/site-packages/neutron_tempest_plugin/api/admin/test_quotas.py", line 145, in test_detail_quotas
    quota_set[key]['used'])
  File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 350, in assertEqual
    self.assertThat(observed, matcher, message)
  File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 435, in assertThat
    raise mismatch_error
testtools.matchers._impl.MismatchError: 1 != 2

The reason of the failure has to deal with the networking-ovn's metadata implementation. Basically, when metadata is enabled (and it's for the CI) and we create a network resource for OVN, networking-ovn will also allocate a port to be used by the metadata agent [0].

That port will deduct 1 from the user's quota for ports and that is causing the difference there which is making the test fail.

...

Since this is an API test (that runs when the quota_details API extension for neutron is enabled) I think that there's little to us to do to fix it without having to do a big refactor in the networking-ovn's code, which I don't think is worth of it to fix this test.

Perhaps, disabling that extension in the CI for now would be the easiest way to deal with the problem.

[0] https://github.com/openstack/networking-ovn/blob/4a5b0564de38d0d43d821dc8d8d21faba9589a8d/networking_ovn/common/ovn_client.py#L1154


Version-Release number of selected component (if applicable):

OSP 13.0

Comment 3 Lucas Alvares Gomes 2018-04-27 13:28:27 UTC
The patch [0] uses a different approach and calculates the number of used ports on that test after the network has been created. Perhaps that's more generic and doesn't require disabling the test or the extension for OVN. 

[0] https://review.openstack.org/#/c/564757/

Comment 4 Lucas Alvares Gomes 2018-04-27 13:29:06 UTC
The patch [0] uses a different approach and calculates the number of used ports on that test after the network has been created. Perhaps that's more generic and doesn't require disabling the test or the extension for OVN. 

[0] https://review.openstack.org/#/c/564757/

Comment 5 Lucas Alvares Gomes 2018-05-16 13:42:57 UTC
*** Bug 1575844 has been marked as a duplicate of this bug. ***

Comment 6 Daniel Alvarez Sanchez 2018-05-21 08:28:50 UTC
Patch is merged upstream

Comment 16 Eran Kuris 2018-08-08 06:00:43 UTC
Fix verified on osp13z2 
13.0-RHEL-7/2018-08-03.3

python2-neutron-tests-tempest-0.0.1-0.20180425142843.02a5e2b.el7ost.noarch

https://rhos-qe-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/view/DFG/view/network/view/networking-ovn/job/DFG-network-networking-ovn-13_director-rhel-virthost-3cont_2comp-ipv4-geneve/139/testReport/neutron_tempest_plugin.api.admin.test_quotas/QuotasTest/tes
t_detail_quotas_gate_id_e974b5ba_090a_452c_a578_f9710151d9fc_/

Comment 17 Joanne O'Flynn 2018-08-13 14:18:44 UTC
This bug is marked for inclusion in the errata but does not currently contain draft documentation text. To ensure the timely release of this advisory please provide draft documentation text for this bug as soon as possible.

If you do not think this bug requires errata documentation, set the requires_doc_text flag to "-".


To add draft documentation text:

* Select the documentation type from the "Doc Type" drop down field.

* A template will be provided in the "Doc Text" field based on the "Doc Type" value selected. Enter draft text in the "Doc Text" field.

Comment 18 Lucas Alvares Gomes 2018-08-13 14:23:22 UTC
(In reply to Joanne O'Flynn from comment #17)
> This bug is marked for inclusion in the errata but does not currently
> contain draft documentation text. To ensure the timely release of this
> advisory please provide draft documentation text for this bug as soon as
> possible.
> 
> If you do not think this bug requires errata documentation, set the
> requires_doc_text flag to "-".
> 
> 
> To add draft documentation text:
> 
> * Select the documentation type from the "Doc Type" drop down field.
> 
> * A template will be provided in the "Doc Text" field based on the "Doc
> Type" value selected. Enter draft text in the "Doc Text" field.

Thanks Joanne,

This bug is only related to a test run so I don't think it needs any documentation about it. I've set the requires_doc_text flag to "-" as requested for this case.

Comment 20 errata-xmlrpc 2018-08-29 16:20:28 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, 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/RHBA-2018:2596


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