1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/microshift-greenboot-microshift-health-script.adoc
2024-09-11 17:50:44 +00:00

59 lines
1.9 KiB
Plaintext

// Module included in the following assemblies:
//
// * microshift_install_get_ready/microshift-greenboot.adoc
:_mod-docs-content-type: CONCEPT
[id="microshift-health-script_{context}"]
= The {microshift-short} health check script
The `40_microshift_running_check.sh` health check script only performs validation of core {microshift-short} services. Install your customized workload health check scripts in the greenboot directories to ensure successful application operations after system updates. Scripts run in alphabetical order.
{microshift-short} health checks are listed in the following table:
.Validation statuses and outcome for {microshift-short}
[cols="3", options="header"]
|===
|Validation
|Pass
|Fail
|Check that the script runs with `root` permissions
|Next
|`exit 0`
|Check that the `microshift.service` is enabled
|Next
|`exit 0`
|Wait for the `microshift.service` to be active (!failed)
|Next
|`exit 1`
|Wait for Kubernetes API health endpoints to be working and receiving traffic
|Next
|`exit 1`
|Wait for any pod to start
|Next
|`exit 1`
|For each core namespace, wait for images to be pulled
|Next
|`exit 1`
|For each core namespace, wait for pods to be ready
|Next
|`exit 1`
|For each core namespace, check if pods are not restarting
|`exit 0`
|`exit 1`
|===
[id="validation-wait-period_{context}"]
== Validation wait period
The wait period in each validation is five minutes by default. After the wait period, if the validation has not succeeded, it is declared a failure. This wait period is incrementally increased by the base wait period after each boot in the verification loop.
* You can override the base-time wait period by setting the `MICROSHIFT_WAIT_TIMEOUT_SEC` environment variable in the `/etc/greenboot/greenboot.conf` configuration file. For example, you can change the wait time to three minutes by resetting the value to 180 seconds, such as `MICROSHIFT_WAIT_TIMEOUT_SEC=180`.