BGPVPN Port association, fails to remove a prefix

Bug #1743574 reported by Thomas Morin
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
BaGPipe
Fix Released
Undecided
Unassigned
networking-bgpvpn
Fix Released
Undecided
Unassigned

Bug Description

test test_bgpvpn_port_association_create_and_update
from https://review.openstack.org/#/c/534187 is currently failing, the bgpvn agent extension fails to detach the Port association prefix routes

Revision history for this message
Thomas Morin (tmmorin-orange) wrote :

The tempest logs show the following:

2018-01-18 09:37:46,497 19635 INFO [tempest.lib.common.rest_client] Request (TestBGPVPNBasic:test_bgpvpn_port_association_create_and_update): 200 PUT http://104.130.222.9:9696/v2.0/bgpvpn/bgpvpns/d0e6d78e-649c-4721-a293-bdc2da3a1ced/port_associations/aa229901-2670-4dd3-b169-18cb97057663 0.618s
2018-01-18 09:37:46,498 19635 DEBUG [tempest.lib.common.rest_client] Request - Headers: {'X-Auth-Token': '<omitted>', 'Accept': 'application/json', 'Content-Type': 'application/json'}
        Body: {"port_association": {"routes": []}}
    Response - Headers: {u'content-type': 'application/json', 'status': '200', 'content-location': 'http://104.130.222.9:9696/v2.0/bgpvpn/bgpvpns/d0e6d78e-649c-4721-a293-bdc2da3a1ced/port_associations/aa229901-2670-4dd3-b169-18cb97057663', u'date': 'Thu, 18 Jan 2018 09:37:46 GMT', u'content-length': '228', u'x-openstack-request-id': 'req-a5d89dd2-b450-4383-b961-56ab619c8051', u'connection': 'close'}
        Body: {"port_association": {"advertise_fixed_ips": true, "routes": [{"local_pref": null, "prefix": "192.168.0.0/24", "type": "prefix"}], "port_id": "e0085573-be13-407c-b4b4-7cc2dc0174c7", "id": "aa229901-2670-4dd3-b169-18cb97057663"}}

It means that the route update is not taken into account by the bgpvpn API/DB layer.

no longer affects: bgpvpn
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-bagpipe (master)

Reviewed: https://review.openstack.org/534331
Committed: https://git.openstack.org/cgit/openstack/networking-bagpipe/commit/?id=8560427c02db1e34f517c763d1de0fda09ecb067
Submitter: Zuul
Branch: master

commit 8560427c02db1e34f517c763d1de0fda09ecb067
Author: Thomas Morin <email address hidden>
Date: Tue Jan 16 15:37:25 2018 +0100

    agent extensions: fix conditional detach for multiple attachments

    A detach should be honored even if there remains
    attachments for the same vpn type.

    This simple fix is only a partial fix, because it
    introduces bug 1744344.

    Change-Id: I6c8a46093fbbf62eff263140a9123b62dee00560
    Partial-Bug: 1743574

description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to networking-bgpvpn (master)

Reviewed: https://review.openstack.org/535913
Committed: https://git.openstack.org/cgit/openstack/networking-bgpvpn/commit/?id=4e5e8d70d6044b2638a55bb50f1095aaab3e516e
Submitter: Zuul
Branch: master

commit 4e5e8d70d6044b2638a55bb50f1095aaab3e516e
Author: Thomas Morin <email address hidden>
Date: Fri Jan 19 16:28:40 2018 +0100

    db: refresh port association db object after route update

    When routes are removed or added to a port association
    DB, we need to refresh our DB object or else the dict
    produced will be generated from the non-updated set of
    routes.

    Change-Id: Ib77813247058a4dafed5c36b3dc46717282f200a
    Related-Bug: 1743574

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-bagpipe (master)

Reviewed: https://review.openstack.org/535827
Committed: https://git.openstack.org/cgit/openstack/networking-bagpipe/commit/?id=d73cf574db4b38875e12e4e03b3fe1d004ff0d4d
Submitter: Zuul
Branch: master

commit d73cf574db4b38875e12e4e03b3fe1d004ff0d4d
Author: Thomas Morin <email address hidden>
Date: Fri Jan 19 17:15:50 2018 +0100

    bgpvpn: agent extension, fix port association 'routes' update

    This change fixes the code to handle port association updates:
    if an update adds routes and removes routes, we were
    only detaching removed routes.

    Change-Id: Ib8c7d3162d5322702ad6a149f903b1c705daabd8
    Closes-Bug: 1743574

Changed in networking-bagpipe:
status: New → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to networking-bagpipe (master)

Fix proposed to branch: master
Review: https://review.openstack.org/536777

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-bagpipe (master)

Reviewed: https://review.openstack.org/536777
Committed: https://git.openstack.org/cgit/openstack/networking-bagpipe/commit/?id=42ad4d3e0dbe3da09582a525623be4fa75604f78
Submitter: Zuul
Branch: master

commit 42ad4d3e0dbe3da09582a525623be4fa75604f78
Author: Thomas Morin <email address hidden>
Date: Tue Jan 23 12:20:39 2018 +0100

    bagpipe-bgp: properly withdraw route on detach

    If advertise_subnet was not provided on detach, the BGP
    route withdrawal was done with a different RD than the announce,
    and hence failing.

    This change stores the route advertised on vif_plugged to
    reuse the exact same route on vif_unplugged to avoid this
    issue and similar ones.

    (this change also restablish code in bagpipe_bgp_agent
    that was mistakenly reverted in
    67228906e8ee89186c3e8c7869df91758027f0a3)

    Change-Id: I9c232656814e6e8b7d271b498c6907d9cf42dfb8
    Closes-Bug: 1743574

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to networking-bgpvpn (master)

Reviewed: https://review.openstack.org/535225
Committed: https://git.openstack.org/cgit/openstack/networking-bgpvpn/commit/?id=02f970454fe4d7e6106aa34919ba2809903c9018
Submitter: Zuul
Branch: master

commit 02f970454fe4d7e6106aa34919ba2809903c9018
Author: Thomas Morin <email address hidden>
Date: Thu Jan 18 09:22:16 2018 +0100

    tempest: enable test_bgpvpn_port_association_create_and_update

    Unskip the test after closing bug 1743574.

    Related-Bug: 1743574
    Depends-On: Iadae21c1c4cbe230c385c7b6fbd37b4f61c6e6b3

    Change-Id: Ie18f24c047243f02417c307ad4f72d73ac561656

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/networking-bagpipe 8.0.0.0b3

This issue was fixed in the openstack/networking-bagpipe 8.0.0.0b3 development milestone.

Changed in bgpvpn:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.