Prior to this update, certain options were unavailable in the neutron client, although they were available in neutron server `PUT` operations.
Consequently, it was not possible to clear the defined gateway by using the `--no-gateway` option with the `subnet-update` neutron client command.
This update adds the ability to update the attributes which are allowed in a `PUT` operation.
As a result, it is possible to clear the defined gateway with `neutron subnet-update --no-gateway UUID`.
DescriptionPratik Pravin Bandarkar
2016-07-04 08:21:05 UTC
Description of problem:
We can create subnet without specifying gateway.
[root@rhos8 ~(keystone_admin)]# neutron subnet-create internal --no-gateway 10.10.10.0/24
Created a new subnet:
+-------------------+------------------------------------------------+
| Field | Value |
+-------------------+------------------------------------------------+
| allocation_pools | {"start": "10.10.10.1", "end": "10.10.10.254"} |
| cidr | 10.10.10.0/24 |
| dns_nameservers | |
| enable_dhcp | True |
| gateway_ip | | <=======
| host_routes | |
| id | 1dc144d1-b9a8-4259-bd01-56799eb0badf |
| ip_version | 4 |
| ipv6_address_mode | |
| ipv6_ra_mode | |
| name | |
| network_id | 2288ad3f-963a-4eec-8680-c6c2e93f0910 |
| subnetpool_id | |
| tenant_id | ea39022238084e03a02441451dbb0466 |
+-------------------+------------------------------------------------+
But, for existing subnets, we don't have --no-gateway equivalent option to set the gateway to null.
[root@rhos8 ~(keystone_admin)]# neutron subnet-show -F gateway_ip fd284aef-e6da-4bb3-b4df-d78bcabadc5c
+------------+-------------+
| Field | Value |
+------------+-------------+
| gateway_ip | 192.168.1.1 | <== we cant clear this field of existing network.
+------------+-------------+
Version-Release number of selected component (if applicable):
RHOS5,6,7,8
How reproducible:
100%
Steps to Reproduce:
1.create subnet with specifying gateway.
2.try to clear the gateway
3.
Actual results:
unable to clear gateway of existing subnets
Expected results:
There should be someway to clear gateway of existing subnets.
Additional info:
This is on master:
neutron subnet-show tmp -F gateway_ip --format=value
10.0.0.1
neutron subnet-update --no-gateway tmp
Updated subnet: tmp
neutron subnet-show tmp -F gateway_ip --format=value
<blank>
Can you please check this on OSP 8?
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://rhn.redhat.com/errata/RHBA-2016-2020.html
Description of problem: We can create subnet without specifying gateway. [root@rhos8 ~(keystone_admin)]# neutron subnet-create internal --no-gateway 10.10.10.0/24 Created a new subnet: +-------------------+------------------------------------------------+ | Field | Value | +-------------------+------------------------------------------------+ | allocation_pools | {"start": "10.10.10.1", "end": "10.10.10.254"} | | cidr | 10.10.10.0/24 | | dns_nameservers | | | enable_dhcp | True | | gateway_ip | | <======= | host_routes | | | id | 1dc144d1-b9a8-4259-bd01-56799eb0badf | | ip_version | 4 | | ipv6_address_mode | | | ipv6_ra_mode | | | name | | | network_id | 2288ad3f-963a-4eec-8680-c6c2e93f0910 | | subnetpool_id | | | tenant_id | ea39022238084e03a02441451dbb0466 | +-------------------+------------------------------------------------+ But, for existing subnets, we don't have --no-gateway equivalent option to set the gateway to null. [root@rhos8 ~(keystone_admin)]# neutron subnet-show -F gateway_ip fd284aef-e6da-4bb3-b4df-d78bcabadc5c +------------+-------------+ | Field | Value | +------------+-------------+ | gateway_ip | 192.168.1.1 | <== we cant clear this field of existing network. +------------+-------------+ Version-Release number of selected component (if applicable): RHOS5,6,7,8 How reproducible: 100% Steps to Reproduce: 1.create subnet with specifying gateway. 2.try to clear the gateway 3. Actual results: unable to clear gateway of existing subnets Expected results: There should be someway to clear gateway of existing subnets. Additional info: