Bug 1712510 - Undercloud deployment fails with "Invalid input for host_routes. Reason: \\\\\\'10.10.10.0\\\\\\' is not a recognized CIDR, \\\\\\'10. 10.10.0/32\\\\\\' is recommended."
Summary: Undercloud deployment fails with "Invalid input for host_routes. Reason: \\\\...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: python-tripleoclient
Version: 15.0 (Stein)
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: beta
: 15.0 (Stein)
Assignee: Harald Jensås
QA Contact: Alistair Tonner
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-05-21 16:31 UTC by Alexander Chuzhoy
Modified: 2019-09-26 10:51 UTC (History)
10 users (show)

Fixed In Version: python-tripleoclient-11.4.1-0.20190611084233.f36d899.el8ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-09-21 11:22:28 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
install-undercloud.log (88.97 KB, application/gzip)
2019-05-21 16:34 UTC, Alexander Chuzhoy
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1830093 0 None None None 2019-05-22 17:08:55 UTC
OpenStack gerrit 661261 0 None None None 2019-05-24 11:54:27 UTC
Red Hat Product Errata RHEA-2019:2811 0 None None None 2019-09-21 11:22:48 UTC

Description Alexander Chuzhoy 2019-05-21 16:31:38 UTC
Undercloud deployment fails with "Invalid input for host_routes. Reason: \\\\\\'10.10.10.0\\\\\\' is not a recognized CIDR, \\\\\\'10. 10.10.0/32\\\\\\' is recommended."

Environment:

python3-tripleoclient-11.4.1-0.20190520170357.a55573f.el8ost.noarch

(undercloud) [stack@undercloud ~]$ sudo ip r
default via 10.8.120.254 dev eth0 proto dhcp metric 100 
10.8.120.0/24 dev eth0 proto kernel scope link src 10.8.120.9 metric 100 
169.254.0.0/16 dev eth1 scope link metric 1003 
169.254.0.0/16 dev br-ctlplane scope link metric 1005 
192.168.0.0/24 dev br-ctlplane proto kernel scope link src 192.168.0.1 


(undercloud) [stack@undercloud ~]$ sudo ip -4 -o a
1: lo    inet 127.0.0.1/8 scope host lo\       valid_lft forever preferred_lft forever
2: eth0    inet 10.8.120.9/24 brd 10.8.120.255 scope global dynamic noprefixroute eth0\       valid_lft 80492sec preferred_lft 80492sec
5: br-ctlplane    inet 192.168.0.1/24 brd 192.168.0.255 scope global br-ctlplane\       valid_lft forever preferred_lft forever
5: br-ctlplane    inet 192.168.0.3/32 scope global br-ctlplane\       valid_lft forever preferred_lft forever
5: br-ctlplane    inet 192.168.0.2/32 scope global br-ctlplane\       valid_lft forever preferred_lft forever



Steps to reproduce:

Attempt to deploy undercloud with:

[ctlplane-subnet]
host_routes = [{destination: 10.10.10.0, nexthop: 192.168.0.1}]



Result:

The undercloud deployment fails with:
BadRequestException: 400: Client Error for url: https://192.168.0.2:13696/v2.0/subnets, Invalid input for host_routes. Reason: \\\\\\'10.10.10.0\\\\\\' is not a recognized CIDR, \\\\\\'10.
10.10.0/32\\\\\\' is recommended.\\\\n\\'\\n[2019-05-21 18:37:48,330] (heat-config) [ERROR] Error running /var/lib/heat-config/heat-config-script/76c4f6a2-f668-4c4e-b270-c2588b8b17a2. [1]\\n
\\n'",

Comment 1 Alexander Chuzhoy 2019-05-21 16:34:03 UTC
Created attachment 1571706 [details]
install-undercloud.log

Comment 2 Alexander Chuzhoy 2019-05-21 16:34:28 UTC
commenting out this line results in successful deployment.

Comment 3 Harald Jensås 2019-05-22 09:18:59 UTC
When specifying a route you need to specify a ip network with a subnet prefix.

I.e 10.10.10.0/24 where 10.10.10.0 is the network address and /24 is the subnet prefix.

Your undercloud.conf need to look like:

[ctlplane-subnet]
host_routes = [{destination: 10.10.10.0/24, nexthop: 192.168.0.1}]



Btw, I opened a bug upstream to add a pre-flight validation: https://bugs.launchpad.net/tripleo/+bug/1830005

Comment 4 Alexander Chuzhoy 2019-05-22 13:07:27 UTC
/usr/share/python-tripleoclient/undercloud.conf.sample needs to be updated accordingly.
The issue came when I merely uncommented the example line from that file.

Comment 5 Harald Jensås 2019-05-22 17:08:55 UTC
ah, ok. So the sample is incorrect:
https://github.com/openstack/python-tripleoclient/blob/master/tripleoclient/config/undercloud.py#L389

  sample_default=('[{destination: 10.10.10.0, '
                  'nexthop: 192.168.24.1}]'),

https://bugs.launchpad.net/tripleo/+bug/1830093

Comment 9 Alistair Tonner 2019-07-17 21:28:52 UTC
core puddle: RHOS_TRUNK-15.0-RHEL-8-20190716.n.0

python3-tripleoclient.noarch                      11.4.1-0.20190705110410.14ae053.el8ost                   @rhelosp-15.0-trunk
python3-tripleoclient-heat-installer.noarch       11.4.1-0.20190705110410.14ae053.el8ost                   @rhelosp-15.0-trunk


  Sample file is corrected -

Comment 11 errata-xmlrpc 2019-09-21 11:22:28 UTC
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://access.redhat.com/errata/RHEA-2019:2811


Note You need to log in before you can comment on or make changes to this bug.