← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1865138] Related fix merged to neutron (master)

 

Reviewed:  https://review.opendev.org/710546
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=3d3dc60408148cf16bc19cccb76b8652f980fa1c
Submitter: Zuul
Branch:    master

commit 3d3dc60408148cf16bc19cccb76b8652f980fa1c
Author: Harald Jensås <hjensas@xxxxxxxxxx>
Date:   Fri Feb 28 03:09:05 2020 +0100

    subnet create - segment aware auto-addr allocation
    
    When creating additional subnets with ipv6 auto-addressing
    ip allocation was added to existing ports without filtering
    on current allocation's segment.
    
    This adds fitering to only add auto-address allocation when
    the new subnet is on the same segment as the ports current
    ipam allocations.
    
    Related: rhbz#1803989
    Related-Bug: #1864225
    Related-Bug: #1865138
    Closes-Bug: #1864333
    Change-Id: I75ae14c64db076434ca9897ba9a6d97702e233ad


** Changed in: neutron
       Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1865138

Title:
  When deleting an stateless subnet port can get allocation on subnet
  with invalid segment

Status in neutron:
  Fix Released

Bug description:
  A provider network with 3 stateless subnet, on different segments.
  (NOTE, this output is from a dev environment with WIP fixes for bug/1864333 and bug/1864333)

  $ for subnet in $(openstack subnet list --network providernet -f value -c ID); do openstack subnet show $subnet -f yaml -c segment_id -c cidr -c id; done
  cidr: deaf:beef:3::/64
  id: 954a1b8c-5fe7-4dcc-84bd-df24c371e651
  segment_id: 632b2bab-5402-4a4d-9433-783d7051d8aa
  cidr: deaf:beef:1::/64
  id: ebae0025-a701-4b22-aa66-00ec48025b30
  segment_id: d1930254-36c9-4490-94f7-d095a25cf3b0
  cidr: deaf:beef:2::/64
  id: ec2a9675-a286-4c8b-983d-2f762939cb5b
  segment_id: 1586a525-e250-4003-bae4-819e18e70c0e

  $ openstack port list --network providernet -f yaml -c "Fixed IP Addresses"
  - Fixed IP Addresses:
    - ip_address: deaf:beef:2:0:f816:3eff:fe03:eb71
      subnet_id: ec2a9675-a286-4c8b-983d-2f762939cb5b
  - Fixed IP Addresses:
    - ip_address: deaf:beef:3:0:f816:3eff:fe48:bb26
      subnet_id: c052289a-f8a0-464b-9413-717628fca4c2
  - Fixed IP Addresses:
    - ip_address: deaf:beef:1:0:f816:3eff:fea1:1aab
      subnet_id: ebae0025-a701-4b22-aa66-00ec48025b30
  - Fixed IP Addresses: []  <-- Deffered allocation

  $ openstack subnet delete subnet3

  After deleting subnet3, the port who was on this subnet get's an
  allocation on  subnet_id: ebae0025-a701-4b22-aa66-00ec48025b30 which
  is not the correct segment for this host.

  $ openstack port list --network providernet -f yaml -c "Fixed IP Addresses"
  - Fixed IP Addresses:
    - ip_address: deaf:beef:2:0:f816:3eff:fe03:eb71
      subnet_id: ec2a9675-a286-4c8b-983d-2f762939cb5b
  - Fixed IP Addresses:
    - ip_address: deaf:beef:1:0:f816:3eff:fe48:bb26   <-- Allocation on invalid segment.
      subnet_id: ebae0025-a701-4b22-aa66-00ec48025b30
  - Fixed IP Addresses:
    - ip_address: deaf:beef:1:0:f816:3eff:fea1:1aab
      subnet_id: ebae0025-a701-4b22-aa66-00ec48025b30
  - Fixed IP Addresses: []

  
  I belive the correct behaviour here would be to remove the allocation from the deleted segment and set allocaton 'deferred' on the port. Or raise SubnetInUse exception on subnet delete because there is no other auto-address subnet that can satisfy the in-use port.

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1865138/+subscriptions


References