Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.
Chapter 3. Bare metal configuration
When deploying OpenShift Container Platform on bare metal hosts, there are times when you need to make changes to the host either before or after provisioning. This can include inspecting the host’s hardware, firmware, and firmware details. It can also include formatting disks or changing modifiable firmware settings.
3.1. About the Bare Metal Operator Link kopierenLink in die Zwischenablage kopiert!
Use the Bare Metal Operator (BMO) to provision, manage, and inspect bare-metal hosts in your cluster.
The BMO uses three resources to complete these tasks:
-
BareMetalHost -
HostFirmwareSettings -
FirmwareSchema
The BMO maintains an inventory of the physical hosts in the cluster by mapping each bare-metal host to an instance of the
BareMetalHost
BareMetalHost
BareMetalHost
The BMO also uses the
HostFirmwareSettings
FirmwareSchema
The BMO interfaces with bare-metal hosts in the cluster by using the Ironic API service. The Ironic service uses the Baseboard Management Controller (BMC) on the host to interface with the machine.
Some common tasks you can complete by using the BMO include the following:
- Provision bare-metal hosts to the cluster with a specific image
- Format a host’s disk contents before provisioning or after deprovisioning
- Turn on or off a host
- Change firmware settings
- View the host’s hardware details
3.1.1. Bare Metal Operator architecture Link kopierenLink in die Zwischenablage kopiert!
The Bare Metal Operator (BMO) uses three resources to provision, manage, and inspect bare-metal hosts in your cluster. The following diagram illustrates the architecture of these resources:
BareMetalHost
The
BareMetalHost
BareMetalHost
BareMetalHost
The
BareMetalHost
- Deployment specifications such as the operating system boot image or the custom RAM disk
- Provisioning state
- Baseboard Management Controller (BMC) address
- Desired power state
The
BareMetalHost
- Number of CPUs
- MAC address of a NIC
- Size of the host’s storage device
- Current power state
HostFirmwareSettings
You can use the
HostFirmwareSettings
Available
HostFirmwareSettings
BareMetalHost
HostFirmwareSettings
You can use the
HostFirmwareSettings
You must adhere to the schema specific to the vendor firmware when you edit the
spec
HostFirmwareSettings
FirmwareSchema
FirmwareSchema
Firmware settings vary among hardware vendors and host models. A
FirmwareSchema
FirmwareSchema
spec
HostFirmwareSettings
A
FirmwareSchema
BareMetalHost
3.2. About the BareMetalHost resource Link kopierenLink in die Zwischenablage kopiert!
Metal3 introduces the concept of the
BareMetalHost
BareMetalHost
-
The spec
BareMetalHost -
The status
BareMetalHost
3.2.1. The BareMetalHost spec Link kopierenLink in die Zwischenablage kopiert!
The
spec
BareMetalHost
| Parameters | Description |
|---|---|
|
| An interface to enable or disable automated cleaning during provisioning and de-provisioning. When set to
|
| The
|
|
| The MAC address of the NIC used for provisioning the host. |
|
| The boot mode of the host. It defaults to
|
|
| A reference to another resource that is using the host. It could be empty if another resource is not currently using the host. For example, a
|
|
| A human-provided string to help identify the host. |
|
| A boolean indicating whether the host provisioning and deprovisioning are managed externally. When set:
|
|
| Contains information about the BIOS configuration of bare-metal hosts. Currently,
|
| The
|
|
| A reference to the secret containing the network configuration data and its namespace, so that it can be attached to the host before the host boots to set up the network. |
|
| A boolean indicating whether the host should be powered on (
|
| (Optional) Contains the information about the RAID configuration for bare-metal hosts. If not specified, it retains the current configuration. Note OpenShift Container Platform 4.14 supports hardware RAID for BMCs using the iRMC protocol only. OpenShift Container Platform 4.14 does not support software RAID on the installation drive. See the following configuration settings:
You can set the
If you receive an error message indicating that the driver does not support RAID, set the
|
| The
|
3.2.2. The BareMetalHost status Link kopierenLink in die Zwischenablage kopiert!
The
BareMetalHost
| Parameters | Description |
|---|---|
|
| A reference to the secret and its namespace holding the last set of baseboard management controller (BMC) credentials the system was able to validate as working. |
|
| Details of the last error reported by the provisioning backend, if any. |
|
| Indicates the class of problem that has caused the host to enter an error state. The error types are:
|
| The
|
| Contains BIOS firmware information. For example, the hardware vendor and version. |
| The
|
| The host’s amount of memory in Mebibytes (MiB). |
| The
|
| Contains information about the host’s
|
|
| The timestamp of the last time the status of the host was updated. |
|
| The status of the server. The status is one of the following:
|
|
| Boolean indicating whether the host is powered on. |
| The
|
|
| A reference to the secret and its namespace holding the last set of BMC credentials that were sent to the provisioning backend. |
3.3. Getting the BareMetalHost resource Link kopierenLink in die Zwischenablage kopiert!
The
BareMetalHost
BareMetalHost
Procedure
Get the list of
resources:BareMetalHost$ oc get bmh -n openshift-machine-api -o yamlNoteYou can use
as the long form ofbaremetalhostwithbmhcommand.oc getGet the list of hosts:
$ oc get bmh -n openshift-machine-apiGet the
resource for a specific host:BareMetalHost$ oc get bmh <host_name> -n openshift-machine-api -o yamlWhere
is the name of the host.<host_name>Example output
apiVersion: metal3.io/v1alpha1 kind: BareMetalHost metadata: creationTimestamp: "2022-06-16T10:48:33Z" finalizers: - baremetalhost.metal3.io generation: 2 name: openshift-worker-0 namespace: openshift-machine-api resourceVersion: "30099" uid: 1513ae9b-e092-409d-be1b-ad08edeb1271 spec: automatedCleaningMode: metadata bmc: address: redfish://10.46.61.19:443/redfish/v1/Systems/1 credentialsName: openshift-worker-0-bmc-secret disableCertificateVerification: true bootMACAddress: 48:df:37:c7:f7:b0 bootMode: UEFI consumerRef: apiVersion: machine.openshift.io/v1beta1 kind: Machine name: ocp-edge-958fk-worker-0-nrfcg namespace: openshift-machine-api customDeploy: method: install_coreos online: true rootDeviceHints: deviceName: /dev/disk/by-id/scsi-<serial_number> userData: name: worker-user-data-managed namespace: openshift-machine-api status: errorCount: 0 errorMessage: "" goodCredentials: credentials: name: openshift-worker-0-bmc-secret namespace: openshift-machine-api credentialsVersion: "16120" hardware: cpu: arch: x86_64 clockMegahertz: 2300 count: 64 flags: - 3dnowprefetch - abm - acpi - adx - aes model: Intel(R) Xeon(R) Gold 5218 CPU @ 2.30GHz firmware: bios: date: 10/26/2020 vendor: HPE version: U30 hostname: openshift-worker-0 nics: - mac: 48:df:37:c7:f7:b3 model: 0x8086 0x1572 name: ens1f3 ramMebibytes: 262144 storage: - hctl: "0:0:0:0" model: VK000960GWTTB name: /dev/disk/by-id/scsi-<serial_number> sizeBytes: 960197124096 type: SSD vendor: ATA systemVendor: manufacturer: HPE productName: ProLiant DL380 Gen10 (868703-B21) serialNumber: CZ200606M3 lastUpdated: "2022-06-16T11:41:42Z" operationalStatus: OK poweredOn: true provisioning: ID: 217baa14-cfcf-4196-b764-744e184a3413 bootMode: UEFI customDeploy: method: install_coreos image: url: "" raid: hardwareRAIDVolumes: null softwareRAIDVolumes: [] rootDeviceHints: deviceName: /dev/disk/by-id/scsi-<serial_number> state: provisioned triedCredentials: credentials: name: openshift-worker-0-bmc-secret namespace: openshift-machine-api credentialsVersion: "16120"
3.4. About the HostFirmwareSettings resource Link kopierenLink in die Zwischenablage kopiert!
You can use the
HostFirmwareSettings
Available
HostFirmwareSettings
firmware
BareMetalHost
HostFirmwareSettings
The
HostFirmwareSettings
-
The spec.
HostFirmwareSettings -
The status.
HostFirmwareSettings
3.4.1. The HostFirmwareSettings spec Link kopierenLink in die Zwischenablage kopiert!
The
spec
HostFirmwareSettings
spec.settings
Preparing
FirmwareSchema
Example
spec:
settings:
ProcTurboMode: Disabled
- 1
- In the foregoing example, the
spec.settingssection contains a name/value pair that will set theProcTurboModeBIOS setting toDisabled.
Integer parameters listed in the
status
"1"
spec.settings
1
3.4.2. The HostFirmwareSettings status Link kopierenLink in die Zwischenablage kopiert!
The
status
| Parameters | Description |
|---|---|
| The
|
| The
|
| The
|
3.5. Getting the HostFirmwareSettings resource Link kopierenLink in die Zwischenablage kopiert!
The
HostFirmwareSettings
HostFirmwareSettings
Procedure
Get the detailed list of
resources:HostFirmwareSettings$ oc get hfs -n openshift-machine-api -o yamlNoteYou can use
as the long form ofhostfirmwaresettingswith thehfscommand.oc getGet the list of
resources:HostFirmwareSettings$ oc get hfs -n openshift-machine-apiGet the
resource for a particular hostHostFirmwareSettings$ oc get hfs <host_name> -n openshift-machine-api -o yamlWhere
is the name of the host.<host_name>
3.6. Editing the HostFirmwareSettings resource Link kopierenLink in die Zwischenablage kopiert!
You can edit the
HostFirmwareSettings
You can only edit hosts when they are in the
provisioned
externally provisioned
Procedure
Get the list of
resources:HostFirmwareSettings$ oc get hfs -n openshift-machine-apiEdit a host’s
resource:HostFirmwareSettings$ oc edit hfs <host_name> -n openshift-machine-apiWhere
is the name of a provisioned host. The<host_name>resource will open in the default editor for your terminal.HostFirmwareSettingsAdd name/value pairs to the
section:spec.settingsExample
spec: settings: name: value1 - 1
- Use the
FirmwareSchemaresource to identify the available settings for the host. You cannot set values that are read-only.
- Save the changes and exit the editor.
Get the host’s machine name:
$ oc get bmh <host_name> -n openshift-machine nameWhere
is the name of the host. The machine name appears under the<host_name>field.CONSUMERAnnotate the machine to delete it from the machineset:
$ oc annotate machine <machine_name> machine.openshift.io/delete-machine=true -n openshift-machine-apiWhere
is the name of the machine to delete.<machine_name>Get a list of nodes and count the number of worker nodes:
$ oc get nodesGet the machineset:
$ oc get machinesets -n openshift-machine-apiScale the machineset:
$ oc scale machineset <machineset_name> -n openshift-machine-api --replicas=<n-1>Where
is the name of the machineset and<machineset_name>is the decremented number of worker nodes.<n-1>When the host enters the
state, scale up the machineset to make theAvailableresource changes take effect:HostFirmwareSettings$ oc scale machineset <machineset_name> -n openshift-machine-api --replicas=<n>Where
is the name of the machineset and<machineset_name>is the number of worker nodes.<n>
3.7. Verifying the HostFirmware Settings resource is valid Link kopierenLink in die Zwischenablage kopiert!
When the user edits the
spec.settings
HostFirmwareSetting
FimwareSchema
Type
status.Condition
False
Procedure
Get a list of
resources:HostFirmwareSetting$ oc get hfs -n openshift-machine-apiVerify that the
resource for a particular host is valid:HostFirmwareSettings$ oc describe hfs <host_name> -n openshift-machine-apiWhere
is the name of the host.<host_name>Example output
Events: Type Reason Age From Message ---- ------ ---- ---- ------- Normal ValidationFailed 2m49s metal3-hostfirmwaresettings-controller Invalid BIOS setting: Setting ProcTurboMode is invalid, unknown enumeration value - FooImportantIf the response returns
, there is an error in the resource configuration and you must update the values to conform to theValidationFailedresource.FirmwareSchema
3.8. About the FirmwareSchema resource Link kopierenLink in die Zwischenablage kopiert!
BIOS settings vary among hardware vendors and host models. A
FirmwareSchema
FirmwareSchema
spec
HostFirmwareSettings
FirmwareSchema
FirmwareSchema
HostFirmwareSettings
FirmwareSchema
| Parameters | Description |
|---|---|
| The
|
3.9. Getting the FirmwareSchema resource Link kopierenLink in die Zwischenablage kopiert!
Each host model from each vendor has different BIOS settings. When editing the
HostFirmwareSettings
spec
FirmwareSchema
Procedure
To get a list of
resource instances, execute the following:FirmwareSchema$ oc get firmwareschema -n openshift-machine-apiTo get a particular
instance, execute:FirmwareSchema$ oc get firmwareschema <instance_name> -n openshift-machine-api -o yamlWhere
is the name of the schema instance stated in the<instance_name>resource (see Table 3).HostFirmwareSettings