Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Install Using Advanced Cluster Management

SUMMARY Learn how to install CN2 using Advanced Cluster Management (ACM).

The procedures in this section show how you can install or import a CN2 cluster using ACM.

Before proceeding, you need to create an ACM hub cluster. See Create an ACM Hub Cluster for an example of how to create a hub cluster. The hub cluster provides the ACM functionality. It does not contain any CN2 components.

Install with User-Managed Networking Using ACM

Use this procedure to bring up an OpenShift cluster with user-managed networking using ACM. User-managed networking refers to a deployment where you explicitly provide an external load balancer for your installation.

Ensure you've set up the ACM hub cluster before you start this procedure.

  1. Copy the kubeconfig of the hub cluster to the default kubeconfig location (~/.kube/config) on the installation computer where you're running this procedure.
  2. Prepare the deployment by setting up an SSH key and downloading the pull secret.
    1. Create an SSH key that you'll use to access the nodes in your cluster.
      We're leaving the SSH key in its default location ~/.ssh/id_rsa.pub.
    2. Download the image pull secret from your Red Hat account onto your local computer. The pull secret allows your installation to access services and registries that serve container images for OpenShift components.

      You can download the pull secret file (pull-secret) from the https://console.redhat.com/openshift/downloads page.

  3. Create the namespace that you'll use for the managed cluster configuration.
    We'll call the namespace mgmt-spoke1.
  4. Convert all the CN2 manifests that you plan to use to ConfigMaps.
    Here's an example of the ConfigMap for the 110-vroutermasters-cr.yaml manifest. The ConfigMap structure contains the contents of 110-vroutermasters-cr.yaml in the data section.
    For convenience, we provide a script that performs the manifest-to-ConfigMap conversions:
    1. First, create a template file that provides the ConfigMap structure.
      We'll call this file TEMPLATE.
    2. Create the following bash script that steps through each CN2 manifest and generates a ConfigMap based on the above template.
      Note:

      This script modifies the original CN2 manifests slightly. We recommend you make a copy of the original manifests before proceeding.

      The script below steps through all the YAML files in the SRC_DIR directory and creates a corresponding ConfigMap for each manifest by applying the TEMPLATE and appending the contents of the original YAML file. The script places the resulting ConfigMap files into the DST_DIR directory.
      We'll call the script convert-manifests.sh. Modify the SRC_DIR and DST_DIR variables in the script as needed. Ensure that the SRC_DIR only contains the CN2 manifests that you want to use. See Manifests for a description of the CN2 manifests that we provide.Make the script executable.
    3. Run the script.
  5. Apply the ConfigMaps.
    Run the following commands from the DST_DIR directory, which is /home/cn2/tmp/config-maps in our example.
  6. Create and apply the manifest for the managed cluster.
    1. Create the manifest.
      Here's an example of a manifest that has 3 control plane nodes and 2 worker nodes, and subnets consistent with other examples in this document:
      • machine network cidr - 172.16.0.0/24

      • cluster network cidr - 10.128.0.0/14

      • service network cidr - 172.31.0.0/16

      We'll call it mgmt-spoke1.yaml.where:
      • <pull-secret> is the contents of the pull-secret file you downloaded from Red Hat earlier

      • <cluster_ssh_key> is the contents of the ~/.ssh/id_rsa.pub file you created earlier

      • <ignition-config> is the string below:

        This string contains an encoded script that configures the extended API server with the proper certificate.

    2. Apply the manifest.
  7. Get the download URL for the ISO image for the managed cluster nodes.
  8. Download the ISO image.
  9. Boot up the cluster nodes with the downloaded ISO image.
  10. Use the following commands to monitor the progress of the installation.
    You can also monitor the installation on the ACM UI.

Import an Existing CN2 Cluster to ACM

The procedure to import a cluster to ACM is the same whether you're importing a CN2 cluster or a non-CN2 cluster.

See Import an Existing Cluster to ACM for an example of how you can import a cluster.

Ensure you've set up the ACM hub cluster before you start this procedure.