config-openstack: resolve subnet-uuid inconsistency in subnet read

Bug #1511864 reported by Hampapur Ajay
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R2.20
Fix Committed
Undecided
Hampapur Ajay
R2.21.x
Fix Committed
Undecided
Hampapur Ajay
Trunk
Fix Committed
Undecided
Hampapur Ajay

Bug Description

Subnet-uuid to Subnet-key(net,pfx) is maintained in useragent-kv table since subnet was not a first class object in contrail db schema.

Before [1], this mapping was maintained by neutron_plugin_db.py and in case it encountered a missing mapping from id to key, it would read in all networks and heal the entry for the *specific* subnet. With [1], the mapping of id to key is now mainatined in vnc_openstack/__init__.py ResourceApiDriver and there is an assumption that mapping can never be missed. This assumption is
incorrect in following two situations.
a. upgrade from R2.0 to R2.21 where subnets in R2.0 are created via vnc-api and never 'neutron subnet_show'd
b. any case where ResourceApiDriver has issue in creating these entries.

As a solution, it would be better to have a fail-safe mechanism in neutron_plugin_db.py to walk and heal such id to key inconsistencies (however do it for all missing entries since the operation is expensive).

1. https://github.com/Juniper/contrail-controller/commit/8ff6b7598f8e5bbf88794d2222e8f2a9fd132f8e

Hampapur Ajay (hajay)
Changed in juniperopenstack:
milestone: none → r3.0-fcs
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/14739
Submitter: Hampapur Ajay (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/14739
Committed: http://github.org/Juniper/contrail-controller/commit/7fb6cc22004039b8a402abb715f06bcdcc377aa1
Submitter: Zuul
Branch: master

commit 7fb6cc22004039b8a402abb715f06bcdcc377aa1
Author: Hampapur Ajay <email address hidden>
Date: Fri Oct 30 14:39:20 2015 -0700

Resolve subnet-id to subnet-key inconsistency from ipam_subnet

On encountering a missing subnet-id to subnet-key mapping in
useragent table, seek to resolve all such entries by walking the
net/ipam/subnet chain from contrail db. Also entire subnet list
shouldn't error out because of any missing subnet id to key mapping.

Change-Id: Ice615358fd01ede373edf882643aa0a6b0eaf2c2
Closes-Bug: #1511864

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R2.20

Review in progress for https://review.opencontrail.org/14819
Submitter: Hampapur Ajay (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R2.21.x

Review in progress for https://review.opencontrail.org/14820
Submitter: Hampapur Ajay (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/14820
Committed: http://github.org/Juniper/contrail-controller/commit/bdc48e2568b1241b87f30f28e44f41011bd3e484
Submitter: Zuul
Branch: R2.21.x

commit bdc48e2568b1241b87f30f28e44f41011bd3e484
Author: Hampapur Ajay <email address hidden>
Date: Fri Oct 30 14:39:20 2015 -0700

Resolve subnet-id to subnet-key inconsistency from ipam_subnet

On encountering a missing subnet-id to subnet-key mapping in
useragent table, seek to resolve all such entries by walking the
net/ipam/subnet chain from contrail db. Also entire subnet list
shouldn't error out because of any missing subnet id to key mapping.

Change-Id: Ice615358fd01ede373edf882643aa0a6b0eaf2c2
Closes-Bug: #1511864
(cherry picked from commit 7fb6cc22004039b8a402abb715f06bcdcc377aa1)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Reviewed: https://review.opencontrail.org/14819
Committed: http://github.org/Juniper/contrail-controller/commit/8f5fe0525c4cb92ef50a21ba294d3a25c1d24d67
Submitter: Zuul
Branch: R2.20

commit 8f5fe0525c4cb92ef50a21ba294d3a25c1d24d67
Author: Hampapur Ajay <email address hidden>
Date: Fri Oct 30 14:39:20 2015 -0700

Resolve subnet-id to subnet-key inconsistency from ipam_subnet

On encountering a missing subnet-id to subnet-key mapping in
useragent table, seek to resolve all such entries by walking the
net/ipam/subnet chain from contrail db. Also entire subnet list
shouldn't error out because of any missing subnet id to key mapping.

Change-Id: Ice615358fd01ede373edf882643aa0a6b0eaf2c2
Closes-Bug: #1511864
(cherry picked from commit 7fb6cc22004039b8a402abb715f06bcdcc377aa1)

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.