Red Hat Training

A Red Hat training course is available for Red Hat OpenStack Platform

Chapter 3. Choosing a Deployment Type

Deploying pure HCI is simpler, as it involves invoking an environment file that adds the Ceph-OSD services to the Compute role. Deploying mixed HCI involves defining a custom role, flavor, and networking settings for HCI nodes. As both HCI types offer contrasting deployment approaches, determine which type is more suitable for your environment.

The following sub-sections walk through each deployment type. For either deployment type, create a /home/stack/templates/ directory to store any custom environment files and Heat templates.

3.1. Pure HCI

To deploy Red Hat OpenStack with pure, use the following environment file:

/usr/share/openstack-tripleo-heat-templates/environments/hyperconverged-ceph.yaml

This environment file redefines the Compute role by adding the CephOSD service to it. By default, the hyperconverged-ceph.yaml environment file assumes that you are using an isolated StorageMgmt network, and configures the Compute ports accordingly.

If you are not using an isolated StorageMgmt network, disable the StorageMgmtPort service. To do this:

  1. Create a new environment file named hyperconverged-non-isolated.yaml in ~/templates/ containing the following:

    resource_registry:
      OS::TripleO::Compute::Ports::StorageMgmtPort::None
  2. During the deployment process (Section 6.1, “Deploying Pure HCI”), invoke ~/templates/hyperconverged-non-isolated.yaml when you run openstack overcloud deploy. This environment file must be invoked last to ensure that it overrides the others correctly.

Proceed to Chapter 4, Configuring Resource Isolation on Hyper-converged Nodes for instructions on mitigating resource contention between Compute and Ceph Storage services.

3.2. Mixed HCI

The Overcloud usually consists of nodes in predefined roles such as Controller nodes, Compute nodes, and different storage node types. Each of these default roles contains a set of services defined in the core Heat template collection on the director node. However, the architecture of the core Heat templates provides a method to:

  • Create custom roles
  • Add and remove services from each role

This allows us to define a new role both Compute and Ceph OSD services. This effectively co-locates both services, allowing you to deploy them together on the same hyper-converged node.

Note

For detailed information about custom roles, see Composable Services and Custom Roles from Advanced Overcloud Customization.

3.2.1. Creating a Custom Role for HCI Nodes

On the undercloud, default roles are defined in the following file:

/usr/share/openstack-tripleo-heat-templates/roles_data.yaml

Copy this file to the custom templates directory you created (namely, ~/templates/):

$ cp usr/share/openstack-tripleo-heat-templates/roles_data.yaml ~/templates/roles_data_hci.yaml

To define a new role that co-locates both Compute and Ceph OSD, create a role that combines the services of both Compute and CephStorage entries. To do this, add a new role named OsdCompute in ~/templates/roles_data_hci.yaml, copy the Compute role services to OsdCompute, and add the Ceph OSD service:

- name: OsdCompute # 1
  CountDefault: 1 # 2
  disable_upgrade_deployment: True
  ServicesDefault:
    - OS::TripleO::Services::CACerts
    - OS::TripleO::Services::CephClient
    - OS::TripleO::Services::CephExternal
    - OS::TripleO::Services::CephOSD # 3
    - OS::TripleO::Services::Timezone
[...]
1
A role must have a unique name, defined here as OsdCompute.
2
The CountDefault: parameter how many nodes the director should apply the role to by default (in this case, 1).
3
The OS::TripleO::Services::CephOSD entry is the only one on the CephStorage role that does not exist on the Compute role.

Red Hat OpenStack Platform supports deployments that feature both hyper-converged and non-hyper-converged Compute nodes. If you do not want to deploy any non-hyper-converged Compute nodes, set the CountDefault: parameter of the Compute role to 0:

- name: Compute
  CountDefault: 0
  disable_upgrade_deployment: True
  ServicesDefault:
    - OS::TripleO::Services::CACerts
    - OS::TripleO::Services::CephClient
    - OS::TripleO::Services::CephExternal
    - OS::TripleO::Services::Timezone
    - OS::TripleO::Services::Ntp
[...]

You can use the CountDefault: parameter to define how many nodes to assign to each role. However, we recommend that you do so in a separate Heat template, as described later in Section 6.2, “Deploying Mixed HCI”.

3.2.2. Configuring Port Assignments for the Custom Role

The default Heat templates in /usr/share/openstack-tripleo-heat-templates/ provide the necessary network settings for the default roles. These settings include how IP addresses and ports should be assigned for each service on each node.

Custom roles (like OsdCompute in Section 3.2.1, “Creating a Custom Role for HCI Nodes”) do not have the required port assignment Heat templates, so you need to define these yourself. To do so, create a new Heat template named ports.yaml in ~/templates containing the following:

resource_registry:
  OS::TripleO::OsdCompute::Ports::ExternalPort: /usr/share/openstack-tripleo-heat-templates/network/ports/noop.yaml  # 1
  OS::TripleO::OsdCompute::Ports::InternalApiPort: /usr/share/openstack-tripleo-heat-templates/network/ports/internal_api.yaml
  OS::TripleO::OsdCompute::Ports::StoragePort: /usr/share/openstack-tripleo-heat-templates/network/ports/storage.yaml
  OS::TripleO::OsdCompute::Ports::StorageMgmtPort: /usr/share/openstack-tripleo-heat-templates/network/ports/storage_mgmt_from_pool.yaml
  OS::TripleO::OsdCompute::Ports::TenantPort: /usr/share/openstack-tripleo-heat-templates/network/ports/tenant.yaml
  OS::TripleO::OsdCompute::Ports::StorageMgmtPort: /usr/share/openstack-tripleo-heat-templates/network/ports/storage_mgmt.yaml
1
If you are using DVR, replace this line with:
  OS::TripleO::OsdCompute::Ports::ExternalPort: /usr/share/openstack-tripleo-heat-templates/network/ports/external.yaml

See Configure Distributed Virtual Routing (DVR) from the Networking Guide for more details.

See Isolating Networks and Selecting Networks to Deploy (from Advanced Overcloud Customization) for related information.

3.2.3. Creating and Assigning a New Flavor

As mentioned in Section 1.1, “Assumptions”, you should have already registered and tagged each node with a corresponding flavor. However, since deploying mixed HCI involves defining a new OsdCompute role, you also need to create a new flavor for it:

  1. To create a new role named osdcompute, run:

    $ openstack flavor create --id auto --ram 6144 --disk 40 --vcpus 4 osdcompute
    Note

    For more details about this command, run openstack flavor create --help.

  2. Map this flavor to a new profile, also named osdcompute:

    $ openstack flavor set --property "cpu_arch"="x86_64" --property "capabilities:boot_option"="local" --property "capabilities:profile"="osdcompute" osdcompute
    Note

    For more details about this command, run openstack flavor set --help.

  3. Tag nodes into the new osdcompute profile:

    $ ironic node-update UUID add properties/capabilities='profile:osdcompute,boot_option:local'
    Note

    For more details about tagging nodes, see Manually Tagging the Nodes (from Red Hat Ceph Storage for the Overcloud).

See Manually Tagging the Nodes and Assigning Nodes and Flavors to Roles (from (from Red Hat Ceph Storage for the Overcloud) for related details.