Using a non-default GW IP should set the allocation pool also accordingly

Bug #1349448 reported by Vedamurthy Joshi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
New
Low
Atul Moghe
R1.1
Won't Fix
Low
Sachin Bansal
R3.0
New
Low
Atul Moghe

Bug Description

Build 1.10 2273

If a non-default GW IP is picked in the subnet, the allocation pool also should be set accordingly.
Ex: It should be 60.1.1.1 to 60.1.1.9 and 60.1.1.11 to 60.1.1.254 .

root@nodec22:/usr/lib/python2.7/dist-packages/neutronclient# neutron subnet-create vn2 60.1.1.0/24 --gateway-ip 60.1.1.10
Created a new subnet:
+------------------+---------------------------------------------------+
| Field | Value |
+------------------+---------------------------------------------------+
| allocation_pools | {"last_ip": "60.1.1.254", "first_ip": "60.1.1.1"} |
| cidr | 60.1.1.0/24 |
| dns_nameservers | |
| enable_dhcp | True |
| gateway_ip | 60.1.1.10 |
| id | dd930605-ac73-45e4-89e3-2daaeb229f02 |
| ip_version | 4 |
| name | |
| network_id | d12a1c0a-1158-4ace-961c-c30de6c50644 |
| tenant_id | c579a77385914ecfb6698515d3c5c3cf |
+------------------+---------------------------------------------------+
root@nodec22:/usr/lib/python2.7/dist-packages/neutronclient#

Revision history for this message
Sachin Bansal (sbansal) wrote :

Is that how it behaves in stock devstack? I dont' see this requirement in documentation.

Revision history for this message
Vedamurthy Joshi (vedujoshi) wrote :

Pls see below with openstack running with openvswitch :

curl -i http://10.204.217.83:9696/v2.0/subnets.json -X POST -H "X-Auth-Token: <token>" -H "Conten
t-Type: application/json" -H "Accept: application/json" -H "User-Agent: python-neutronclient" -d '{"subnet": {"network_id": "02b7d689-ea66-4d7b-9373-658f
10ad1012", "ip_version": 4, "cidr": "20.1.1.0/24", "gateway_ip": "20.1.1.10"}}'

DEBUG: neutronclient.client RESP:{'date': 'Mon, 28 Jul 2014 14:28:38 GMT', 'status': '201', 'content-length': '412', 'content-type': 'application/json; c
harset=UTF-8'} {"subnet": {"name": "", "enable_dhcp": true, "network_id": "02b7d689-ea66-4d7b-9373-658f10ad1012", "tenant_id": "3136f090ef9c493e9c70184ce678482c", "dns_nameservers": [], "allocation_pools": [{"start": "20.1.1.1", "end": "20.1.1.9"}, {"start": "20.1.1.11", "end": "20.1.1.254"}], "host_routes": [], "ip_version": 4, "gateway_ip": "20.1.1.10", "cidr": "20.1.1.0/24", "id": "620ae687-fd94-4f6c-af0c-d52177d9e7b7"}}

Created a new subnet:
+------------------+---------------------------------------------+
| Field | Value |
+------------------+---------------------------------------------+
| allocation_pools | {"start": "20.1.1.1", "end": "20.1.1.9"} |
| | {"start": "20.1.1.11", "end": "20.1.1.254"} |
| cidr | 20.1.1.0/24 |
| dns_nameservers | |
| enable_dhcp | True |
| gateway_ip | 20.1.1.10 |
| host_routes | |
| id | 620ae687-fd94-4f6c-af0c-d52177d9e7b7 |
| ip_version | 4 |
| name | |
| network_id | 02b7d689-ea66-4d7b-9373-658f10ad1012 |
| tenant_id | 3136f090ef9c493e9c70184ce678482c |
+------------------+---------------------------------------------+
root@nodec43:~#

Sachin Bansal (sbansal)
Changed in juniperopenstack:
assignee: Sachin Bansal (bansalsachin) → Atul Moghe (moghea)
Revision history for this message
Raj Reddy (rajreddy) wrote :

we can release note this and take it up if/when need arises.

tags: added: neutronapi
Revision history for this message
Ashish Ranjan (aranjan-n) wrote :

We have decided not to work on it for 1.10 release

Changed in juniperopenstack:
importance: Medium → Low
tags: added: releasenote
Revision history for this message
Nagabhushana R (bhushana) wrote :

no plan to fix in 1.1, marked accordingly

Changed in juniperopenstack:
milestone: r1.10-beta → none
Changed in juniperopenstack:
assignee: Atul Moghe (moghea) → Sachin Bansal (sbansal)
tags: removed: releasenote
Sachin Bansal (sbansal)
Changed in juniperopenstack:
assignee: Sachin Bansal (sbansal) → Atul Moghe (moghea)
Revision history for this message
Atul Moghe (moghea) wrote :

I think it is open for interpretation in understanding allocation-pool. Neutron does not impose any such requirement and if we do this way for gw_ip, what will do if dns_nameservers[] are within the pool, for multiple such reserved entries within single allocation-pool, are we going to slice alloc-pool to number of allocation-pools to display. IMO, we should continue to display as user has configured

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.