← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1518819] [NEW] Can't specify gateway when creating subnet with subnetpool

 

Public bug reported:

When creating a subnet by using the subnetpool(without specifying cidr), I can't specify the gateway. Either using --no-gateway or --gateway, the newly created subnet will have the first ip in the pool as the the gateway ip.
Looks like the code don't consider gateway ip at [1], and always set the first ip in pool as gateway ip in [2].

I fount this when creating an external network, which don't have a
gateway indeed. The unnecessary gateway ip will create meaningless
default route in router.

[1] https://github.com/openstack/neutron/blob/master/neutron/ipam/requests.py#L290
[2] https://github.com/openstack/neutron/blob/master/neutron/ipam/subnet_alloc.py#L126

** Affects: neutron
     Importance: Undecided
     Assignee: Hong Hui Xiao (xiaohhui)
         Status: New

** Changed in: neutron
     Assignee: (unassigned) => Hong Hui Xiao (xiaohhui)

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

Title:
  Can't specify gateway when creating subnet with subnetpool

Status in neutron:
  New

Bug description:
  When creating a subnet by using the subnetpool(without specifying cidr), I can't specify the gateway. Either using --no-gateway or --gateway, the newly created subnet will have the first ip in the pool as the the gateway ip.
  Looks like the code don't consider gateway ip at [1], and always set the first ip in pool as gateway ip in [2].

  I fount this when creating an external network, which don't have a
  gateway indeed. The unnecessary gateway ip will create meaningless
  default route in router.

  [1] https://github.com/openstack/neutron/blob/master/neutron/ipam/requests.py#L290
  [2] https://github.com/openstack/neutron/blob/master/neutron/ipam/subnet_alloc.py#L126

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


Follow ups