Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Installing Containerized Contrail Using Server Manager Lite (SM-Lite)

Server Manager Lite (SM-Lite) is a streamlined version of Server Manager. SM-Lite has functionality similar to Server Manager, except it does not perform reimaging. SM-Lite is typically used for Contrail networking only.

You can use Contrail Server Manager or Server Manager Lite (SM-Lite) to provision containerized Contrail. To use SM-Lite for provisioning, you install regular Server Manager, then use SM-Lite commands for provisioning.

This topic is the procedure for installing and provisioning Contrail 4.0 and later using SM-Lite.

The SM-Lite installation of containerized Contrail is completed using the following major activities:

Preparing for SM-Lite Installation

For Contrail 4.0, SM-Lite install is only supported on Ubuntu 14.04.5. Contrail 4.1 adds support for Ubuntu 16.04.2.

Before installing containerized Contrail, you must install Server Manager SM-Lite on a server running a supported version of Ubuntu.

You can install SM-Lite on any server or node, and you can run it using multiple options:

  • Provision a single node or VM for Contrail, then install SM-Lite on the same node and use it to perform Contrail provisioning.

  • Use a separate node or VM to install SM-Lite, and provision Contrail with the rest of the nodes.

  • Use a node or VM that has Contrail roles (typically a config node) to install SM-Lite.

To specify servers and associated Contrail roles and cluster details, you can use either a testbed.py or JSONs based on the sample JSONs used with regular Server Manager. The image details come from the image JSON.

Prerequisites

Before installing the SM-Lite package, ensure the following cautions have been met:

  • Ensure that the sources.list is present and empty.

  • Ensure that /etc/apt/sources.list.d/ is not pointing to any external or local repositories.

If you are installing SM-Lite on a VM spawned from OpenStack Horizon or from an Ubuntu cloud image:

  • Verify that the VM is set up correctly with hostname and domain details:

    • The hostname and domain name are present in /etc/hosts as follows:

      <Host non mgmt IP> <server hostname>.<domain_name> <server hostname>

    • The domain name is present in /etc/resolv.conf as follows:

      search <domain_name>

  • When correctly set up, the command "hostname -f" will return < hostname >.< domain_name >

Installing SM-Lite

  1. Install the regular Server Manager wrapper package (Debian).( An example package is: contrail-server-manager-installer_2.22~juno_all.deb.)

    dpkg –i </github-build/mainline/<build_number> /ubuntu-14-04/mitaka/artifacts/ contrail-server-manager-installer_4.0.0.0-<build-number>~mitaka_all.deb>

  2. Now you can use the SM-Lite provision_containers command to provision Contrail.

    The full syntax and available options of the provision_containers.sh script:

    The -ni option is used to reprovision an existing cluster, create a new cluster, or upgrade an existing cluster with a different version.

For more details about SM-Lite, refer to Installing and Using Server Manager Lite.

Provisioning Contrail Using SM-Lite

To activate SM-Lite and provision the target systems, use provision_containers.sh along with system-specific configuration information.

Provision Contrail with system-specific configuration information using one of the following options:

  • Using JSONs

    /opt/contrail/contrail_server_manager/provision_containers.sh -cj <cluster json path> -sj <server json path> -ij <image json path> --cluster-id <Cluster ID>

  • Using testbed.py and contrail-docker-cloud.tgz

    /opt/contrail/contrail_server_manager/provision_containers.sh -t <testbed.py path> -c <contrail-cloud-docker tgz path> --cluster-id <Cluster ID>

The SM-Lite provisioning logs can be viewed at /var/log/contrail-server-manager/debug.log.

Running the provision_containers.sh script does the following:

  1. Installs SM-Lite components: sm client, sm webui, sm monitoring/inventory, and the like.

  2. Prepares the targets for provisioning by running the preconfig.py script.

  3. Adds Server Manager objects for cluster, server, and image from the JSONs or the testbed.py as provided.

  4. Loads Docker containers and pushes them to the registry in the background.

  5. Launches the Contrail provisioning, using the Server Manager client CLI.

Sample JSONs and Testbed.py

Use the SM-Lite command provision_containers.sh with a JSON file or a testbed.py to provision Contrail objects.

Configure an appropriate JSON file or testbed.py with the IP addresses, interface names, and password strings specific to your system, then identify its path when you use the SM-Lite provision_containers.sh command.

Select a sample JSON or testbed.py from the following and update it to match your system: