yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #48058
[Bug 1531363] Re: internal server error returned when set gateway of router with an octal ip address
@hgangwx- As mentioned earlier, the issue mentioned in the bug is solved with https://review.openstack.org/#/c/255217/
The bug gave an example of the case where we add router-gateway port and mention the fixed IP explicitly ( leading to possibility of octal IP address notation). This issue has been addressed.
[stack@rhel7-devstack-ovn-153 ~]$ neutron net-show external
+-----------------+--------------------------------------+
| Field | Value |
+-----------------+--------------------------------------+
| admin_state_up | True |
| id | d7a80d1b-7f92-4d35-8372-9e8b36741217 |
| name | external |
| router:external | True |
| shared | False |
| status | ACTIVE |
| subnets | 1723f860-7c16-46c0-a18b-cc119e18a0fc |
| tenant_id | 6d7e5317ac2743259ce662af255e662b |
+-----------------+--------------------------------------+
[stack@rhel7-devstack-ovn-153 ~]$ neutron router-gateway-set --fixed-ip subnet_id=1723f860-7c16-46c0-a18b-cc119e18a0fc,ip_address=110.0.0.012 test external
Invalid input for external_gateway_info. Reason: '110.0.0.012' is not an accepted IP address, '110.0.0.12' is recommended.
In the bug you mentioned INTERNAL SERVER ERROR. With the patch we get an
Error message saying Invalid IP address.
When you rectify IP, it works.
[stack@rhel7-devstack-ovn-153 ~]$ neutron router-gateway-set --fixed-ip subnet_id=1723f860-7c16-46c0-a18b-cc119e18a0fc,ip_address=110.0.0.12 test external
Set gateway for router test
** Changed in: neutron
Status: New => 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/1531363
Title:
internal server error returned when set gateway of router with an
octal ip address
Status in neutron:
Fix Released
Bug description:
[Summary]
internal server error returned when set gateway of router with an octal ip address
[Topo]
devstack all-in-one node
[Description and expect result]
no error returned when set gateway of router with an octal ip address
[Reproduceable or not]
reproduceable
[Recreate Steps]
1) create a router:
root@45-59:/opt/stack/devstack# neutron router-create router100
Created a new router:
+-------------------------+--------------------------------------+
| Field | Value |
+-------------------------+--------------------------------------+
| admin_state_up | True |
| availability_zone_hints | |
| availability_zones | |
| distributed | False |
| external_gateway_info | |
| ha | False |
| id | ab35ac7b-dc5f-4ec4-b3a3-26f90ecd9fd7 |
| name | router100 |
| routes | |
| status | ACTIVE |
| tenant_id | 72a70635fa0c42a2bcba67edd760d516 |
+-------------------------+--------------------------------------+
2)internal server error returned when set gateway of router
with an octal ip address:
root@45-59:/opt/stack/devstack# neutron router-gateway-set --fixed-ip subnet_id=
015bc64c-ab58-41a1-a296-b58198cffacc,ip_address=172.168.0.011 router100 ext-net
Request Failed: internal server error while processing your request. >>>>ISSUE
root@45-59:/opt/stack/devstack#
Note: the ip address 172.168.0.011 may be interpreted as octal address since
there is a leading "0" in the address
3) if there is no leading "0" in the address, it's ok:
root@45-59:/opt/stack/devstack#
root@45-59:/opt/stack/devstack# neutron router-gateway-set --fixed-ip
subnet_id=015bc64c-ab58-41a1-a296-b58198cffacc,ip_address=172.168.0.11 router100 ext-net
Set gateway for router router100
root@45-59:/opt/stack/devstack# neutron router-show router100
+-------------------------+-------------------------------------------------------------------------------
--------------------------------------------------------------------------------
| Field | Value
|
+-------------------------+-------------------------------------------------------------------------------
--------------------------------------------------------------------------------
| admin_state_up | True
|
| availability_zone_hints |
|
| availability_zones | nova
|
| distributed | False
|
| external_gateway_info | {"network_id": "1fd330fa-e2f3-40a0-b6fc-5c1caa4981c8"
, "enable_snat": true, "external_fixed_ips": [{"subnet_id": "015bc64c-ab58-41a1
-a296-b58198cffacc", "ip_address": "172.168.0.11"}]} |
| ha | False
|
| id | ab35ac7b-dc5f-4ec4-b3a3-26f90ecd9fd7
|
| name | router100
|
| routes |
|
| status | ACTIVE
|
| tenant_id | 72a70635fa0c42a2bcba67edd760d516
|
+-------------------------+-------------------------------------------------------------------------------
-----------------------------------------------------------------------------
[Configration]
reproduceable bug, no need
[logs]
reproduceable bug, no need
[Root cause anlyze or debug inf]
reproduceable bug
[Attachment]
None
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1531363/+subscriptions