이 콘텐츠는 선택한 언어로 제공되지 않습니다.
Chapter 3. Deploying an overcloud with the Bare Metal Provisioning service
To deploy an overcloud with the Bare Metal Provisioning service (ironic), you must create and configure the bare metal network, and configure the overcloud to enable bare metal provisioning.
Create the bare metal network. You can reuse the provisioning network interface on the Controller nodes to create a flat network, or you can create a custom network:
Configure the overcloud to enable bare metal provisioning:
If you use Open Virtual Network (OVN), the Bare Metal Provisioning service is supported only with the DHCP agent defined in the ironic-overcloud.yaml file, neutron-dhcp-agent. The built-in DHCP server on OVN cannot provision bare metal nodes or serve DHCP for the provisioning networks. To enable iPXE chain loading you must set the --dhcp-match tag in dnsmasq, which is not supported by the OVN DHCP server.
Prerequisites
- Your environment meets the minimum requirements. For more information, see Requirements for bare metal provisioning.
3.1. Configuring the default flat network 링크 복사링크가 클립보드에 복사되었습니다!
To use the default flat bare metal network, you reuse the provisioning network interface on the Controller nodes to create a bridge for the Bare Metal Provisioning service (ironic).
Procedure
-
Log in to the undercloud as the
stackuser. Source the
stackrcfile:[stack@director ~]$ source ~/stackrcModify the
/home/stack/templates/nic-configs/controller.yamlfile to reuse the provisioning network interface on the Controller nodes,eth1, to create a bridge for the bare metal network:network_config: - type: ovs_bridge name: br-baremetal use_dhcp: false members: - type: interface name: eth1 addresses: - ip_netmask: list_join: - / - - get_param: ControlPlaneIp - get_param: ControlPlaneSubnetCidrNoteYou cannot VLAN tag the bare metal network when you create it by reusing the provisioning network.
Add
br-baremetalto theNeutronBridgeMappingsparameter in yournetwork-environment.yamlfile:parameter_defaults: NeutronBridgeMappings: datacentre:br-ex,baremetal:br-baremetalAdd
baremetalto the list of networks specified by theNeutronFlatNetworksparameter in yournetwork-environment.yamlfile:parameter_defaults: NeutronBridgeMappings: datacentre:br-ex,baremetal:br-baremetal NeutronFlatNetworks: datacentre,baremetal
3.2. Configuring a custom IPv4 provisioning network 링크 복사링크가 클립보드에 복사되었습니다!
Create a custom IPv4 provisioning network to provision and deploy the overcloud over IPv4.
Procedure
-
Log in to the undercloud host as the
stackuser. Source the
stackrcundercloud credentials file:$ source ~/stackrcCopy the
network_data.yamlfile to your environment file directory:(undercloud) [stack@host01 ~]$ cp /usr/share/openstack-tripleo-heat-templates/network_data.yaml /home/stack/templates/network_data.yamlAdd a new network for overcloud provisioning to your
network_data.yamlfile:# custom network for overcloud provisioning - name: OcProvisioning name_lower: oc_provisioning vip: true vlan: 205 ip_subnet: '<ipv4_subnet_address>/<ipv4_mask>' allocation_pools: [{'start': '<ipv4_start_address>', 'end': '<ipv4_end_address>'}]-
Replace
<ipv4_subnet_address>with the IPv4 address of your IPv4 subnet. -
Replace
<ipv4_mask>with the IPv4 network mask for your IPv4 subnet. -
Replace
<ipv4_start_address>and<ipv4_end_address>with the IPv4 range that you want to use for address allocation.
-
Replace
Configure
IronicApiNetworkandIronicNetworkin yourServiceNetMapconfiguration to use the new IPv4 provisioning network:ServiceNetMap: IronicApiNetwork: oc_provisioning IronicNetwork: oc_provisioningAdd the new network as an interface to your local Controller NIC configuration file:
network_config: - type: vlan vlan_id: get_param: OcProvisioningNetworkVlanID addresses: - ip_netmask: get_param: OcProvisioningIpSubnetCopy the
roles_data.yamlfile to your environment file directory:(undercloud) [stack@host01 ~]$ cp /usr/share/openstack-tripleo-heat-templates/roles_data.yaml /home/stack/templates/roles_data.yamlAdd the new network for the controller to your
roles_data.yamlfile:networks: ... OcProvisioning: subnet: oc_provisioning_subnetInclude the
IronicInspectorservice in theIronicrole in yourroles_data.yamlfile, if not already present:ServicesDefault: OS::TripleO::Services::IronicInspector
3.3. Configuring a custom IPv6 provisioning network 링크 복사링크가 클립보드에 복사되었습니다!
Create a custom IPv6 provisioning network to provision and deploy the overcloud over IPv6.
Procedure
-
Log in to the undercloud as the
stackuser. Source the
stackrcfile:[stack@director ~]$ source ~/stackrcCopy the
network_data.yamlfile to your environment file directory:(undercloud) [stack@host01 ~]$ cp /usr/share/openstack-tripleo-heat-templates/network_data.yaml /home/stack/templates/network_data.yamlAdd a new IPv6 network for overcloud provisioning to your
network_data.yamlfile:# custom network for IPv6 overcloud provisioning - name: OcProvisioningIPv6 vip: true name_lower: oc_provisioning_ipv6 vlan: 10 ipv6: true ipv6_subnet: '<ipv6_subnet_address>/<ipv6_prefix>' ipv6_allocation_pools: [{'start': '<ipv6_start_address>', 'end': '<ipv6_end_address>'}] gateway_ipv6: '<ipv6_gw_address>'-
Replace
<ipv6_subnet_address>with the IPv6 address of your IPv6 subnet. -
Replace
<ipv6_prefix>with the IPv6 network prefix for your IPv6 subnet. -
Replace
<ipv6_start_address>and<ipv6_end_address>with the IPv6 range that you want to use for address allocation. -
Replace
<ipv6_gw_address>with the IPv6 address of your gateway.
-
Replace
Create a new file
network_environment_overrides.yamlin your environment file directory:$ touch /home/stack/templates/network_environment_overrides.yamlConfigure
IronicApiNetworkandIronicNetworkin yournetwork_environment_overrides.yamlfile to use the new IPv6 provisioning network:ServiceNetMap: IronicApiNetwork: oc_provisioning_ipv6 IronicNetwork: oc_provisioning_ipv6Set the
IronicIpVersionparameter to6:parameter_defaults: IronicIpVersion: 6Enable the
RabbitIPv6,MysqlIPv6, andRedisIPv6parameters:parameter_defaults: RabbitIPv6: True MysqlIPv6: True RedisIPv6: TrueAdd the new network as an interface to your local Controller NIC configuration file:
network_config: - type: vlan vlan_id: get_param: OcProvisioningIPv6NetworkVlanID addresses: - ip_netmask: get_param: OcProvisioningIPv6IpSubnetCopy the
roles_data.yamlfile to your environment file directory:(undercloud) [stack@host01 ~]$ cp /usr/share/openstack-tripleo-heat-templates/roles_data.yaml /home/stack/templates/roles_data.yamlAdd the new network for the Controller role to your
roles_data.yamlfile:networks: ... - OcProvisioningIPv6Include the
IronicInspectorservice in theIronicrole in yourroles_data.yamlfile, if not already present:ServicesDefault: OS::TripleO::Services::IronicInspector
3.4. Configuring the overcloud to enable bare metal provisioning 링크 복사링크가 클립보드에 복사되었습니다!
Use one of the default templates located in the /usr/share/openstack-tripleo-heat-templates/environments/services directory to deploy the overcloud with the Bare Metal Provisioning service (ironic) enabled:
-
For deployments that use OVS:
ironic.yaml -
For deployments that use OVN:
ironic-overcloud.yaml
You can create a local environment file to override the default configuration, as required by your deployment.
Procedure
-
Create an environment file in your local directory to configure the Bare Metal Provisioning service for your deployment, for example,
ironic-overrides.yaml. Optional: Configure the type of cleaning that is performed on the bare metal machines before and between provisioning:
parameter_defaults: IronicCleaningDiskErase: <cleaning_type>Replace
<cleaning_type>with one of the following values:-
full: (Default) Performs a full clean. -
metadata: Clean only the partition table. This type of cleaning substantially speeds up the cleaning process. However, because the deployment is less secure in a multi-tenant environment, use this option only in a trusted tenant environment.
-
Optional: Add additional drivers to the default drivers:
parameter_defaults: IronicEnabledHardwareTypes: ipmi,idrac,ilo,[additional_driver_1],...,[additional_driver_n]Replace
[additional_driver_1], and optionally all drivers up to[additional_driver_n], with the additional drivers you want to enable.To enable bare metal introspection, add the following configuration to your local Bare Metal Provisioning service environment file,
ironic-overrides.yaml:parameter_defaults: IronicInspectorSubnets: - ip_range: <ip_range> IPAImageURLs: '["http://<ip_address>:<port>/agent.kernel", "http://<ip_address>:<port>/agent.ramdisk"]' IronicInspectorInterface: '<baremetal_interface>'-
Replace
<ip_range>with the IP ranges for your environments, for example,192.168.0.100,192.168.0.120. -
Replace
<ip_address>:<port>with the IP address and port of the web server that hosts the IPA kernel and ramdisk. To use the same images that you use on the undercloud, set the IP address to the undercloud IP address, and the port to8088. If you omit this parameter, you must include alternatives on each Controller node. -
Replace
<baremetal_interface>with the bare metal network interface, for example,br-baremetal.
-
Replace
Add your new role and custom environment files to the stack with your other environment files and deploy the overcloud:
(undercloud)$ openstack overcloud deploy --templates \ -e [your environment files] \ -e /home/stack/templates/node-info.yaml -r /home/stack/templates/roles_data.yaml \ -e /usr/share/openstack-tripleo-heat-templates/network-environment.yaml \ -e /usr/share/openstack-tripleo-heat-templates/environments/services/<default_ironic_template> \ -e /usr/share/openstack-tripleo-heat-templates/environments/services/ironic-inspector.yaml \ -e /home/stack/templates/network_environment_overrides.yaml -n /home/stack/templates/network_data.yaml -e /home/stack/templates/ironic-overrides.yaml \-
Replace
<default_ironic_template>with eitherironic.yamlorironic-overcloud.yaml, depending on the Networking service mechanism driver for your deployment.
NoteThe order that you pass your environment files to the
openstack overcloud deploycommand is important, as the configuration in the later files takes precedence. Therefore, your environment file that enables and configures bare metal provisioning on your overcloud must be passed to the command after any network configuration files.-
Replace
3.5. Testing the Bare Metal Provisioning service 링크 복사링크가 클립보드에 복사되었습니다!
You can use the OpenStack Integration Test Suite to validate your Red Hat OpenStack deployment. For more information, see the OpenStack Integration Test Suite Guide.
Additional verification methods for the Bare Metal Provisioning service:
Configure the shell to access Identity as the administrative user:
$ source ~/overcloudrcCheck that the
nova-computeservice is running on the Controller nodes:$ openstack compute service list -c Binary -c Host -c StatusIf you changed the default ironic drivers, ensure that the required drivers are enabled:
$ openstack baremetal driver listEnsure that the ironic endpoints are listed:
$ openstack catalog list
3.6. Additional resources 링크 복사링크가 클립보드에 복사되었습니다!
- Deployment command options in the Director Installation and Usage guide
- IPv6 Networking for the Overcloud
- Bare Metal (ironic) Parameters in the Overcloud Parameters guide