
Some of the OpenStack director guides that I have seen and read suggest using ACH Tools to perform role matching, which matches Ironic nodes to the most appropriate roles (flavors) bases on their CPU, Memory, and Disk configurations.
However if you prefer to manually assign a role to a node follow the steps outlined below.
Creating Flavors
Before we can manually assign a role to a flavor, we must first create the flavor. In this example we are going to create 4 flavors.
First lets create the flavor that will be used for our OpenStack Overcloud Controllers.
# openstack flavor create –id auto –ram 8192 –disk 26 –vcpus 4 control
+—————————-+————————————–+
| Field | Value |
+—————————-+————————————–+
| OS-FLV-DISABLED:disabled | False |
| OS-FLV-EXT-DATA:ephemeral | 0 |
| disk | 26 |
| id | 4007f8a4-6ea9-400e-9142-6926f0538b29 |
| name | control |
| os-flavor-access:is_public | True |
| ram | 8192 |
| rxtx_factor | 1.0 |
| swap | |
| vcpus | 4 |
+—————————-+————————————–+
Now lets create the flavor that will be used for our OpenStack Overcloud Compute Nodes.
# openstack flavor create –id auto –ram 6144 –disk 18 –vcpus 2 compute
+—————————-+————————————–+
| Field | Value |
+—————————-+————————————–+
| OS-FLV-DISABLED:disabled | False |
| OS-FLV-EXT-DATA:ephemeral | 0 |
| disk | 18 |
| id | 60d05417-d2ba-4f62-a37c-1bafbfaec30a |
| name | compute |
| os-flavor-access:is_public | True |
| ram | 6144 |
| rxtx_factor | 1.0 |
| swap | |
| vcpus | 2 |
+—————————-+————————————–+
Since our POC deployment will also include CEPH nodes, we need to also create a CEPH role.
# openstack flavor create –id auto –ram 4096 –disk 18 –vcpus 2 ceph
+—————————-+————————————–+
| Field | Value |
+—————————-+————————————–+
| OS-FLV-DISABLED:disabled | False |
| OS-FLV-EXT-DATA:ephemeral | 0 |
| disk | 18 |
| id | 5480e8e6-f895-4870-b4dc-e5fff5a32911 |
| name | ceph |
| os-flavor-access:is_public | True |
| ram | 4096 |
| rxtx_factor | 1.0 |
| swap | |
| vcpus | 2 |
+—————————-+————————————–+
Important Note: You need to have a baremetal role created otherwise your deployment will fail, use the command below to create it.
# openstack flavor create –id auto –ram 8192 –disk 58 –vcpus 4 baremetal
Now let’s check our work with the command below. You should see your 4 roles listed (Baremetal, Ceph, Control, and Compute).
#openstack flavor list




