Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Installing OpenStack Octavia LBaaS with Juju Charms in Contrail Networking

Contrail Networking Release 2005 supports Octavia as LBaaS. The deployment supports RHOSP and Juju platforms.

With Octavia as LBaaS, Contrail Networking is only maintaining network connectivity and is not involved in any load balancing functions.

For each OpenStack load balancer creation, Octavia launches a VM known as amphora VM. The VM starts the HAPROXY when listener is created for the load balancer in OpenStack. Whenever the load balancer gets updated in OpenStack, amphora VM updates the running HAPROXY configuration. The amphora VM is deleted on deleting the load balancer.

Contrail Networking provides connectivity to amphora VM interfaces. Amphora VM has two interfaces; one for management and the other for data. The management interface is used by the Octavia services for the management communication. Since, Octavia services are running in the underlay network and amphora VM is running in the overlay network, SDN gateway is needed to reach the overlay network. The data interface is used for load balancing.

Follow the procedure to install OpenStack Octavia LBaaS in Canonical deployment:

  1. Prepare Juju setup with OpenStack Train version and Octavia overlay bundle.

    Refer to #installing-openstack-octavia-lbaas-with-juju-charms-in-contrail-networking__SampleOctavia-bundle.yamlFile output.

    or

    Add Octavia service after deploying the main bundle on the existing cluster.

  2. Prepare ssh key for amphora VM. Add the options in the octavia-bundle.yaml file.

    Add the following options to Octavia options.

  3. Generate certificates.

    Make sure all the units are in active or blocked state.

  4. Configure vault service.
    1. SSH into the machine where vault service is installed.
    2. Export vault address and run init.

      It will print 5 unseal keys and initial root token.

    3. Call unseal command by using any three of the five printed unseal keys.
    4. Export initial root token.
    5. Create user token.
    6. Exit from vault’s machine and initialize vault’s charm with the user token.
  5. Create amphora image.
  6. Install python-openstackclient and python-octaviaclient and create management network for Octavia.

    You must create these objects in services project.

  7. The management network created in step 6 is in overlay network and Octavia services are running in the underlay network. Verify network connectivity between overlay and underlay network via SDN gateway.
  8. Configure Octavia with the created network.

    Make sure the juju cluster is functional and all units have active status.

If you want to run amphora instances on DPDK computes, you have to create your own flavor with the required options and set the ID to configuration of Octavia charm via custom-amp-flavor-id option before call configure-resources. OrSet the required options to created flavor with name charm-octavia by charm

Here is an example for creating and testing load balancer:

Prerequisites:

  • You must have connectivity between Octavia controller and amphora instances,

  • You must have OpenStack services into LXD containers.

  • You must have separate interfaces for control plane and data plane.

  1. Create private network.

  2. Create security group.

  3. Check available flavors and images. You can create them, if needed.

  4. Create two servers for load balancer.

  5. Create additional server to test load balancer.

  6. Check status and IP addresses.

  7. Create simple HTTP server on every cirros. Login on both the cirros instances and run following commands:

  8. Create load balancer

    Make sure provisioning_status is Active.

  9. Setup load balancer

    IP addresses 10.10.10.50 and 10.10.10.51 belong to VMs created with test http server in step 7.

  10. Check the status of load balancer.

  11. Login to load balancer client and verify if round robin works.

Sample octavia-bundle.yaml file

Release History Table
Release
Description
2005
Contrail Networking Release 2005 supports Octavia as LBaaS.