contrail agent #22

Supports: xenial bionic
Add to new model

Description

Contrail vRouter agent


Overview

OpenContrail (www.opencontrail.org) is a fully featured Software Defined Networking (SDN) solution for private clouds. It supports high performance isolated tenant networks without requiring external hardware support. It provides a Neutron plugin to integrate with OpenStack.

This charm is designed to be used in conjunction with the rest of the OpenStack related charms in the charm store to virtualize the network that Nova Compute instances plug into.

This subordinate charm provides the vRouter component which contains the contrail-vrouter-agent service. It can be related to any charm to provide vRouter functionality on the node. For OpenStack it should be nova-compute application to provide vRouter functionality for OpenStack.

Only OpenStack Ocata or newer is supported. Only for Contrail 5.0 or above. Juju 2.0 is required.

Usage

Contrail Controller are prerequisite service to deploy.

Once ready, deploy and relate as follows:

juju deploy contrail-agent
juju add-relation contrail-agent:juju-info nova-compute:juju-info
juju add-relation contrail-agent contrail-controller

Install Sources

The version of packages installed when deploying must be configured using the 'install-sources' option. This is a multilined value that may refer to PPAs or Deb repositories.

Control Node Relation

This charm is typically related to contrail-controller. This instructs the Contrail vRouter agent to use the API endpoints for locating needed information.

DPDK mode

This charm supports DPDK mode of Contrail vrouter. DPDK mode requires more than one ethernet adapters. User have to configure control-network and physical-interface properly for correct work. For example system has ens3 interface with network 10.0.0.0/24 and default gateway is in this network and ens4 interface. Configuration can be applied as follows:

juju config dpdk=True physical-interface=ens4 control-network=10.0.0.0/24

User have to configure hugepages and unset it in charm configuration or let the charm configure amount of it. User can provide coremask for DPDK driver. Also user have to provide correct UIO driver's name. Charm tries to load it at install stage and raises an error if kernel module can't be loaded.

Repository for this charm and for contrail-openstack charm must additionaly contain Contrail's version for packages: nova-, python-nova, libvirt

Plugin option

This charm can be linked with any plugin by vrouter-plugin relation. With option wait-for-external-plugin code will wait for ready flag in the relation. This charm accepts 'settings' value as a serialized dict to json in relation. All these option will be serilized to container settings and then into contrail-vrouter-agent.conf. Example of dict: {"DEFAULT": {"key1": "value1"}, "SECTION_2": {"key1": "value1"}}

Kubernetes

This charm can be used with The Charmed Distribution Of Kubernetes. In this case relation must be set to Kubernetes Worker instead of the nova-compute:

juju add-relation contrail-agent:juju-info kubernetes-worker:juju-info

SSL

This charm supports relation to easyrsa charm to obtain certificates for XMPP and Sandesh connections:

juju add-relation contrail-agent easyrsa

Please note that in this case all charms must be related to easyrsa. Components require CA certificate for communication.


Configuration

csn-mode
(string) The vrouter agent mode. The valid values are 'tor'/'tsn'/'tsn-no-forwarding' or empty.
docker-log-driver
(string) A logging driver for the service’s containers.
json-file
docker-log-options
(string) Logging options for the logging driver. Logging options available depend on which logging driver you use.
max-size=20m max-file=5
docker-opts
(string) Extra options to pass to the Docker config file '/etc/docker/daemon.json' in json format. e.g. {"iptables": false, "insecure-registries": ["host2", "tungstenfabric", "host1"]}
docker-password
(string) Password to the docker registry.
docker-registry
(string) URL of docker-registry
opencontrailnightly
docker-registry-insecure
(boolean) Is it docker-registry insecure and should docker be configured for it
docker-user
(string) Login to the docker registry.
docker_runtime
(string) Docker runtime to install valid values are "upstream" (Docker PPA), "apt" (Ubuntu archive), "auto" (Ubuntu archive), or "custom" (must have set `docker_runtime_repo` URL, `docker_runtime_key_url` URL and `docker_runtime_package` name). Warning! The changes will not be applied after the package is installed.
upstream
docker_runtime_key_url
(string) Custom Docker repository validation key URL. Warning! The changes will not be applied after the package is installed.
docker_runtime_package
(string) Custom Docker repository package name. Warning! The changes will not be applied after the package is installed.
docker_runtime_repo
(string) Custom Docker repository, given in deb format. Use `{ARCH}` to determine architecture at runtime. Use `{CODE}` to set release codename. E.g. `deb [arch={ARCH}] https://download.docker.com/linux/ubuntu {CODE} stable`. Warning! The changes will not be applied after the package is installed.
dpdk
(boolean) Use user space DPDK vRouter
dpdk-coremask
(string) vRouter CPU affinity mask for dpdk forwarding threads. Value can be specified as either a hexidecimal bitmask e.g. 0xF or as a numbered list separated by commas e.g. 0,1 (ranges are also supported using '-' e.g. 0-2). It must specify only real cores cause contrail-vrouter-dpdk service will fail if specified core number is not present in the system.
1
dpdk-ctrl-thread-coremask
(string) vRouter DPDK CPU affinity mask for dpdk ctrl threads. Value can be specified as either a hexidecimal bitmask e.g. 0xF or as a numbered list separated by commas e.g. 0,1 (ranges are also supported using '-' e.g. 0-2). It must specify only real cores cause contrail-vrouter-dpdk service will fail if specified core number is not present in the system. Supported from Contrail release 2003 and R1912.L2.
1
dpdk-driver
(string) DPDK driver to use for physical interface. Interface can be specified using vhost-interface.
uio_pci_generic
dpdk-hugepages
(string) Number of huge pages to reserve for use with DPDK vRouter and OpenStack instances. Value can be specified as percentage of system memory e.g. 70% or as number of huge pages e.g. 1434.
70%
dpdk-main-mempool-size
(string) Main packet pool size.
dpdk-pmd-rxd-size
(string) DPDK PMD Rx Descriptor size.
dpdk-pmd-txd-size
(string) DPDK PMD Tx Descriptor size.
dpdk-rx-ring-sz
(string) vRouter DPDK option to configure for forwarding lcores rx ring buffer size. If not there is default in dpdk bin is used which is 1024. Supported from Contrail release 2003 and R1912.L2.
dpdk-service-coremask
(string) vRouter DPDK CPU affinity mask for dpdk service threads. Value can be specified as either a hexidecimal bitmask e.g. 0xF or as a numbered list separated by commas e.g. 0,1 (ranges are also supported using '-' e.g. 0-2). It must specify only real cores cause contrail-vrouter-dpdk service will fail if specified core number is not present in the system. Supported from Contrail release 2003 and R1912.L2.
1
dpdk-tx-ring-sz
(string) vRouter DPDK option to configure for forwarding lcores tx ring buffer size. If not there is default in dpdk bin is used which is 1024. Supported from Contrail release 2003 and R1912.L2.
dpdk-yield-option
(string) vRouter DPDK option to disable/enable yield on forwarding lcores. Allowed values 0 / 1. If not set the default behaviour is enalbed (1). Supported from Contrail release 2003 and R1912.L2.
hostname-use-fqdn
(boolean) Use fqdn for vrouter_hostname or use gethostname instead. fqdn is used in R5.1 and in further releases. R5.0 releases used hostname that doesn’t always return the fully qualified domain name.
True
http_proxy
(string) URL to use for HTTP_PROXY to be used by Docker. Only useful in closed environments where a proxy is the only option for routing to the registry to pull images
https_proxy
(string) URL to use for HTTPS_PROXY to be used by Docker. Only useful in closed environments where a proxy is the only option for routing to the registry to pull images
image-tag
(string) Tag of docker image.
latest
kernel-hugepages-1g
(string) Number of 1 GB huge pages to reserve for use with vRouter in kernel mode and OpenStack instances. Value can be specified as number of huge pages e.g. 10. To turn off HP suppor completely kernel-hugepages-1g and kernel-hugepages-2m must be set as '0' both. Supported from Contrail release 2005.
kernel-hugepages-2m
(string) Number of 2 MB huge pages to reserve for use with vRouter in kernel mode and OpenStack instances. Value can be specified as number of huge pages e.g. '1024'. To turn off HP suppor completely kernel-hugepages-1g and kernel-hugepages-2m must be set as '0' both. Supported from Contrail release 2005.
1024
log-level
(string) Log level for contrail services. Valid values are: SYS_EMERG, SYS_ALERT, SYS_CRIT, SYS_ERR, SYS_WARN, SYS_NOTICE, SYS_INFO, SYS_DEBUG
SYS_NOTICE
max-vm-flows
(string) Maximum flows allowed per VM (given as % of maximum system flows)
nagios_context
(string) Used by the nrpe subordinate charms. A string that will be prepended to instance name to set the host name in nagios. So for instance the hostname would be something like juju-myservice-0 If you're running multiple environments with the same services in them this allows you to differentiate between them.
juju
nagios_servicegroups
(string) A comma-separated list of nagios servicegroups. If left empty, the nagios_context will be used as the servicegroup
no_proxy
(string) Comma-separated list of destinations (either domain names or IP addresses) that should be directly accessed, by opposition of going through the proxy defined above. Must be less than 2023 characters long
physical-interface
(string) Specify the interface to install vhost0 on. If left empty, vhost0 will be installed on the default gateway interface.
sriov-numvfs
(string) A comma-separated list of NumVFS's for specified devices. The number of elements in the list should be equal to number of elements in sriov-physical-interface. List is supported only by R2008 release and further. For previous releases only first element will be taken. This parameter and sriov-physical-interface will be passed into agent container that will configure SR-IOV.
sriov-physical-interface
(string) A comma-separated list of interface names for SR-IOV. The number of elements in the list should be equal to number of elements in sriov-numvfs. List is supported only by R2008 release and further. For previous releases only first element will be taken. This parameter and sriov-numvfs will be passed into agent container that will configure SR-IOV.
vhost-gateway
(string) Specify the gateway for vhost0, either an IPv4 address or keyword 'auto'. 'auto' will set gateway automatically.
auto
wait-for-external-plugin
(boolean)