Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1405929 - OvsBridge JSON objects require 'name' to be configured
OvsBridge JSON objects require 'name' to be configured
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-tripleo-heat-templates (Show other bugs)
10.0 (Newton)
All Linux
medium Severity medium
: ga
: 12.0 (Pike)
Assigned To: Dan Sneddon
Gurenko Alex
: Triaged
: 1409330 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-12-19 03:30 EST by VIKRANT
Modified: 2018-02-06 15:05 EST (History)
14 users (show)

See Also:
Fixed In Version: openstack-tripleo-heat-templates-7.0.0-0.20170821194253.el7ost
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-12-13 15:57:54 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Launchpad 1669130 None None None 2017-03-01 16:18 EST
OpenStack gerrit 439868 None None None 2017-03-01 19:15 EST
Red Hat Product Errata RHEA-2017:3462 normal SHIPPED_LIVE Red Hat OpenStack Platform 12.0 Enhancement Advisory 2018-02-15 20:43:25 EST

  None (edit)
Description VIKRANT 2016-12-19 03:30:24 EST
Description of problem:

I have seen deployment getting failed with following error in overcloud nodes. 

~~~
OvsBridge JSON objects require 'name' to be configured.
~~~

This was the error which I was getting in compute node during the deployment.

compute_1

~~~
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: + os-net-config -c /etc/os-net-config/dhcp_all_interfaces.yaml -v --detailed-exit-codes --cleanup
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] Using config file at: /etc/os-net-config/dhcp_all_interfaces.yaml
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] Using mapping file at: /etc/os-net-config/mapping.yaml
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] Ifcfg net config provider created.
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] nic2 mapped to: eth1
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] nic1 mapped to: eth0
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] adding interface: eth0
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] adding interface: eth1
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] applying network configs...
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] No changes required for interface: eth1
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016/12/19 03:47:13 AM] [INFO] No changes required for interface: eth0
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: + RETVAL=0
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: + [[ 0 == 2 ]]
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: + [[ 0 != 0 ]]
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016-12-19 03:47:13,736] (os-refresh-config) [ERROR] during configure phase. [Command '['dib-run-parts', '/usr/libexec/os-refresh-config/configure.d']' returned non-zero exit status 1]
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: [2016-12-19 03:47:13,736] (os-refresh-config) [ERROR] Aborting...
Dec 19 03:47:13 host-192-0-2-16 os-collect-config: Command failed, will not cache new data. Command 'os-refresh-config --timeout 14400' returned non-zero exit status 1
~~~

compute_2

~~~
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: + os-net-config -c /etc/os-net-config/dhcp_all_interfaces.yaml -v --detailed-exit-codes --cleanup
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] Using config file at: /etc/os-net-config/dhcp_all_interfaces.yaml
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] Using mapping file at: /etc/os-net-config/mapping.yaml
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] Ifcfg net config provider created.
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] nic3 mapped to: eth2
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] nic2 mapped to: eth1
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] nic1 mapped to: eth0
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] adding interface: eth0
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] adding interface: eth1
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] adding interface: eth2
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] applying network configs...
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] No changes required for interface: eth2
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] No changes required for interface: eth1
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016/12/19 03:48:45 AM] [INFO] No changes required for interface: eth0
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: + RETVAL=0
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: + [[ 0 == 2 ]]
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: + [[ 0 != 0 ]]
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016-12-19 03:48:45,327] (os-refresh-config) [ERROR] during configure phase. [Command '['dib-run-parts', '/usr/libexec/os-refresh-config/configure.d']' returned non-zero exit status 1]
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: [2016-12-19 03:48:45,327] (os-refresh-config) [ERROR] Aborting...
Dec 19 03:48:45 host-192-0-2-7 os-collect-config: Command failed, will not cache new data. Command 'os-refresh-config --timeout 14400' returned non-zero exit status 1
~~~

While running "/usr/libexec/os-refresh-config/configure.d" manually I noticed following error : 


~~~
[root@overcloud-compute-1-0 ~]# dib-run-parts /usr/libexec/os-refresh-config/configure.d
dib-run-parts Mon Dec 19 04:01:29 EST 2016 Running /usr/libexec/os-refresh-config/configure.d/20-os-apply-config
[2016/12/19 04:01:29 AM] [INFO] writing /etc/os-net-config/config.json
[2016/12/19 04:01:29 AM] [INFO] writing /var/run/heat-config/heat-config
[2016/12/19 04:01:29 AM] [INFO] writing /etc/puppet/hiera.yaml
[2016/12/19 04:01:29 AM] [INFO] writing /etc/os-collect-config.conf
[2016/12/19 04:01:29 AM] [INFO] success
dib-run-parts Mon Dec 19 04:01:29 EST 2016 20-os-apply-config completed
dib-run-parts Mon Dec 19 04:01:29 EST 2016 Running /usr/libexec/os-refresh-config/configure.d/20-os-net-config
++ os-apply-config --key os_net_config --type raw --key-default ''
+ NET_CONFIG='{"network_config": [{"dns_servers": [], "addresses": [{"ip_netmask": "192.0.2.16/24"}], "primary": true, "routes": [{"ip_netmask": "169.254.169.254/32", "next_hop": "192.0.2.1"}, {"default": true, "next_hop": "192.0.2.1"}], "use_dhcp": true, "type": "interface", "name": "nic1"}, {"type": "ovs_bridge", "name": null, "members": [{"type": "interface", "name": "nic2"}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 30}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 20}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 50}]}]}'
+ '[' -n '{"network_config": [{"dns_servers": [], "addresses": [{"ip_netmask": "192.0.2.16/24"}], "primary": true, "routes": [{"ip_netmask": "169.254.169.254/32", "next_hop": "192.0.2.1"}, {"default": true, "next_hop": "192.0.2.1"}], "use_dhcp": true, "type": "interface", "name": "nic1"}, {"type": "ovs_bridge", "name": null, "members": [{"type": "interface", "name": "nic2"}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 30}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 20}, {"type": "vlan", "addresses": [{"ip_netmask": "192.0.2.16/24"}], "vlan_id": 50}]}]}' ']'
+ trap configure_safe_defaults EXIT
+ os-net-config -c /etc/os-net-config/config.json -v --detailed-exit-codes
[2016/12/19 04:01:30 AM] [INFO] Using config file at: /etc/os-net-config/config.json
[2016/12/19 04:01:30 AM] [INFO] Using mapping file at: /etc/os-net-config/mapping.yaml
[2016/12/19 04:01:30 AM] [INFO] Ifcfg net config provider created.
[2016/12/19 04:01:30 AM] [INFO] nic2 mapped to: eth1
[2016/12/19 04:01:30 AM] [INFO] nic1 mapped to: eth0
[2016/12/19 04:01:30 AM] [INFO] adding interface: eth0
[2016/12/19 04:01:30 AM] [INFO] adding custom route for interface: eth0
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 184, in main
    obj = objects.object_from_json(iface_json)
  File "/usr/lib/python2.7/site-packages/os_net_config/objects.py", line 42, in object_from_json
    return OvsBridge.from_json(json)
  File "/usr/lib/python2.7/site-packages/os_net_config/objects.py", line 428, in from_json
    name = _get_required_field(json, 'name', 'OvsBridge')
  File "/usr/lib/python2.7/site-packages/os_net_config/objects.py", line 78, in _get_required_field
    raise InvalidConfigException(msg)
os_net_config.objects.InvalidConfigException: OvsBridge JSON objects require 'name' to be configured.
+ RETVAL=1
+ [[ 1 == 2 ]]
+ [[ 1 != 0 ]]
+ echo 'ERROR: os-net-config configuration failed.'
ERROR: os-net-config configuration failed.
+ exit 1
+ configure_safe_defaults
+ [[ 1 == 0 ]]
+ cat
++ ls /sys/class/net
++ grep -v '^lo$'
+ for iface in '$(ls /sys/class/net | grep -v ^lo$)'
++ cat /sys/class/net/eth0/addr_assign_type
+ local mac_addr_type=0
+ '[' 0 '!=' 0 ']'
+ ip link set dev eth0 up
++ cat /sys/class/net/eth0/carrier
+ HAS_LINK=1
+ TRIES=10
+ '[' 1 == 0 -a 10 -gt 0 ']'
+ '[' 1 == 1 ']'
+ cat
+ for iface in '$(ls /sys/class/net | grep -v ^lo$)'
++ cat /sys/class/net/eth1/addr_assign_type
+ local mac_addr_type=0
+ '[' 0 '!=' 0 ']'
+ ip link set dev eth1 up
++ cat /sys/class/net/eth1/carrier
+ HAS_LINK=1
+ TRIES=10
+ '[' 1 == 0 -a 10 -gt 0 ']'
+ '[' 1 == 1 ']'
+ cat
+ os-net-config -c /etc/os-net-config/dhcp_all_interfaces.yaml -v --detailed-exit-codes --cleanup
[2016/12/19 04:01:30 AM] [INFO] Using config file at: /etc/os-net-config/dhcp_all_interfaces.yaml
[2016/12/19 04:01:30 AM] [INFO] Using mapping file at: /etc/os-net-config/mapping.yaml
[2016/12/19 04:01:30 AM] [INFO] Ifcfg net config provider created.
[2016/12/19 04:01:30 AM] [INFO] nic2 mapped to: eth1
[2016/12/19 04:01:30 AM] [INFO] nic1 mapped to: eth0
[2016/12/19 04:01:30 AM] [INFO] adding interface: eth0
[2016/12/19 04:01:30 AM] [INFO] adding interface: eth1
[2016/12/19 04:01:30 AM] [INFO] applying network configs...
[2016/12/19 04:01:30 AM] [INFO] No changes required for interface: eth1
[2016/12/19 04:01:30 AM] [INFO] No changes required for interface: eth0
+ RETVAL=0
+ [[ 0 == 2 ]]
+ [[ 0 != 0 ]]
~~~


Version-Release number of selected component (if applicable):
RHEL OSP 10

How reproducible:
Everytime. 

Steps to Reproduce:
1. try to deploy the setup using following command : 

~~~
nohup  openstack overcloud deploy --templates -e /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml -e /home/stack/network-environment.yaml -r /home/stack/nic-configs/roles_data.yaml --libvirt-type qemu --ntp-server clock.redhat.com &
~~~

Templates are located at :

https://github.com/ervikrant06/OpenstackDirector/tree/master/compute_heter_deploy

2. Deployment is getting failed. 
3.

Actual results:
Deployment is getting failed. 


Expected results:
Deployment should get completed successfully

Additional info:

It was getting failed when the template was having :

~~~
            -
              type: ovs_bridge
              name: {get_input: bridge_name}
~~~

After specificially mentioning the bridge name, deployment is getting completed successfully.



~~~
            -
              type: ovs_bridge
              name: br-ex
              members:
~~~
Comment 1 Andreas Karis 2016-12-31 15:18:45 EST
This is due to the templates. This also means that we have another bug: controller bridge name is hardcoded to br-ex

[stack@undercloud-1 templates]$ grep NetworkDeployment: /usr/share/openstack-tripleo-heat-templates/* -R -C10
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      TenantIp: {get_attr: [TenantPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      ManagementIp: {get_attr: [ManagementPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      server: {get_resource: BlockStorage}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-  BlockStorageDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-    type: OS::Heat::StructuredDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml-    depends_on: NetworkDeployment
--
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      TenantIp: {get_attr: [TenantPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      ManagementIp: {get_attr: [ManagementPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      server: {get_resource: CephStorage}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-  CephStorageDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-    type: OS::Heat::StructuredDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml-    depends_on: NetworkDeployment
--
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-    type: OS::TripleO::Compute::Net::SoftwareConfig
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      ControlPlaneIp: {get_attr: [NovaCompute, networks, ctlplane, 0]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      server: {get_resource: NovaCompute}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-      input_values:
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-        bridge_name: {get_param: NeutronPhysicalBridge}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-        interface_name: {get_param: NeutronPublicInterface}
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml-
--
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-    type: OS::TripleO::Controller::Net::SoftwareConfig
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      ControlPlaneIp: {get_attr: [Controller, networks, ctlplane, 0]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      server: {get_resource: Controller}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-      input_values:
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-        bridge_name: br-ex
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-        interface_name: {get_param: NeutronPublicInterface}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml-
--
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      TenantIp: {get_attr: [TenantPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      ManagementIp: {get_attr: [ManagementPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      server: {get_resource: SwiftStorage}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-  SwiftStorageHieraConfig:
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-    type: OS::Heat::StructuredConfig
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml-    properties:
--
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      TenantIp: {get_attr: [TenantPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      ManagementIp: {get_attr: [ManagementPort, ip_address]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml:  NetworkDeployment:
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-    type: OS::TripleO::SoftwareDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-    properties:
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      name: NetworkDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      config: {get_resource: NetworkConfig}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      server: {get_resource: {{role}}}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-      actions: {get_param: NetworkDeploymentActions}
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-  {{role}}Deployment:
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-    type: OS::Heat::StructuredDeployment
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml-    depends_on: NetworkDeployment
Comment 2 Andreas Karis 2016-12-31 15:19:05 EST
*** Bug 1409330 has been marked as a duplicate of this bug. ***
Comment 3 Andreas Karis 2017-02-23 17:33:30 EST
Some clarification:

There are 2 issues:
a)
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml sets bridge_name always to br-ex

/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml:
~~~
(...)
  NetworkDeployment:
    type: OS::TripleO::SoftwareDeployment
    properties:
      name: NetworkDeployment
      config: {get_resource: NetworkConfig}
      server: {get_resource: Controller}
      actions: {get_param: NetworkDeploymentActions}
      input_values:
        bridge_name: br-ex
        interface_name: {get_param: NeutronPublicInterface}
(...)
~~~

if on the other hand we look at the compute role, this is correctly set as NeutronPhysicalBridge with default 'br-ex':
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml
~~~
(...)
  NeutronPhysicalBridge:
    default: 'br-ex'
    description: An OVS bridge to create for accessing external networks.
    type: string
(...)
  NetworkDeployment:
    type: OS::TripleO::SoftwareDeployment
    properties:
      name: NetworkDeployment
      config: {get_resource: NetworkConfig}
      server: {get_resource: NovaCompute}
      actions: {get_param: NetworkDeploymentActions}
      input_values:
        bridge_name: {get_param: NeutronPhysicalBridge}
        interface_name: {get_param: NeutronPublicInterface}
(...)
~~~
Comment 4 Andreas Karis 2017-02-23 17:38:17 EST
b) The second issue has to do with customer roles:
https://bugzilla.redhat.com/show_bug.cgi?id=1409330 outlines this more clearly.

The custom role jinja templates should pass bridge_name as an input value to the NetworkDeployment, but they don't:
[stack@undercloud-1 ~]$ grep bridge_name /usr/share/openstack-tripleo-heat-templates/* -R | grep -v config
/usr/share/openstack-tripleo-heat-templates/puppet/compute-role.yaml:        bridge_name: {get_param: NeutronPhysicalBridge}
/usr/share/openstack-tripleo-heat-templates/puppet/controller-role.yaml:        bridge_name: br-ex


Instead:
/usr/share/openstack-tripleo-heat-templates/puppet/role.role.j2.yaml
/usr/share/openstack-tripleo-heat-templates/puppet/objectstorage-role.yaml
/usr/share/openstack-tripleo-heat-templates/puppet/cephstorage-role.yaml
/usr/share/openstack-tripleo-heat-templates/puppet/blockstorage-role.yaml

all pass only the following, but *not* the bridge_name
NetworkDeployment:
    type: OS::TripleO::SoftwareDeployment
    properties:
      name: NetworkDeployment
      config: {get_resource: NetworkConfig}
      server: {get_resource: {{role}}}
      actions: {get_param: NetworkDeploymentActions}


And hence, network templates for swift / cinder / ceph nodes or for custom roles cannot use bridge_name as a parameter.
Comment 5 VIKRANT 2017-02-28 10:38:25 EST
Thanks Andreas for inputs.
Comment 6 Dan Sneddon 2017-03-01 17:03:41 EST
(In reply to Andreas Karis from comment #4)
> b) The second issue has to do with customer roles:
> https://bugzilla.redhat.com/show_bug.cgi?id=1409330 outlines this more
> clearly.
> [...]
> And hence, network templates for swift / cinder / ceph nodes or for custom
> roles cannot use bridge_name as a parameter.

This is expected. The swift/cinder/ceph roles do not use Neutron bridges, so if a bridge is required on those nodes, just use whatever name you prefer.

We may have to look into making sure that bridge_name is passed to the role when using a dedicated Neutron networker role.
Comment 7 Dan Sneddon 2017-03-01 19:18:59 EST
Posted review https://review.openstack.org/#/c/439868/ to add the NeutronPhysicalBridge parameter to the Controller role (so that it can be changed from "br-ex").

The other roles do not require a parameter that matches Neutron, so their bridge names are not parameterized. You may use "br-ex" or any other name directly in the NIC configs for the swift, ceph, cinder nodes.
Comment 8 Andreas Karis 2017-06-01 14:56:05 EDT
Sorry that my answer is coming a bit late...

"The other roles do not require a parameter that matches Neutron, so their bridge names are not parameterized. You may use "br-ex" or any other name directly in the NIC configs for the swift, ceph, cinder nodes."

I don't agree with that statement. What happens with custom controller and custom compute roles? The behavior will be inconsistent between the default roles and custom roles.
Comment 13 Bob Fournier 2017-07-21 10:24:39 EDT
>>Sorry that my answer is coming a bit late...

>>"The other roles do not require a parameter that matches Neutron, so their bridge >>names are not parameterized. You may use "br-ex" or any other name directly in the
>> NIC configs for the swift, ceph, cinder nodes."

>I don't agree with that statement. What happens with custom controller and custom >compute roles? The behavior will be inconsistent between the default roles and >custom roles.

Hi Andreas - Dan's fix https://review.openstack.org/#/c/439868/ added the NeutronPhysicalBridge to role.role.j2.yaml, replacing the hardcoded br-ex. 

 NetworkDeployment:
    type: OS::TripleO::SoftwareDeployment
    depends_on: PreNetworkConfig
    properties:
      name: NetworkDeployment
      config: {get_resource: NetworkConfig}
      server: {get_resource: {{role.name}}}
      actions: {get_param: NetworkDeploymentActions}
      input_values:
        bridge_name: {get_param: NeutronPhysicalBridge}  <== replaced br-ex
        interface_name: {get_param: NeutronPublicInterface}

This should be sufficient to ensure that the behavior with custom controller/compute roles is consistent with the default roles.  Do you agree?
Comment 15 Bob Fournier 2017-07-21 11:07:01 EDT
Andreas  - thanks. Yes this is just upstream now and will be part of OSP-12.  Is it necessary in OSP-10?  I'll let Dan answer as to the feasibility of back porting these changes.
Comment 16 Andreas Karis 2017-07-21 11:42:00 EDT
Bob,

Well, it's a bug. At least the part where we hardcode the br-ex on the computes and controllers. The part with the custom roles is a feature. I should actually have created 2 BZs back in the days and upstream 2 patches, but the RFE and bug are so similar. Anyway - I personally don't need it for OSP 10 because I can work around it, but I think that Ganesh asked for it and the aforementioned bug should eventually be fixed in OSP 10 as well.

- Andreas
Comment 17 Bob Fournier 2017-07-21 11:56:00 EDT
Andreas - yes this same patch (https://review.openstack.org/#/c/439868/) fixes the hardcoded br-ex for controller and compute in addition to the custom roles.  Controller and compute now use NeutronPhysicalBridge instead of br-ex directly.
Comment 25 errata-xmlrpc 2017-12-13 15:57:54 EST
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-2017:3462

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