Enabling BlueChi components¶
Setting use_qm:
to true
builds the mixed-criticality architecture and enables BlueChi components.
If you have not configured the use_qm
variable, do so now.
Prerequisites
- A host machine that runs on CentOS Stream, Fedora, or RHEL
- A custom manifest file, such as the manifest file that you created in Configuring communication between containers in QM and root partitions
- A container in the root partition and a container in the QM partition that need to communicate with each other
Procedure
-
To enable BlueChi components, set
use_qm
totrue
in thempp-vars
section of your manifest file:
Next steps
After enabling BlueChi components, you can configure communication between the controller and agents.
Configuring communication between BlueChi controller and agent¶
Configuration files for the bluechi-controller
and bluechi-agent
enable these components to communicate with each other. These files define
information such as the host, port, and allowed node names for these components.
Prerequisites
- A host machine that runs on CentOS Stream, Fedora, or RHEL
- A custom manifest file, such as the manifest file that you created in Configuring communication between containers in QM and root partitions
- A container in the root partition and a container in the QM partition that need to communicate with each other
Procedure
-
Create a configuration file for the BlueChi controller on the primary node:
-
Create a configuration file for the BlueChi agent on the primary node:
-
Copy the
.conf
files for the root partition into the image by adding a neworg.osbuild.copy
stage to therootfs
pipeline of your manifest file:- type: org.osbuild.copy inputs: inlinefile6: type: org.osbuild.files origin: org.osbuild.source mpp-embed: id: controller path: ../etc/bluechi/controller.conf inlinefile7: type: org.osbuild.files origin: org.osbuild.source mpp-embed: id: agent path: ../etc/bluechi/agent.conf options: paths: - from: mpp-format-string: input://inlinefile6/{embedded['controller']} to: tree:///etc/bluechi/controller.conf - from: mpp-format-string: input://inlinefile7/{embedded['agent']} to: tree:///etc/bluechi/agent.conf
-
Create a configuration file for the managed QM partition:
-
Copy the
agent.conf
file for the QM partition into the image by adding a neworg.osbuild.copy
stage to theqm_rootfs
pipeline of your manifest file:
Using bluechictl¶
The bluechi-ctl
RPM package contains a command line tool that you can use to manually monitor and manage nodes and units and to test and debug
BlueChi functionality. No remote connection exists between bluechictl
and the bluechi-controller
. Instead, the bluechictl
tool interacts with
bluechi-controller
through sd-bus. Therefore, install bluechictl
on the same node as the bluechi-controller
and run the commands from
that host.
Monitoring nodes¶
You can check the state of nodes in your system. The bluechictl status
command indicates whether nodes are online and when they were last seen.
You can monitor single nodes or all the nodes in your system.
Commands to monitor nodes
Command | Purpose |
---|---|
bluechictl status |
Verify the status of all nodes. |
bluechictl status -w |
Continuously watch the status of all nodes. |
bluechictl status _<NodeName>_ |
Verify the status of a specific node. |
bluechictl status _<NodeName>_ -w |
Continuously watch the status of a specific node. |
Monitoring units¶
Services, such as bluechi-controller.service
and bluechi-agent.service
are examples of units. Use these commands to list units and monitor
changes to the services.
Commands to monitor units
Command | Purpose |
---|---|
bluechictl list-units |
List all units on all nodes. |
bluechictl list-units --filter=demo-\*.service |
Use a glob pattern to filter services; this example lists services that start with demo . |
bluechictl list-units _<NodeName>_ |
List all units on a specific node. |
bluechictl monitor _<NodeName>_ _<UnitName>_ |
View changes on a specific node and unit. |
bluechictl monitor \* \* |
Use the wildcard character * to view changes on all units on all node. |
Managing units¶
Additional bluechictl
commands exist to start and stop services and manage them in other ways during the testing process.
Commands to manage units
Command | Purpose |
---|---|
bluechictl start |
Starts systemd units on managed nodes. |
bluechictl stop |
Stops systemd units on managed nodes. |
bluechictl enable |
Enables services on managed nodes. |
bluechictl disable |
Disables services on managed nodes. |
bluechictl freeze |
Temporarily prevents identified services from receiving CPU time. |
bluechictl thaw |
Restores CPU time to identified services. |
For more information about how to use bluechictl
commands, see
Examples on how to use BlueChi on the BlueChi Documentation site.
Additional resources