Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Run Preflight and Postflight Checks

SUMMARY Learn about Contrail preflight and postflight checks.

Preflight checks allow you to verify that your cluster nodes can support Contrail. The checks test for resource capacity, kernel compability, network reachability, and other infrastructure requirements. You run preflight checks prior to installing Contrail.

Postflight checks allow you to verify that your Contrail installation is working properly. The checks test for status, pod-to-pod communication, API server reachability, and other basic functions. You run postflight checks after installing Contrail. Contrail supports postflight checks starting in release 22.2.

Run Preflight Checks in Release 22.1

In Release 22.1, we provide a preflight check script that you run on each node in the cluster. The script checks to see if the cluster node is able to run the deployer manifest that you want to apply to that node.

  1. Locate the preflight.sh script and the manifest that you want to apply from the downloaded package.
  2. Copy the script and the manifest(s) you plan on using to every node in the cluster. You're not applying the manifest yet. You're just making the manifest available for the preflight.sh script to read.
  3. Log in as root to each node in the cluster and run the script.

    where <deployer-manifest>.yaml is the name of the manifest(s) that you plan to apply to this node.

    The script checks to make sure that the node is capable of supporting the resources required by the <deployer-manifest>.yaml file.

    Address any errors flagged by the script before proceeding.

Run Preflight and Postflight Checks in Release 22.2

In release 22.2, we provide a custom controller that performs preflight and postflight checks on all cluster nodes. The controller runs the checks defined in custom resources that we provide. You create and run the controller in the same way you run other Kubernetes applications. You no longer need to log in to each cluster node to run the checks.

  1. Locate the contrail-tools/contrail-readiness directory from the downloaded Contrail Manifests and Tools package.
  2. If you haven't already done so, ensure you've populated the manifests with your repository login credentials. See Configure Repository Credentials for one way to do this.
  3. Apply the ContrailReadiness custom resource definitions.
  4. Create the ConfigMap from the deployer manifest that you want to apply to this cluster. Name the ConfigMap deployer-yaml.
    where <path_to_deployer_manifest> is the full path to the deployer manifest that you want to apply.
  5. Create the ContrailReadiness controller.

    Wait for the controller to come up.

  6. Run the checks.
    • To run the preflight checks:You run preflight checks after you create the cluster but before you install Contrail.
    • To run the postflight checks:You run postflight checks after you install Contrail.
      Note:

      In a multi-cluster deployment, run postflight checks from the central cluster only.

  7. Read the preflight and postflight check results as applicable.

    Address any errors before proceeding.

    Note:

    The preflight and postflight checks do not automatically rerun after you've fixed any errors. The output will continue to show errors even after you've fixed them.

Run Preflight and Postflight Checks in Release 22.3

In release 22.3, we provide a custom controller that performs preflight and postflight checks on all cluster nodes. The controller runs the checks defined in custom resources that we provide. You create and run the controller in the same way you run other Kubernetes applications.

  1. Locate the contrail-tools/contrail-readiness directory from the downloaded Contrail Manifests and Tools package.
  2. If you haven't already done so, ensure you've populated the manifests with your repository login credentials. See Configure Repository Credentials for one way to do this.
  3. Apply the ContrailReadiness custom resource definitions.
  4. Create the ConfigMap from the deployer manifest that you want to apply to this cluster. Name the ConfigMap deployer-yaml.
    where <path_to_deployer_manifest> is the full path to the deployer manifest that you want to apply.
  5. Patch the ConfigMap with the registry information.
  6. Create the ContrailReadiness controller.

    Wait for the controller to come up.

  7. Run the checks.
    • To run the preflight checks:You run preflight checks after you create the cluster but before you install Contrail.
    • To run the postflight checks:You run postflight checks after you install Contrail.
      Note:

      In a multi-cluster deployment, run postflight checks from the central cluster only.

  8. Read the preflight and postflight check results as applicable.

    Address any errors before proceeding.

    Note:

    The preflight and postflight checks do not automatically rerun after you've fixed any errors. The output will continue to show errors even after you've fixed them.