undercloud install error "invalid IPNetwork undercloud.rdocloud" when undercloud_public_host set to hostname

Bug #1798829 reported by James Slagle
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
tripleo
Incomplete
High
Unassigned

Bug Description

In my undercloud.conf, I have undercloud_public_host set to a hostname, as that was always supported with instack-undercloud so that you could bind public SSL services to a hostname during undercloud install, and generate the cert with a hostname CN subject.

Now however with tripleoclient, that seems to fail:

      "+ os-net-config -c /etc/os-net-config/config.json -v --detailed-exit-codes",
      "[2018/10/19 01:47:44 PM] [INFO] Using config file at: /etc/os-net-config/config.json",
      "[2018/10/19 01:47:44 PM] [INFO] Ifcfg net config provider created.",
      "[2018/10/19 01:47:44 PM] [INFO] Not using any mapping file.",
      "[2018/10/19 01:47:44 PM] [WARNING] Config file failed schema validation at network_config/0:",
      " {'persist_mapping': False, 'nic_mapping': None, 'ovs_extra': ['br-set-external-id br-ctlplane bridge-id br-ctlplane'], 'addresses': [{'ip_netmask': 'undercloud.rdocloud'}], 'name': 'br-ctlplane', 'type': 'ovs_bridge', 'mtu': 1500} is not valid under any of the given schemas",
      " Sub-schemas tested and not matching:",
      " - items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf: 'undercloud.rdocloud' is not valid under any of the given schemas",
      " -- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/ip_cidr_string/oneOf: 'undercloud.rdocloud' is not valid under any of the given schemas",
      " --- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/ip_cidr_string/oneOf/ipv4_cidr_string/pattern: 'undercloud.rdocloud' does not match '^((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?).){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)/(3[0-2]|[1-2][0-9]|[0-9])$'",
      " --- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/ip_cidr_string/oneOf/ipv6_cidr_string/pattern: 'undercloud.rdocloud' does not match '^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,
4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))/(12[0-8]|1[0-1][0-9]|[1-9][0-9]|[0-9])$'",
      " -- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/param/oneOf: 'undercloud.rdocloud' is not valid under any of the given schemas",
      " --- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/param/oneOf/0/type: 'undercloud.rdocloud' is not of type 'object'",
      " --- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/param/oneOf/1/type: 'undercloud.rdocloud' is not of type 'object'",
      " -- items/oneOf/ovs_bridge/addresses/items/ip_netmask/oneOf/2/type: 'undercloud.rdocloud' is not of type 'object'",
      " - items/oneOf/ovs_bridge/required: 'members' is a required property",
      "Traceback (most recent call last):",
      " File \"/bin/os-net-config\", line 10, in <module>",
      " sys.exit(main())",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/cli.py\", line 259, in main",
      " obj = objects.object_from_json(iface_json)",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/objects.py\", line 47, in object_from_json",
      " return OvsBridge.from_json(json)",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/objects.py\", line 577, in from_json",
      " json, include_primary=False)",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/objects.py\", line 364, in base_opts_from_json",
      " addresses.append(Address.from_json(address))",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/objects.py\", line 269, in from_json",
      " return Address(ip_netmask)",
      " File \"/usr/lib/python2.7/site-packages/os_net_config/objects.py\", line 260, in __init__",
      " ip_nw = netaddr.IPNetwork(self.ip_netmask)",
      " File \"/usr/lib/python2.7/site-packages/netaddr/ip/__init__.py\", line 938, in __init__",
      " raise AddrFormatError('invalid IPNetwork %s' % addr)",
      "netaddr.core.AddrFormatError: invalid IPNetwork undercloud.rdocloud",
      "+ RETVAL=1",
      "+ set -e",
      "+ [[ 1 == 2 ]]",
      "+ [[ 1 != 0 ]]",
      "+ echo 'ERROR: os-net-config configuration failed.'",
      "ERROR: os-net-config configuration failed.",

my undercloud.conf:

[DEFAULT]
local_ip=192.168.0.21/24
undercloud_public_host=undercloud.rdocloud
generate_service_certificate = true
hieradata_override = hieradata-override.yaml
net_config_override = net-config-override.json

[ctlplane-subnet]

#
# From undercloud_config
#

# Network CIDR for the Neutron-managed subnet for Overcloud instances.
# (string value)
# Deprecated group/name - [DEFAULT]/network_cidr
cidr = 192.168.0.0/24

# End of DHCP allocation range for PXE and DHCP of Overcloud instances
# on this network. (string value)
# Deprecated group/name - [DEFAULT]/dhcp_end
dhcp_end = 192.168.0.24

# Start of DHCP allocation range for PXE and DHCP of Overcloud
# instances on this network. (string value)
# Deprecated group/name - [DEFAULT]/dhcp_start
dhcp_start = 192.168.0.5

# Network gateway for the Neutron-managed network for Overcloud
# instances on this network. (string value)
# Deprecated group/name - [DEFAULT]/network_gateway
gateway = 192.168.0.1

# Temporary IP range that will be given to nodes on this network
# during the inspection process. Should not overlap with the range
# defined by dhcp_start and dhcp_end, but should be in the same ip
# subnet. (string value)
# Deprecated group/name - [DEFAULT]/inspection_iprange
inspection_iprange = 192.168.0.100,192.168.0.120

# The network will be masqueraded for external access. (boolean value)
#masquerade = false

the generated /etc/os-net-config/config.json:

[centos@undercloud ~]$ cat /etc/os-net-config/config.json
{"network_config": [{"addresses": [{"ip_netmask": "undercloud.rdocloud"}], "mtu": 1500, "name": "br-ctlplane", "ovs_extra": ["br-set-external-id br-ctlplane bridge-id br-ctlplane"], "type": "ovs_bridge"}]}

Changed in tripleo:
status: New → Triaged
importance: Undecided → High
milestone: none → stein-1
Changed in tripleo:
milestone: stein-1 → stein-2
Revision history for this message
Dan Trainor (dtrainor) wrote :
Changed in tripleo:
milestone: stein-2 → stein-3
Changed in tripleo:
milestone: stein-3 → stein-rc1
Changed in tripleo:
milestone: stein-rc1 → train-1
Changed in tripleo:
milestone: train-1 → train-2
Changed in tripleo:
milestone: train-2 → train-3
Revision history for this message
Trevor Vardeman (tvardeman) wrote :

I did an undercloud deployment earlier with the following options:
local_ip=192.168.0.21/24
undercloud_public_host=undercloud.rdocloud

My installation made it past the network setup. Full disclosure, it failed on ansible setup, but that isn't related. I think this bug can be closed.

Changed in tripleo:
milestone: train-3 → ussuri-1
Changed in tripleo:
milestone: ussuri-1 → ussuri-2
wes hayutin (weshayutin)
Changed in tripleo:
milestone: ussuri-2 → ussuri-3
wes hayutin (weshayutin)
Changed in tripleo:
status: Triaged → Incomplete
wes hayutin (weshayutin)
Changed in tripleo:
milestone: ussuri-3 → ussuri-rc3
wes hayutin (weshayutin)
Changed in tripleo:
milestone: ussuri-rc3 → victoria-1
Changed in tripleo:
milestone: victoria-1 → victoria-3
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.