From cbd67ebdb1c1b77d4fa5ad0398ead5b8f98bb67e Mon Sep 17 00:00:00 2001 From: chenxing Date: Mon, 24 Jul 2017 23:28:39 +0800 Subject: Rearrange existing documentation to fit the new standard layout For more detail, see the doc migration spec. http://specs.openstack.org/openstack/docs-specs/specs/pike/os-manuals-migration.html Co-Authored-By: Eduardo Gonzalez Change-Id: I3a7c0ed204ee1e9060b5325f20622afe9a5e3040 --- doc/CONTRIBUTING.rst | 133 ---- doc/advanced-configuration.rst | 231 ------- doc/bifrost.rst | 475 -------------- doc/bug-triage.rst | 8 - doc/central-logging-guide.rst | 156 ----- doc/ceph-guide.rst | 360 ----------- doc/cinder-guide-hnas.rst | 231 ------- doc/cinder-guide.rst | 166 ----- doc/conf.py | 90 --- doc/deployment-philosophy.rst | 76 --- doc/designate-guide.rst | 122 ---- doc/external-ceph-guide.rst | 202 ------ doc/hyperv-guide.rst | 174 ------ doc/index.rst | 90 --- doc/ironic-guide.rst | 75 --- doc/kolla-for-openstack-development.rst | 76 --- doc/kollanet.png | Bin 26014 -> 0 bytes doc/kuryr-guide.rst | 63 -- doc/manila-guide.rst | 357 ----------- doc/manila-hnas-guide.rst | 330 ---------- doc/multi-regions.rst | 144 ----- doc/multinode.rst | 210 ------- doc/networking-guide.rst | 350 ----------- doc/nova-fake-driver.rst | 37 -- doc/operating-kolla.rst | 129 ---- doc/osprofiler-guide.rst | 57 -- doc/production-architecture-guide.rst | 120 ---- doc/quickstart.rst | 693 --------------------- doc/running-tests.rst | 106 ---- doc/security.rst | 56 -- doc/skydive-guide.rst | 37 -- doc/source/conf.py | 90 +++ doc/source/contributor/CONTRIBUTING.rst | 133 ++++ doc/source/contributor/bug-triage.rst | 8 + doc/source/contributor/index.rst | 10 + doc/source/contributor/running-tests.rst | 106 ++++ doc/source/contributor/vagrant-dev-env.rst | 190 ++++++ doc/source/index.rst | 59 ++ doc/source/reference/bifrost.rst | 475 ++++++++++++++ doc/source/reference/central-logging-guide.rst | 156 +++++ doc/source/reference/ceph-guide.rst | 360 +++++++++++ doc/source/reference/cinder-guide-hnas.rst | 231 +++++++ doc/source/reference/cinder-guide.rst | 166 +++++ doc/source/reference/designate-guide.rst | 122 ++++ doc/source/reference/external-ceph-guide.rst | 202 ++++++ doc/source/reference/hyperv-guide.rst | 174 ++++++ doc/source/reference/index.rst | 26 + doc/source/reference/ironic-guide.rst | 75 +++ doc/source/reference/kollanet.png | Bin 0 -> 26014 bytes doc/source/reference/kuryr-guide.rst | 63 ++ doc/source/reference/manila-guide.rst | 357 +++++++++++ doc/source/reference/manila-hnas-guide.rst | 330 ++++++++++ doc/source/reference/networking-guide.rst | 350 +++++++++++ doc/source/reference/nova-fake-driver.rst | 37 ++ doc/source/reference/osprofiler-guide.rst | 57 ++ doc/source/reference/skydive-guide.rst | 37 ++ doc/source/reference/swift-guide.rst | 192 ++++++ doc/source/reference/tacker-guide.rst | 168 +++++ doc/source/reference/vmware-guide.rst | 251 ++++++++ doc/source/reference/zun-guide.rst | 113 ++++ doc/source/user/advanced-configuration.rst | 231 +++++++ doc/source/user/deployment-philosophy.rst | 76 +++ doc/source/user/index.rst | 16 + .../user/kolla-for-openstack-development.rst | 76 +++ doc/source/user/multi-regions.rst | 144 +++++ doc/source/user/multinode.rst | 210 +++++++ doc/source/user/operating-kolla.rst | 129 ++++ doc/source/user/production-architecture-guide.rst | 120 ++++ doc/source/user/quickstart.rst | 693 +++++++++++++++++++++ doc/source/user/security.rst | 56 ++ doc/source/user/troubleshooting.rst | 97 +++ doc/swift-guide.rst | 192 ------ doc/tacker-guide.rst | 168 ----- doc/troubleshooting.rst | 97 --- doc/vagrant-dev-env.rst | 190 ------ doc/vmware-guide.rst | 251 -------- doc/zun-guide.rst | 113 ---- setup.cfg | 2 +- 78 files changed, 6387 insertions(+), 6366 deletions(-) delete mode 100644 doc/CONTRIBUTING.rst delete mode 100644 doc/advanced-configuration.rst delete mode 100644 doc/bifrost.rst delete mode 100644 doc/bug-triage.rst delete mode 100644 doc/central-logging-guide.rst delete mode 100644 doc/ceph-guide.rst delete mode 100644 doc/cinder-guide-hnas.rst delete mode 100644 doc/cinder-guide.rst delete mode 100644 doc/conf.py delete mode 100644 doc/deployment-philosophy.rst delete mode 100644 doc/designate-guide.rst delete mode 100644 doc/external-ceph-guide.rst delete mode 100644 doc/hyperv-guide.rst delete mode 100644 doc/index.rst delete mode 100644 doc/ironic-guide.rst delete mode 100644 doc/kolla-for-openstack-development.rst delete mode 100644 doc/kollanet.png delete mode 100644 doc/kuryr-guide.rst delete mode 100644 doc/manila-guide.rst delete mode 100644 doc/manila-hnas-guide.rst delete mode 100644 doc/multi-regions.rst delete mode 100644 doc/multinode.rst delete mode 100644 doc/networking-guide.rst delete mode 100644 doc/nova-fake-driver.rst delete mode 100644 doc/operating-kolla.rst delete mode 100644 doc/osprofiler-guide.rst delete mode 100644 doc/production-architecture-guide.rst delete mode 100644 doc/quickstart.rst delete mode 100644 doc/running-tests.rst delete mode 100644 doc/security.rst delete mode 100644 doc/skydive-guide.rst create mode 100644 doc/source/conf.py create mode 100644 doc/source/contributor/CONTRIBUTING.rst create mode 100644 doc/source/contributor/bug-triage.rst create mode 100644 doc/source/contributor/index.rst create mode 100644 doc/source/contributor/running-tests.rst create mode 100644 doc/source/contributor/vagrant-dev-env.rst create mode 100644 doc/source/index.rst create mode 100644 doc/source/reference/bifrost.rst create mode 100644 doc/source/reference/central-logging-guide.rst create mode 100644 doc/source/reference/ceph-guide.rst create mode 100644 doc/source/reference/cinder-guide-hnas.rst create mode 100644 doc/source/reference/cinder-guide.rst create mode 100644 doc/source/reference/designate-guide.rst create mode 100644 doc/source/reference/external-ceph-guide.rst create mode 100644 doc/source/reference/hyperv-guide.rst create mode 100644 doc/source/reference/index.rst create mode 100644 doc/source/reference/ironic-guide.rst create mode 100644 doc/source/reference/kollanet.png create mode 100644 doc/source/reference/kuryr-guide.rst create mode 100644 doc/source/reference/manila-guide.rst create mode 100644 doc/source/reference/manila-hnas-guide.rst create mode 100644 doc/source/reference/networking-guide.rst create mode 100644 doc/source/reference/nova-fake-driver.rst create mode 100644 doc/source/reference/osprofiler-guide.rst create mode 100644 doc/source/reference/skydive-guide.rst create mode 100644 doc/source/reference/swift-guide.rst create mode 100644 doc/source/reference/tacker-guide.rst create mode 100644 doc/source/reference/vmware-guide.rst create mode 100644 doc/source/reference/zun-guide.rst create mode 100644 doc/source/user/advanced-configuration.rst create mode 100644 doc/source/user/deployment-philosophy.rst create mode 100644 doc/source/user/index.rst create mode 100644 doc/source/user/kolla-for-openstack-development.rst create mode 100644 doc/source/user/multi-regions.rst create mode 100644 doc/source/user/multinode.rst create mode 100644 doc/source/user/operating-kolla.rst create mode 100644 doc/source/user/production-architecture-guide.rst create mode 100644 doc/source/user/quickstart.rst create mode 100644 doc/source/user/security.rst create mode 100644 doc/source/user/troubleshooting.rst delete mode 100644 doc/swift-guide.rst delete mode 100644 doc/tacker-guide.rst delete mode 100644 doc/troubleshooting.rst delete mode 100644 doc/vagrant-dev-env.rst delete mode 100644 doc/vmware-guide.rst delete mode 100644 doc/zun-guide.rst diff --git a/doc/CONTRIBUTING.rst b/doc/CONTRIBUTING.rst deleted file mode 100644 index 7092cd88b..000000000 --- a/doc/CONTRIBUTING.rst +++ /dev/null @@ -1,133 +0,0 @@ -.. _CONTRIBUTING: - -================= -How To Contribute -================= - -Basics -====== - -#. Our source code is hosted on `OpenStack Kolla-Ansible Git`_. Bugs should be - filed on launchpad_. - -#. Please follow OpenStack `Gerrit Workflow`_ to contribute to Kolla. - -#. Note the branch you're proposing changes to. ``master`` is the current focus - of development. Kolla project has a strict policy of only allowing backports - in ``stable/branch``, unless when not applicable. A bug in a - ``stable/branch`` will first have to be fixed in ``master``. - -#. Please file a launchpad_ blueprint for any significant code change and a bug - for any significant bug fix or add a TrivialFix tag for simple changes. - See how to reference a bug or a blueprint in the commit message here_ - -#. TrivialFix tags or bugs are not required for documentation changes. - -.. _OpenStack Kolla-Ansible Git: https://git.openstack.org/cgit/openstack/kolla-ansible/ -.. _launchpad: https://bugs.launchpad.net/kolla-ansible -.. _here: https://wiki.openstack.org/wiki/GitCommitMessages - -Development Environment -======================= - -Please follow our `quickstart`_ to deploy your environment and test your -changes. - -.. _quickstart: https://docs.openstack.org/kolla-ansible/latest/quickstart.html - -Please use the existing sandbox repository, available at -https://git.openstack.org/cgit/openstack-dev/sandbox, for learning, understanding -and testing the `Gerrit Workflow`_. - -.. _Gerrit Workflow: https://docs.openstack.org/infra/manual/developers.html#development-workflow - -Adding a new service -==================== - -Kolla aims to both containerise and deploy all services within the OpenStack -"big tent". This is a constantly moving target as the ecosystem grows, so these -guidelines aim to help make adding a new service to Kolla a smooth experience. - -When adding a role for a new service in Ansible, there are couple of patterns -that Kolla uses throughout that should be followed. - -* The sample inventories - - Entries should be added for the service in each of - ``ansible/inventory/multinode`` and ``ansible/inventory/all-in-one``. - -* The playbook - - The main playbook that ties all roles together is in ``ansible/site.yml``, - this should be updated with appropriate roles, tags, and conditions. Ensure - also that supporting hosts such as haproxy are updated when necessary. - -* The common role - - A ``common`` role exists which sets up logging, ``kolla-toolbox`` and other - supporting components. This should be included in all services within - ``meta/main.yml`` of your role. - -* Common tasks - - All services should include the following tasks: - - - ``reconfigure.yml`` : Used to push new configuration files to the host - and restart the service. - - - ``pull.yml`` : Used to pre fetch the image into the Docker image cache - on hosts, to speed up initial deploys. - - - ``upgrade.yml`` : Used for upgrading the service in a rolling fashion. May - include service specific setup and steps as not all services can be - upgraded in the same way. - -* Logrotation - - - For OpenStack services there should be a ``cron-logrotate-PROJECT.conf.j2`` - template file in ``ansible/roles/common/templates`` with the following - content: - - .. code:: - - "/var/log/kolla/PROJECT/*.log" - { - } - - - For OpenStack services there should be an entry in the ``services`` list - in the ``cron.json.j2`` template file in ``ansible/roles/common/templates``. - -* Log delivery - - - For OpenStack services the service should add a new ``rewriterule`` in the - ``match`` element in the ``01-rewrite.conf.j2`` template file in - ``ansible/roles/common/templates/conf/filter`` to deliver log messages to - Elasticsearch. - -* Documentation - - - For OpenStack services there should be an entry in the list - ``OpenStack services`` in the ``README.rst`` file. - - - For infrastructure services there should be an entry in the list - ``Infrastructure components`` in the ``README.rst`` file. - -* Syntax - - - All YAML data files should start with three dashes (``---``). - -Other than the above, most roles follow the following pattern: - - - ``Register``: Involves registering the service with Keystone, creating - endpoints, roles, users, etc. - - - ``Config``: Distributes the config files to the nodes to be pulled into - the container on startup. - - - ``Bootstrap``: Creating the database (but not tables), database user for - the service, permissions, etc. - - - ``Bootstrap Service``: Starts a one shot container on the host to create - the database tables, and other initial run time config. - - - ``Start``: Start the service(s). diff --git a/doc/advanced-configuration.rst b/doc/advanced-configuration.rst deleted file mode 100644 index 0b97bff6b..000000000 --- a/doc/advanced-configuration.rst +++ /dev/null @@ -1,231 +0,0 @@ -.. _advanced-configuration: - -====================== -Advanced Configuration -====================== - -Endpoint Network Configuration -============================== - -When an OpenStack cloud is deployed, the REST API of each service is presented -as a series of endpoints. These endpoints are the admin URL, the internal -URL, and the external URL. - -Kolla offers two options for assigning these endpoints to network addresses: - - Combined - Where all three endpoints share the same IP address - - Separate - Where the external URL is assigned to an IP address that is - different than the IP address shared by the internal and admin URLs - -The configuration parameters related to these options are: - - kolla_internal_vip_address - - network_interface - - kolla_external_vip_address - - kolla_external_vip_interface - -For the combined option, set the two variables below, while allowing the -other two to accept their default values. In this configuration all REST -API requests, internal and external, will flow over the same network. :: - - kolla_internal_vip_address: "10.10.10.254" - network_interface: "eth0" - -For the separate option, set these four variables. In this configuration -the internal and external REST API requests can flow over separate -networks. :: - - kolla_internal_vip_address: "10.10.10.254" - network_interface: "eth0" - kolla_external_vip_address: "10.10.20.254" - kolla_external_vip_interface: "eth1" - -Fully Qualified Domain Name Configuration -========================================= - -When addressing a server on the internet, it is more common to use -a name, like www.example.net, instead of an address like 10.10.10.254. -If you prefer to use names to address the endpoints in your kolla -deployment use the variables: - - - kolla_internal_fqdn - - kolla_external_fqdn - -:: - - kolla_internal_fqdn: inside.mykolla.example.net - kolla_external_fqdn: mykolla.example.net - -Provisions must be taken outside of kolla for these names to map to the -configured IP addresses. Using a DNS server or the /etc/hosts file are -two ways to create this mapping. - -RabbitMQ Hostname Resolution -============================ - -RabbitMQ doesn't work with IP address, hence the IP address of api_interface -should be resolvable by hostnames to make sure that all RabbitMQ Cluster hosts -can resolve each others hostname beforehand. - -TLS Configuration -================= - -An additional endpoint configuration option is to enable or disable -TLS protection for the external VIP. TLS allows a client to authenticate -the OpenStack service endpoint and allows for encryption of the requests -and responses. - -.. note:: The kolla_internal_vip_address and kolla_external_vip_address must - be different to enable TLS on the external network. - -The configuration variables that control TLS networking are: - - - kolla_enable_tls_external - - kolla_external_fqdn_cert - -The default for TLS is disabled; to enable TLS networking: - -:: - - kolla_enable_tls_external: "yes" - kolla_external_fqdn_cert: "{{ node_config_directory }}/certificates/mycert.pem" - - -.. note:: TLS authentication is based on certificates that have been - signed by trusted Certificate Authorities. Examples of commercial - CAs are Comodo, Symantec, GoDaddy, and GlobalSign. Letsencrypt.org - is a CA that will provide trusted certificates at no charge. Many - company's IT departments will provide certificates within that - company's domain. If using a trusted CA is not possible for your - situation, you can use OpenSSL to create your own or see the section - company's domain. If using a trusted CA is not possible for your - situation, you can use `OpenSSL`_ to create your own or see the section - below about kolla generated self-signed certificates. - -Two certificate files are required to use TLS securely with authentication. -These two files will be provided by your Certificate Authority. These -two files are the server certificate with private key and the CA certificate -with any intermediate certificates. The server certificate needs to be -installed with the kolla deployment and is configured with the -``kolla_external_fqdn_cert`` parameter. If the server certificate provided -is not already trusted by the client, then the CA certificate file will -need to be distributed to the client. - -When using TLS to connect to a public endpoint, an OpenStack client will -have settings similar to this: - -:: - - export OS_PROJECT_DOMAIN_ID=default - export OS_USER_DOMAIN_ID=default - export OS_PROJECT_NAME=demo - export OS_USERNAME=demo - export OS_PASSWORD=demo-password - export OS_AUTH_URL=https://mykolla.example.net:5000 - # os_cacert is optional for trusted certificates - export OS_CACERT=/etc/pki/mykolla-cacert.crt - export OS_IDENTITY_API_VERSION=3 - -.. _OpenSSL: https://www.openssl.org/ - -Self-Signed Certificates -======================== - -.. note:: Self-signed certificates should never be used in production. - -It is not always practical to get a certificate signed by a well-known -trust CA, for example a development or internal test kolla deployment. In -these cases it can be useful to have a self-signed certificate to use. - -For convenience, the ``kolla-ansible`` command will generate the necessary -certificate files based on the information in the ``globals.yml`` -configuration file: - - :: - - kolla-ansible certificates - -The files haproxy.pem and haproxy-ca.pem will be generated and stored -in the ``/etc/kolla/certificates/`` directory. - -.. _service-config: - -OpenStack Service Configuration in Kolla -======================================== - -.. note:: As of now kolla only supports config overrides for ini based configs. - -An operator can change the location where custom config files are read from by -editing ``/etc/kolla/globals.yml`` and adding the following line. - -:: - - # The directory to merge custom config files the kolla's config files - node_custom_config: "/etc/kolla/config" - -Kolla allows the operator to override configuration of services. Kolla will -look for a file in ``/etc/kolla/config/<< service name >>/<< config file >>``. -This can be done per-project, per-service or per-service-on-specified-host. -For example to override scheduler_max_attempts in nova scheduler, the operator -needs to create ``/etc/kolla/config/nova/nova-scheduler.conf`` with content: - -:: - - [DEFAULT] - scheduler_max_attempts = 100 - -If the operator wants to configure compute node ram allocation ratio -on host myhost, the operator needs to create file -``/etc/kolla/config/nova/myhost/nova.conf`` with content: - -:: - - [DEFAULT] - ram_allocation_ratio = 5.0 - -The operator can make these changes after services were already deployed by -using following command: - -:: - - kolla-ansible reconfigure - -IP Address Constrained Environments -=================================== - -If a development environment doesn't have a free IP address available for VIP -configuration, the host's IP address may be used here by disabling HAProxy by -adding: - -:: - - enable_haproxy: "no" - -Note this method is not recommended and generally not tested by the -Kolla community, but included since sometimes a free IP is not available -in a testing environment. - -External Elasticsearch/Kibana environment -========================================= - -It is possible to use an external Elasticsearch/Kibana environment. To do this -first disable the deployment of the central logging. - -:: - - enable_central_logging: "no" - -Now you can use the parameter ``elasticsearch_address`` to configure the -address of the external Elasticsearch environment. - -Non-default port -========================== - -It is sometimes required to use a different than default port -for service(s) in Kolla. It is possible with setting _port -in ``globals.yml`` file. -For example: -:: - - database_port: 3307 - -As _port value is saved in different services' configuration so -it's advised to make above change before deploying. diff --git a/doc/bifrost.rst b/doc/bifrost.rst deleted file mode 100644 index 38c755ae3..000000000 --- a/doc/bifrost.rst +++ /dev/null @@ -1,475 +0,0 @@ -============= -Bifrost Guide -============= - -From the bifrost developer documentation: - - Bifrost (pronounced bye-frost) is a set of Ansible playbooks that automates - the task of deploying a base image onto a set of known hardware using - Ironic. It provides modular utility for one-off operating system - deployment with as few operational requirements as reasonably possible. - -Kolla uses bifrost as a mechanism for bootstrapping an OpenStack control plane -on a set of baremetal servers. Kolla provides a container image for bifrost. -Kolla-ansible provides a playbook to configure and deploy the bifrost -container, as well as building a base OS image and provisioning it onto the -baremetal nodes. - -Hosts in the System -=================== - -In a system deployed by bifrost we define a number of classes of hosts. - -Control host - The control host is the host on which kolla and kolla-ansible will be - installed, and is typically where the cloud will be managed from. -Deployment host - The deployment host runs the bifrost deploy container and is used to - provision the cloud hosts. -Cloud hosts - The cloud hosts run the OpenStack control plane, compute and storage - services. -Bare metal compute hosts: - In a cloud providing bare metal compute services to tenants via Ironic, - these hosts will run the bare metal tenant workloads. In a cloud with only - virtualised compute this category of hosts does not exist. - -.. note:: - - In many cases the control and deployment host will be the same, although - this is not mandatory. - -.. note:: - - Bifrost supports provisioning of bare metal nodes. While kolla-ansible is - agnostic to whether the host OS runs on bare metal or is virtualised, in a - virtual environment the provisioning of VMs for cloud hosts and their base - OS images is currently out of scope. - -Cloud Deployment Procedure -========================== - -Cloud deployment using kolla and bifrost follows the following high level -steps: - -#. Install and configure kolla and kolla-ansible on the control host. -#. Deploy bifrost on the deployment host. -#. Use bifrost to build a base OS image and provision cloud hosts with this - image. -#. Deploy OpenStack services on the cloud hosts provisioned by bifrost. - -Preparation -=========== - -Prepare the Control Host ------------------------- - -Follow the **Install dependencies** section of the :doc:`quickstart` guide -instructions to set up kolla and kolla-ansible dependencies. Follow the -instructions in either the **Install kolla for development** section or the -**Install kolla for deployment or evaluation** section to install kolla and -kolla-ansible. - -Prepare the Deployment Host ---------------------------- - -RabbitMQ requires that the system's hostname resolves to the IP address that it -has been configured to use, which with bifrost will be ``127.0.0.1``. Bifrost -will attempt to modify ``/etc/hosts`` on the deployment host to ensure that -this is the case. Docker bind mounts ``/etc/hosts`` into the container from a -volume. This prevents atomic renames which will prevent Ansible from fixing -the -``/etc/hosts`` file automatically. - -To enable bifrost to be bootstrapped correctly add an entry to ``/etc/hosts`` -resolving the deployment host's hostname to ``127.0.0.1``, for example:: - - ubuntu@bifrost:/repo/kolla$ cat /etc/hosts - 127.0.0.1 bifrost localhost - - # The following lines are desirable for IPv6 capable hosts - ::1 ip6-localhost ip6-loopback - fe00::0 ip6-localnet - ff00::0 ip6-mcastprefix - ff02::1 ip6-allnodes - ff02::2 ip6-allrouters - ff02::3 ip6-allhosts - 192.168.100.15 bifrost - -Build a Bifrost Container Image -=============================== - -This section provides instructions on how to build a container image for -bifrost using kolla. - -Enable Source Build Type ------------------------- - -Currently kolla only supports the source install type for the bifrost image. - -Configuration File -~~~~~~~~~~~~~~~~~~ - -If required, generate a default configuration file for ``kolla-build``:: - - cd kolla - tox -e genconfig - -Modify ``kolla-build.conf``, setting ``install_type`` to ``source``:: - - install_type = source - -Command line -~~~~~~~~~~~~ - -Alternatively, instead of using ``kolla-build.conf``, a source build can be -enabled by appending ``--type source`` to the ``kolla-build`` or -``tools/build.py`` command. - -Build Container ---------------- - -Development -~~~~~~~~~~~ - -:: - - cd kolla - tools/build.py bifrost-deploy - -Production -~~~~~~~~~~ - -:: - - kolla-build bifrost-deploy - -.. note:: - - By default kolla-build will build all containers using CentOS as the base - image. To change this behavior, use the following parameter with - ``kolla-build`` or ``tools/build.py`` command:: - - --base [ubuntu|centos|oraclelinux] - -Configure and Deploy a Bifrost Container -======================================== - -This section provides instructions for how to configure and deploy a container -running bifrost services. - -Prepare Kolla-Ansible Inventory -------------------------------- - -Kolla-ansible will deploy bifrost on the hosts in the ``bifrost`` Ansible -group. In the ``all-in-one`` and ``multinode`` inventory files, a ``bifrost`` -group is defined which contains all hosts in the ``deployment`` group. This -top level ``deployment`` group is intended to represent the host running the -``bifrost_deploy`` container. By default, this group contains ``localhost``. -See `Multinode Deployment of Kolla `_ -for details on how to modify the Ansible inventory in a multinode deployment. - -Bifrost does not currently support running on multiple hosts so the ``bifrost`` -group should contain only a single host, however this is not enforced by -kolla-ansible. Bifrost manages a number of services that conflict with -services deployed by kolla including OpenStack Ironic, MariaDB, RabbitMQ and -(optionally) OpenStack Keystone. These services should not be deployed on the -host on which bifrost is deployed. - -Prepare Kolla-Ansible Configuration ------------------------------------ - -Follow the instructions in :doc:`quickstart` to prepare kolla-ansible's global -configuration file ``globals.yml``. For bifrost, the -``bifrost_network_interface`` variable should be set to the name of the -interface that will be used to provision bare metal cloud hosts if this is -different than ``network_interface``. For example to use ``eth1``: - -.. code-block:: yaml - - bifrost_network_interface: eth1 - -Note that this interface should typically have L2 network connectivity with the -bare metal cloud hosts in order to provide DHCP leases with PXE boot options. - -Since bifrost only supports the source image type, ensure that this is -reflected in ``globals.yml`` - -.. code-block:: yaml - - kolla_install_type: source - -Prepare Bifrost Configuration ------------------------------ - -Kolla ansible custom configuration files can be placed in a directory given by -the ``node_custom_config`` variable, which defaults do ``/etc/kolla/config``. -Bifrost configuration files should be placed in this directory or in a -``bifrost`` subdirectory of it (e.g. ``/etc/kolla/config/bifrost``). Within -these directories the files ``bifrost.yml``, ``servers.yml`` and ``dib.yml`` -can be used to configure Bifrost. - -Create a Bifrost Inventory -~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The file ``servers.yml`` defines the bifrost hardware inventory that will be -used to populate Ironic. See the `bifrost dynamic inventory examples -`_ for -further details. - -For example, the following inventory defines a single node managed via the -Ironic ``agent_ipmitool`` driver. The inventory contains credentials required -to access the node's BMC via IPMI, the MAC addresses of the node's NICs, an IP -address to configure the node's configdrive with, a set of scheduling -properties and a logical name. - -.. code-block:: yaml - - --- - cloud1: - uuid: "31303735-3934-4247-3830-333132535336" - driver_info: - power: - ipmi_username: "admin" - ipmi_address: "192.168.1.30" - ipmi_password: "root" - nics: - - - mac: "1c:c1:de:1c:aa:53" - - - mac: "1c:c1:de:1c:aa:52" - driver: "agent_ipmitool" - ipv4_address: "192.168.1.10" - properties: - cpu_arch: "x86_64" - ram: "24576" - disk_size: "120" - cpus: "16" - name: "cloud1" - -The required inventory will be specific to the hardware and environment in use. - -Create Bifrost Configuration -~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The file ``bifrost.yml`` provides global configuration for the bifrost -playbooks. By default kolla mostly uses bifrost's default variable values. -For details on bifrost's variables see the bifrost documentation. - -For example: - -.. code-block:: yaml - - mysql_service_name: mysql - ansible_python_interpreter: /var/lib/kolla/venv/bin/python - enabled_drivers: agent_ipmitool,agent_ipminative - # uncomment below if needed - # dhcp_pool_start: 192.168.2.200 - # dhcp_pool_end: 192.168.2.250 - # dhcp_lease_time: 12h - # dhcp_static_mask: 255.255.255.0 - -Create Disk Image Builder Configuration -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The file ``dib.yml`` provides configuration for bifrost's image build -playbooks. By default kolla mostly uses bifrost's default variable values when -building the baremetal OS and deployment images, and will build an -**Ubuntu-based** image for deployment to nodes. For details on bifrost's -variables see the bifrost documentation. - -For example to use the ``debian`` Disk Image Builder OS element: - -.. code-block:: yaml - - dib_os_element: debian - -See the `diskimage-builder documentation -`__ for more details. - -Deploy Bifrost --------------- - -The bifrost container can be deployed either using kolla-ansible or manually. - -Kolla-Ansible -~~~~~~~~~~~~~ - -Development -___________ - -:: - - cd kolla-ansible - tools/kolla-ansible deploy-bifrost - -Production -__________ - -:: - - kolla-ansible deploy-bifrost - -Manual -~~~~~~ - -Start Bifrost Container -_______________________ - -:: - - docker run -it --net=host -v /dev:/dev -d \ - --privileged --name bifrost_deploy \ - kolla/ubuntu-source-bifrost-deploy:3.0.1 - -Copy Configuration Files -________________________ - -.. code-block:: console - - docker exec -it bifrost_deploy mkdir /etc/bifrost - docker cp /etc/kolla/config/bifrost/servers.yml bifrost_deploy:/etc/bifrost/servers.yml - docker cp /etc/kolla/config/bifrost/bifrost.yml bifrost_deploy:/etc/bifrost/bifrost.yml - docker cp /etc/kolla/config/bifrost/dib.yml bifrost_deploy:/etc/bifrost/dib.yml - -Bootstrap Bifrost -_________________ - -:: - - docker exec -it bifrost_deploy bash - -Generate an SSH Key -___________________ - -:: - - ssh-keygen - -Bootstrap and Start Services -____________________________ - -.. code-block:: console - - cd /bifrost - ./scripts/env-setup.sh - . env-vars - cat > /etc/rabbitmq/rabbitmq-env.conf << EOF - HOME=/var/lib/rabbitmq - EOF - ansible-playbook -vvvv \ - -i /bifrost/playbooks/inventory/target \ - /bifrost/playbooks/install.yaml \ - -e @/etc/bifrost/bifrost.yml \ - -e @/etc/bifrost/dib.yml \ - -e skip_package_install=true - -Validate the Deployed Container -=============================== - -.. code-block:: console - - docker exec -it bifrost_deploy bash - cd /bifrost - . env-vars - -Running "ironic node-list" should return with no nodes, for example - -.. code-block:: console - - (bifrost-deploy)[root@bifrost bifrost]# ironic node-list - +------+------+---------------+-------------+--------------------+-------------+ - | UUID | Name | Instance UUID | Power State | Provisioning State | Maintenance | - +------+------+---------------+-------------+--------------------+-------------+ - +------+------+---------------+-------------+--------------------+-------------+ - -Enroll and Deploy Physical Nodes -================================ - -Once we have deployed a bifrost container we can use it to provision the bare -metal cloud hosts specified in the inventory file. Again, this can be done -either using kolla-ansible or manually. - -Kolla-Ansible -------------- - -Development -~~~~~~~~~~~ - -:: - - tools/kolla-ansible deploy-servers - -Production -~~~~~~~~~~ - -:: - - kolla-ansible deploy-servers - -Manual ------- - -.. code-block:: console - - docker exec -it bifrost_deploy bash - cd /bifrost - . env-vars - export BIFROST_INVENTORY_SOURCE=/etc/bifrost/servers.yml - ansible-playbook -vvvv \ - -i /bifrost/playbooks/inventory/bifrost_inventory.py \ - /bifrost/playbooks/enroll-dynamic.yaml \ - -e "ansible_python_interpreter=/var/lib/kolla/venv/bin/python" \ - -e @/etc/bifrost/bifrost.yml - - docker exec -it bifrost_deploy bash - cd /bifrost - . env-vars - export BIFROST_INVENTORY_SOURCE=/etc/bifrost/servers.yml - ansible-playbook -vvvv \ - -i /bifrost/playbooks/inventory/bifrost_inventory.py \ - /bifrost/playbooks/deploy-dynamic.yaml \ - -e "ansible_python_interpreter=/var/lib/kolla/venv/bin/python" \ - -e @/etc/bifrost/bifrost.yml - -At this point Ironic should clean down the nodes and install the default -OS image. - -Advanced Configuration -====================== - -Bring Your Own Image --------------------- - -TODO - -Bring Your Own SSH Key ----------------------- - -To use your own SSH key after you have generated the ``passwords.yml`` file -update the private and public keys under ``bifrost_ssh_key``. - -Known issues -============ - -SSH daemon not running ----------------------- - -By default ``sshd`` is installed in the image but may not be enabled. If you -encounter this issue you will have to access the server physically in recovery -mode to enable the ``sshd`` service. If your hardware supports it, this can be -done remotely with ``ipmitool`` and Serial Over LAN. For example - -.. code-block:: console - - ipmitool -I lanplus -H 192.168.1.30 -U admin -P root sol activate - -References -========== - -Bifrost documentation: https://docs.openstack.org/bifrost/latest/ - -Bifrost troubleshooting guide: https://docs.openstack.org/bifrost/latest/troubleshooting.html - -Bifrost code repository: https://github.com/openstack/bifrost - diff --git a/doc/bug-triage.rst b/doc/bug-triage.rst deleted file mode 100644 index d5d24ca15..000000000 --- a/doc/bug-triage.rst +++ /dev/null @@ -1,8 +0,0 @@ -========== -Bug triage -========== - -The triage of Kolla bugs follows the OpenStack-wide process documented -on `BugTriage `_ in the wiki. -Please reference `Bugs `_ in the -wiki for further details. diff --git a/doc/central-logging-guide.rst b/doc/central-logging-guide.rst deleted file mode 100644 index 938b8b137..000000000 --- a/doc/central-logging-guide.rst +++ /dev/null @@ -1,156 +0,0 @@ -.. _central-logging-guide: - -======================== -Central Logging in Kolla -======================== - -An OpenStack deployment generates vast amounts of log data. In order to -successfully monitor this and use it to diagnose problems, the standard "ssh -and grep" solution quickly becomes unmanageable. - -Preparation and deployment -========================== - -Modify the configuration file ``/etc/kolla/globals.yml`` and change -the following: - -:: - - enable_central_logging: "yes" - -Elasticsearch -============= - -Kolla deploys Elasticsearch as part of the E*K stack to store, organize -and make logs easily accessible. - -By default Elasticsearch is deployed on port ``9200``. - -.. note:: - - Elasticsearch stores a lot of logs, so if you are running centralized logging, - remember to give ``/var/lib/docker`` an adequate space. - - -Kibana -====== - -Kolla deploys Kibana as part of the E*K stack in order to allow operators to -search and visualise logs in a centralised manner. - -After successful deployment, Kibana can be accessed using a browser on -``:5601``. - -The default username is ``kibana``, the password can be located under -```` in ``/etc/kolla/passwords.yml``. - -Search logs - Discover tab --------------------------- - -Operators can create and store searches based on various fields from logs, for -example, "show all logs marked with ERROR on nova-compute". - -To do this, click the ``Discover`` tab. Fields from the logs can be filtered by -hovering over entries from the left hand side, and clicking ``add`` or -``remove``. Add the following fields: - -* Hostname -* Payload -* severity_label -* programname - -This yields an easy to read list of all log events from each node in the -deployment within the last 15 minutes. A "tail like" functionality can be -achieved by clicking the clock icon in the top right hand corner of the screen, -and selecting ``Auto-refresh``. - -Logs can also be filtered down further. To use the above example, type -``programname:nova-compute`` in the search bar. Click the drop-down arrow from -one of the results, then the small magnifying glass icon from beside the -programname field. This should now show a list of all events from nova-compute -services across the cluster. - -The current search can also be saved by clicking the ``Save Search`` icon -available from the menu on the right hand side. - -Example: using Kibana to diagnose a common failure --------------------------------------------------- - -The following example demonstrates how Kibana can be used to diagnose a common -OpenStack problem, where an instance fails to launch with the error 'No valid -host was found'. - -First, re-run the server creation with ``--debug``: - -:: - - openstack --debug server create --image cirros --flavor m1.tiny \ - --key-name mykey --nic net-id=00af016f-dffe-4e3c-a9b8-ec52ccd8ea65 \ - demo1 - -In this output, look for the key ``X-Compute-Request-Id``. This is a unique -identifier that can be used to track the request through the system. An -example ID looks like this: - -:: - - X-Compute-Request-Id: req-c076b50a-6a22-48bf-8810-b9f41176a6d5 - -Taking the value of ``X-Compute-Request-Id``, enter the value into the Kibana -search bar, minus the leading ``req-``. Assuming some basic filters have been -added as shown in the previous section, Kibana should now show the path this -request made through the OpenStack deployment, starting at a ``nova-api`` on -a control node, through the ``nova-scheduler``, ``nova-conductor``, and finally -``nova-compute``. Inspecting the ``Payload`` of the entries marked ``ERROR`` -should quickly lead to the source of the problem. - -While some knowledge is still required of how Nova works in this instance, it -can still be seen how Kibana helps in tracing this data, particularly in a -large scale deployment scenario. - -Visualize data - Visualize tab ------------------------------- - -In the visualization tab a wide range of charts is available. If any -visualization has not been saved yet, after choosing this tab *Create a new -visualization* panel is opened. If a visualization has already been saved, -after choosing this tab, lately modified visualization is opened. In this -case, one can create a new visualization by choosing *add visualization* -option in the menu on the right. In order to create new visualization, one -of the available options has to be chosen (pie chart, area chart). Each -visualization can be created from a saved or a new search. After choosing -any kind of search, a design panel is opened. In this panel, a chart can be -generated and previewed. In the menu on the left, metrics for a chart can -be chosen. The chart can be generated by pressing a green arrow on the top -of the left-side menu. - -.. note:: After creating a visualization, it can be saved by choosing *save - visualization* option in the menu on the right. If it is not saved, it - will be lost after leaving a page or creating another visualization. - -Organize visualizations and searches - Dashboard tab ----------------------------------------------------- - -In the Dashboard tab all of saved visualizations and searches can be -organized in one Dashboard. To add visualization or search, one can choose -*add visualization* option in the menu on the right and then choose an item -from all saved ones. The order and size of elements can be changed directly -in this place by moving them or resizing. The color of charts can also be -changed by checking a colorful dots on the legend near each visualization. - -.. note:: After creating a dashboard, it can be saved by choosing *save dashboard* - option in the menu on the right. If it is not saved, it will be lost after - leaving a page or creating another dashboard. - -If a Dashboard has already been saved, it can be opened by choosing *open -dashboard* option in the menu on the right. - -Exporting and importing created items - Settings tab ----------------------------------------------------- - -Once visualizations, searches or dashboards are created, they can be exported -to a JSON format by choosing Settings tab and then Objects tab. Each of the -item can be exported separately by selecting it in the menu. All of the items -can also be exported at once by choosing *export everything* option. -In the same tab (Settings - Objects) one can also import saved items by -choosing *import* option. diff --git a/doc/ceph-guide.rst b/doc/ceph-guide.rst deleted file mode 100644 index 61e2f7b1c..000000000 --- a/doc/ceph-guide.rst +++ /dev/null @@ -1,360 +0,0 @@ -.. _ceph-guide: - -============= -Ceph in Kolla -============= - -The out-of-the-box Ceph deployment requires 3 hosts with at least one block -device on each host that can be dedicated for sole use by Ceph. However, with -tweaks to the Ceph cluster you can deploy a **healthy** cluster with a single -host and a single block device. - -Requirements -============ - -* A minimum of 3 hosts for a vanilla deploy -* A minimum of 1 block device per host - -Preparation -=========== - -To prepare a disk for use as a -`Ceph OSD `_ you must add a -special partition label to the disk. This partition label is how Kolla detects -the disks to format and bootstrap. Any disk with a matching partition label -will be reformatted so use caution. - -To prepare an OSD as a storage drive, execute the following operations: - -:: - - # - # where $DISK is /dev/sdb or something similar - parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 - -The following shows an example of using parted to configure ``/dev/sdb`` for -usage with Kolla. - -:: - - parted /dev/sdb -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 - parted /dev/sdb print - Model: VMware, VMware Virtual S (scsi) - Disk /dev/sdb: 10.7GB - Sector size (logical/physical): 512B/512B - Partition Table: gpt - Number Start End Size File system Name Flags - 1 1049kB 10.7GB 10.7GB KOLLA_CEPH_OSD_BOOTSTRAP - - -Using an external journal drive -------------------------------- - -The steps documented above created a journal partition of 5 GByte -and a data partition with the remaining storage capacity on the same tagged -drive. - -It is a common practice to place the journal of an OSD on a separate -journal drive. This section documents how to use an external journal drive. - -Prepare the storage drive in the same way as documented above: - -:: - - # - # where $DISK is /dev/sdb or something similar - parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_FOO 1 -1 - -To prepare the journal external drive execute the following command: - -:: - - # - # where $DISK is /dev/sdc or something similar - parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_FOO_J 1 -1 - -.. note:: - - Use different suffixes (``_42``, ``_FOO``, ``_FOO42``, ..) to use different external - journal drives for different storage drives. One external journal drive can only - be used for one storage drive. - -.. note:: - - The partition labels ``KOLLA_CEPH_OSD_BOOTSTRAP`` and ``KOLLA_CEPH_OSD_BOOTSTRAP_J`` - are not working when using external journal drives. It is required to use - suffixes (``_42``, ``_FOO``, ``_FOO42``, ..). If you want to setup only one - storage drive with one external journal drive it is also necessary to use a suffix. - - -Configuration -============= - -Edit the [storage] group in the inventory which contains the hostname of the -hosts that have the block devices you have prepped as shown above. - -:: - - [storage] - controller - compute1 - - -Enable Ceph in ``/etc/kolla/globals.yml``: - -:: - - enable_ceph: "yes" - - -RadosGW is optional, enable it in ``/etc/kolla/globals.yml``: - -:: - - enable_ceph_rgw: "yes" - -RGW requires a healthy cluster in order to be successfully deployed. On initial -start up, RGW will create several pools. The first pool should be in an -operational state to proceed with the second one, and so on. So, in the case of -an **all-in-one** deployment, it is necessary to change the default number of -copies for the pools before deployment. Modify the file -``/etc/kolla/config/ceph.conf`` and add the contents:: - - [global] - osd pool default size = 1 - osd pool default min size = 1 - - -Deployment -========== - -Finally deploy the Ceph-enabled OpenStack: - -:: - - kolla-ansible deploy -i path/to/inventory - -Using a Cache Tier -================== - -An optional `cache tier `_ -can be deployed by formatting at least one cache device and enabling cache. -tiering in the globals.yml configuration file. - -To prepare an OSD as a cache device, execute the following operations: - -:: - - # - # where $DISK is /dev/sdb or something similar - parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_CACHE_BOOTSTRAP 1 -1 - -Enable the Ceph cache tier in ``/etc/kolla/globals.yml``: - -:: - - enable_ceph: "yes" - ceph_enable_cache: "yes" - # Valid options are [ forward, none, writeback ] - ceph_cache_mode: "writeback" - -After this run the playbooks as you normally would. For example: - -:: - - kolla-ansible deploy -i path/to/inventory - -Setting up an Erasure Coded Pool -================================ - -`Erasure code `_ -is the new big thing from Ceph. Kolla has the ability to setup your Ceph pools -as erasure coded pools. Due to technical limitations with Ceph, using erasure -coded pools as OpenStack uses them requires a cache tier. Additionally, you -must make the choice to use an erasure coded pool or a replicated pool -(the default) when you initially deploy. You cannot change this without -completely removing the pool and recreating it. - -To enable erasure coded pools add the following options to your -``/etc/kolla/globals.yml`` configuration file: - -:: - - # A requirement for using the erasure-coded pools is you must setup a cache tier - # Valid options are [ erasure, replicated ] - ceph_pool_type: "erasure" - # Optionally, you can change the profile - #ceph_erasure_profile: "k=4 m=2 ruleset-failure-domain=host" - -Managing Ceph -============= - -Check the Ceph status for more diagnostic information. The sample output below -indicates a healthy cluster: - -:: - - docker exec ceph_mon ceph -s - cluster 5fba2fbc-551d-11e5-a8ce-01ef4c5cf93c - health HEALTH_OK - monmap e1: 1 mons at {controller=10.0.0.128:6789/0} - election epoch 2, quorum 0 controller - osdmap e18: 2 osds: 2 up, 2 in - pgmap v27: 64 pgs, 1 pools, 0 bytes data, 0 objects - 68676 kB used, 20390 MB / 20457 MB avail - 64 active+clean - -If Ceph is run in an **all-in-one** deployment or with less than three storage -nodes, further configuration is required. It is necessary to change the default -number of copies for the pool. The following example demonstrates how to change -the number of copies for the pool to 1: - -:: - - docker exec ceph_mon ceph osd pool set rbd size 1 - -All the pools must be modified if Glance, Nova, and Cinder have been deployed. -An example of modifying the pools to have 2 copies: - -:: - - for p in images vms volumes backups; do docker exec ceph_mon ceph osd pool set ${p} size 2; done - -If using a cache tier, these changes must be made as well: - -:: - - for p in images vms volumes backups; do docker exec ceph_mon ceph osd pool set ${p}-cache size 2; done - -The default pool Ceph creates is named **rbd**. It is safe to remove this pool: - -:: - - docker exec ceph_mon ceph osd pool delete rbd rbd --yes-i-really-really-mean-it - -Troubleshooting -=============== - -Deploy fails with 'Fetching Ceph keyrings ... No JSON object could be decoded' ------------------------------------------------------------------------------- - -If an initial deploy of Ceph fails, perhaps due to improper configuration or -similar, the cluster will be partially formed and will need to be reset for a -successful deploy. - -In order to do this the operator should remove the `ceph_mon_config` volume -from each Ceph monitor node: - -:: - - ansible \ - -i ansible/inventory/multinode \ - -a 'docker volume rm ceph_mon_config' \ - ceph-mon - -===================== -Simple 3 Node Example -===================== - -This example will show how to deploy Ceph in a very simple setup using 3 -storage nodes. 2 of those nodes (kolla1 and kolla2) will also provide other -services like control, network, compute, and monitoring. The 3rd -(kolla3) node will only act as a storage node. - -This example will only focus on the Ceph aspect of the deployment and assumes -that you can already deploy a fully functional environment using 2 nodes that -does not employ Ceph yet. So we will be adding to the existing multinode -inventory file you already have. - -Each of the 3 nodes are assumed to have two disk, ``/dev/sda`` (40GB) -and ``/dev/sdb`` (10GB). Size is not all that important... but for now make -sure each sdb disk are of the same size and are at least 10GB. This example -will use a single disk (/dev/sdb) for both Ceph data and journal. It will not -implement caching. - -Here is the top part of the multinode inventory file used in the example -environment before adding the 3rd node for Ceph: - -:: - - [control] - # These hostname must be resolvable from your deployment host - kolla1.ducourrier.com - kolla2.ducourrier.com - - [network] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [compute] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [monitoring] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [storage] - kolla1.ducourrier.com - kolla2.ducourrier.com - - - -Configuration -============= - -To prepare the 2nd disk (/dev/sdb) of each nodes for use by Ceph you will need -to add a partition label to it as shown below: - -:: - - # - parted /dev/sdb -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 - -Make sure to run this command on each of the 3 nodes or the deployment will -fail. - -Next, edit the multinode inventory file and make sure the 3 nodes are listed -under [storage]. In this example I will add kolla3.ducourrier.com to the -existing inventory file: - -:: - - [control] - # These hostname must be resolvable from your deployment host - kolla1.ducourrier.com - kolla2.ducourrier.com - - [network] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [compute] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [monitoring] - kolla1.ducourrier.com - kolla2.ducourrier.com - - [storage] - kolla1.ducourrier.com - kolla2.ducourrier.com - kolla3.ducourrier.com - -It is now time to enable Ceph in the environment by editing the -``/etc/kolla/globals.yml`` file: - -:: - - enable_ceph: "yes" - enable_ceph_rgw: "yes" - enable_cinder: "yes" - glance_backend_file: "no" - glance_backend_ceph: "yes" - -Finally deploy the Ceph-enabled configuration: - -:: - - kolla-ansible deploy -i path/to/inventory-file diff --git a/doc/cinder-guide-hnas.rst b/doc/cinder-guide-hnas.rst deleted file mode 100644 index c064e3c05..000000000 --- a/doc/cinder-guide-hnas.rst +++ /dev/null @@ -1,231 +0,0 @@ -.. _cinder-guide-hnas: - -======================================================== -Hitachi NAS Platform iSCSI and NFS drives for OpenStack -======================================================== - -Overview -======== -The Block Storage service provides persistent block storage resources that -Compute instances can consume. This includes secondary attached storage similar -to the Amazon Elastic Block Storage (EBS) offering. In addition, you can write -images to a Block Storage device for Compute to use as a bootable persistent -instance. - -Requirements ------------- -- Hitachi NAS Platform Models 3080, 3090, 4040, 4060, 4080, and 4100. - -- HNAS/SMU software version is 12.2 or higher. - -- HNAS configuration and management utilities to create a storage pool (span) - and an EVS. - - - GUI (SMU). - - - SSC CLI. - -- You must set an iSCSI domain to EVS - -Supported shared file systems and operations --------------------------------------------- - -The NFS and iSCSI drivers support these operations: - -- Create, delete, attach, and detach volumes. - -- Create, list, and delete volume snapshots. - -- Create a volume from a snapshot. - -- Copy an image to a volume. - -- Copy a volume to an image. - -- Clone a volume. - -- Extend a volume. - -- Get volume statistics. - -- Manage and unmanage a volume. - -- Manage and unmanage snapshots (HNAS NFS only). - -Configuration example for Hitachi NAS Platform iSCSI and NFS -============================================================ - -iSCSI backend -------------- - -Enable cinder hnas backend iscsi in ``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_cinder_backend_hnas_iscsi: "yes" - -Create or modify the file ``/etc/kolla/config/cinder.conf`` and add the -contents: - -.. code-block:: console - - [DEFAULT] - enabled_backends = hnas-iscsi - - [hnas-iscsi] - volume_driver = cinder.volume.drivers.hitachi.hnas_iscsi.HNASISCSIDriver - volume_iscsi_backend = hnas_iscsi_backend - hnas_iscsi_username = supervisor - hnas_iscsi_password = supervisor - hnas_iscsi_mgmt_ip0 = - hnas_chap_enabled = True - - hnas_iscsi_svc0_volume_type = iscsi_gold - hnas_iscsi_svc0_hdp = FS-Baremetal1 - hnas_iscsi_svc0_iscsi_ip = - -NFS backend ------------ - -Enable cinder hnas backend nfs in ``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_cinder_backend_hnas_nfs: "yes" - -Create or modify the file ``/etc/kolla/config/cinder.conf`` and -add the contents: - -.. code-block:: console - - [DEFAULT] - enabled_backends = hnas-nfs - - [hnas-nfs] - volume_driver = cinder.volume.drivers.hitachi.hnas_nfs.HNASNFSDriver - volume_nfs_backend = hnas_nfs_backend - hnas_nfs_username = supervisor - hnas_nfs_password = supervisor - hnas_nfs_mgmt_ip0 = - hnas_chap_enabled = True - - hnas_nfs_svc0_volume_type = nfs_gold - hnas_nfs_svc0_hdp = / - -Configuration on Kolla deployment ---------------------------------- - -Enable Shared File Systems service and HNAS driver in -``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_cinder: "yes" - -Configuration on HNAS ---------------------- - -Create the data HNAS network in Kolla OpenStack: - -List the available tenants: - -.. code-block:: console - - $ openstack project list - -Create a network to the given tenant (service), providing the tenant ID, -a name for the network, the name of the physical network over which the -virtual network is implemented, and the type of the physical mechanism by -which the virtual network is implemented: - -.. code-block:: console - - $ neutron net-create --tenant-id hnas_network \ - --provider:physical_network=physnet2 --provider:network_type=flat - -Create a subnet to the same tenant (service), the gateway IP of this subnet, -a name for the subnet, the network ID created before, and the CIDR of -subnet: - -.. code-block:: console - - $ neutron subnet-create --tenant-id --gateway \ - --name hnas_subnet - -Add the subnet interface to a router, providing the router ID and subnet -ID created before: - -.. code-block:: console - - $ neutron router-interface-add - -Create volume -============= - -Create a non-bootable volume. - -.. code-block:: console - - $ openstack volume create --size 1 my-volume - -Verify Operation. - -.. code-block:: console - - $ cinder show my-volume - - +--------------------------------+--------------------------------------+ - | Property | Value | - +--------------------------------+--------------------------------------+ - | attachments | [] | - | availability_zone | nova | - | bootable | false | - | consistencygroup_id | None | - | created_at | 2017-01-17T19:02:45.000000 | - | description | None | - | encrypted | False | - | id | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | - | metadata | {} | - | migration_status | None | - | multiattach | False | - | name | my-volume | - | os-vol-host-attr:host | compute@hnas-iscsi#iscsi_gold | - | os-vol-mig-status-attr:migstat | None | - | os-vol-mig-status-attr:name_id | None | - | os-vol-tenant-attr:tenant_id | 16def9176bc64bd283d419ac2651e299 | - | replication_status | disabled | - | size | 1 | - | snapshot_id | None | - | source_volid | None | - | status | available | - | updated_at | 2017-01-17T19:02:46.000000 | - | user_id | fb318b96929c41c6949360c4ccdbf8c0 | - | volume_type | None | - +--------------------------------+--------------------------------------+ - - $ nova volume-attach INSTANCE_ID VOLUME_ID auto - - +----------+--------------------------------------+ - | Property | Value | - +----------+--------------------------------------+ - | device | /dev/vdc | - | id | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | - | serverId | 3bf5e176-be05-4634-8cbd-e5fe491f5f9c | - | volumeId | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | - +----------+--------------------------------------+ - - $ openstack volume list - - +--------------------------------------+---------------+----------------+------+-------------------------------------------+ - | ID | Display Name | Status | Size | Attached to | - +--------------------------------------+---------------+----------------+------+-------------------------------------------+ - | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | my-volume | in-use | 1 | Attached to private-instance on /dev/vdb | - +--------------------------------------+---------------+----------------+------+-------------------------------------------+ - -For more information about how to manage volumes, see the -`OpenStack User Guide -`__. - -For more information about how HNAS driver works, see -`Hitachi NAS Platform iSCSI and NFS drives for OpenStack -`__. diff --git a/doc/cinder-guide.rst b/doc/cinder-guide.rst deleted file mode 100644 index 937e99ac8..000000000 --- a/doc/cinder-guide.rst +++ /dev/null @@ -1,166 +0,0 @@ -.. _cinder-guide: - -=============== -Cinder in Kolla -=============== - -Overview -======== - -Cinder can be deploying using Kolla and supports the following storage -backends: - -* ceph -* hnas_iscsi -* hnas_nfs -* iscsi -* lvm -* nfs - -LVM -=== - -When using the ``lvm`` backend, a volume group will need to be created on each -storage node. This can either be a real physical volume or a loopback mounted -file for development. Use ``pvcreate`` and ``vgcreate`` to create the volume -group. For example with the devices ``/dev/sdb`` and ``/dev/sdc``: - -:: - - - - pvcreate /dev/sdb /dev/sdc - vgcreate cinder-volumes /dev/sdb /dev/sdc - -During development, it may be desirable to use file backed block storage. It -is possible to use a file and mount it as a block device via the loopback -system. :: - - - free_device=$(losetup -f) - fallocate -l 20G /var/lib/cinder_data.img - losetup $free_device /var/lib/cinder_data.img - pvcreate $free_device - vgcreate cinder-volumes $free_device - -Enable the ``lvm`` backend in ``/etc/kolla/globals.yml``: - -:: - - enable_cinder_backend_lvm: "yes" - -.. note :: - There are currently issues using the LVM backend in a multi-controller setup, - see `_bug 1571211 `__ for more info. - -NFS -=== - -To use the ``nfs`` backend, configure ``/etc/exports`` to contain the mount -where the volumes are to be stored:: - - /kolla_nfs 192.168.5.0/24(rw,sync,no_root_squash) - -In this example, ``/kolla_nfs`` is the directory on the storage node which will -be ``nfs`` mounted, ``192.168.5.0/24`` is the storage network, and -``rw,sync,no_root_squash`` means make the share read-write, synchronous, and -prevent remote root users from having access to all files. - -Then start ``nfsd``:: - - systemctl start nfs - -On the deploy node, create ``/etc/kolla/config/nfs_shares`` with an entry for -each storage node:: - - storage01:/kolla_nfs - storage02:/kolla_nfs - -Finally, enable the ``nfs`` backend in ``/etc/kolla/globals.yml``:: - - enable_cinder_backend_nfs: "yes" - -Validation -========== - -Create a volume as follows: - -:: - - $ openstack volume create --size 1 steak_volume - - -Verify it is available. If it says "error" here something went wrong during -LVM creation of the volume. :: - - $ openstack volume list - +--------------------------------------+--------------+-----------+------+-------------+ - | ID | Display Name | Status | Size | Attached to | - +--------------------------------------+--------------+-----------+------+-------------+ - | 0069c17e-8a60-445a-b7f0-383a8b89f87e | steak_volume | available | 1 | | - +--------------------------------------+--------------+-----------+------+-------------+ - -Attach the volume to a server using: - -:: - - openstack server add volume steak_server 0069c17e-8a60-445a-b7f0-383a8b89f87e - -Check the console log added the disk: - -:: - - openstack console log show steak_server - -A ``/dev/vdb`` should appear in the console log, at least when booting cirros. -If the disk stays in the available state, something went wrong during the -iSCSI mounting of the volume to the guest VM. - -Cinder LVM2 back end with iSCSI -=============================== - -As of Newton-1 milestone, Kolla supports LVM2 as cinder back end. It is -accomplished by introducing two new containers ``tgtd`` and ``iscsid``. -``tgtd`` container serves as a bridge between cinder-volume process and a -server hosting Logical Volume Groups (LVG). ``iscsid`` container serves as -a bridge between nova-compute process and the server hosting LVG. - -In order to use Cinder's LVM back end, a LVG named ``cinder-volumes`` should -exist on the server and following parameter must be specified in -``globals.yml`` :: - - enable_cinder_backend_lvm: "yes" - -For Ubuntu and LVM2/iSCSI -~~~~~~~~~~~~~~~~~~~~~~~~~ - -``iscsd`` process uses configfs which is normally mounted at -``/sys/kernel/config`` to store discovered targets information, on centos/rhel -type of systems this special file system gets mounted automatically, which is -not the case on debian/ubuntu. Since ``iscsid`` container runs on every nova -compute node, the following steps must be completed on every Ubuntu server -targeted for nova compute role. - - - Add configfs module to ``/etc/modules`` - - Rebuild initramfs using: ``update-initramfs -u`` command - - Stop ``open-iscsi`` system service due to its conflicts - with iscsid container. - - Ubuntu 16.04 (systemd): - ``systemctl stop open-iscsi; systemctl stop iscsid`` - - - Make sure configfs gets mounted during a server boot up process. There are - multiple ways to accomplish it, one example: - :: - - mount -t configfs /etc/rc.local /sys/kernel/config - -Cinder back end with external iSCSI storage -=========================================== - -In order to use external storage system (like one from EMC or NetApp) -the following parameter must be specified in ``globals.yml`` :: - - enable_cinder_backend_iscsi: "yes" - -Also ``enable_cinder_backend_lvm`` should be set to "no" in this case. diff --git a/doc/conf.py b/doc/conf.py deleted file mode 100644 index 7219f5feb..000000000 --- a/doc/conf.py +++ /dev/null @@ -1,90 +0,0 @@ -# -*- coding: utf-8 -*- -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or -# implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import os -import sys - -sys.path.insert(0, os.path.abspath('../..')) -# -- General configuration ---------------------------------------------------- - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = [ - 'openstackdocstheme', - 'sphinx.ext.autodoc', -] - -# autodoc generation is a bit aggressive and a nuisance when doing heavy -# text edit cycles. -# execute "export SPHINX_DEBUG=1" in your terminal to disable - -# The suffix of source filenames. -source_suffix = '.rst' - -# The master toctree document. -master_doc = 'index' - -# General information about the project. -project = u'kolla-ansible' -copyright = u'2013, OpenStack Foundation' - -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. -# -# The short X.Y version. -from kolla_ansible.version import version_info as kolla_version -# The full version, including alpha/beta/rc tags. -release = kolla_version.version_string_with_vcs() -# The short X.Y version. -version = kolla_version.canonical_version_string() - -# If true, '()' will be appended to :func: etc. cross-reference text. -add_function_parentheses = True - -# If true, the current module name will be prepended to all description -# unit titles (such as .. function::). -add_module_names = True - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' - -# -- Options for HTML output -------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. Major themes that come with -# Sphinx are currently 'default' and 'sphinxdoc'. -# html_theme_path = [] -html_theme = 'openstackdocs' -# html_static_path = ['static'] - -# Output file base name for HTML help builder. -htmlhelp_basename = '%sdoc' % project - -# Must set this variable to include year, month, day, hours, and minutes. -html_last_updated_fmt = '%Y-%m-%d %H:%M' - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto/manual]). -latex_documents = [ - ('index', - '%s.tex' % project, - u'%s Documentation' % project, - u'OpenStack Foundation', 'manual'), -] - -# openstackdocstheme options -repository_name = 'openstack/kolla-ansible' -bug_project = 'kolla-ansible' -bug_tag = '' diff --git a/doc/deployment-philosophy.rst b/doc/deployment-philosophy.rst deleted file mode 100644 index 959148e4c..000000000 --- a/doc/deployment-philosophy.rst +++ /dev/null @@ -1,76 +0,0 @@ -.. _deployment-philosophy: - -============================= -Kolla's Deployment Philosophy -============================= - -Overview -======== - -Kolla has an objective to replace the inflexible, painful, resource-intensive -deployment process of OpenStack with a flexible, painless, inexpensive -deployment process. Often to deploy OpenStack at the 100+ nodes scale, small -businesses may require building a team of OpenStack professionals to -maintain and manage the OpenStack deployment. Finding people experienced in -OpenStack deployment is very difficult and expensive, resulting in a big -barrier for OpenStack adoption. Kolla seeks to remedy this set of problems by -simplifying the deployment process while enabling flexible deployment models. - -Kolla is a highly opinionated deployment tool out of the box. This permits -Kolla to be deployable with the simple configuration of three key/value pairs. -As an operator's experience with OpenStack grows and the desire to customize -OpenStack services increases, Kolla offers full capability to override every -OpenStack service configuration option in the deployment. - -Why not Template Customization? -=============================== - -The Kolla upstream community does not want to place key/value pairs in the -Ansible playbook configuration options that are not essential to obtaining -a functional deployment. If the Kolla upstream starts down the path of -templating configuration options, the Ansible configuration could conceivably -grow to hundreds of configuration key/value pairs which is unmanageable. -Further, as new versions of Kolla are released, there would be independent -customization available for different versions creating an unsupportable and -difficult to document environment. Finally, adding key/value pairs for -configuration options creates a situation in which development and release -cycles are required in order to successfully add new customizations. -Essentially templating in configuration options is not a scalable solution -and would result in an inability of the project to execute its mission. - -Kolla's Solution to Customization -================================= - -Rather than deal with the customization madness of templating configuration -options in Kolla's Ansible playbooks, Kolla eliminates all the inefficiencies -of existing deployment tools through a simple, tidy design: custom -configuration sections. - -During deployment of an OpenStack service, a basic set of default configuration -options are merged with and overridden by custom ini configuration sections. -Kolla deployment customization is that simple! This does create a situation -in which the Operator must reference the upstream documentation if a -customization is desired in the OpenStack deployment. Fortunately the -configuration options documentation is extremely mature and well-formulated. - -As an example, consider running Kolla in a virtual machine. In order to -launch virtual machines from Nova in a virtual environment, it is necessary -to use the QEMU hypervisor, rather than the KVM hypervisor. To achieve this -result, simply `mkdir -p /etc/kolla/config` and modify the file -`/etc/kolla/config/nova.conf` with the contents:: - - [libvirt] - virt_type=qemu - -After this change Kolla will use an emulated hypervisor with lower performance. -Kolla could have templated this commonly modified configuration option. If -Kolla starts down this path, the Kolla project could end with hundreds of -config options all of which would have to be subjectively evaluated for -inclusion or exclusion in the source tree. - -Kolla's approach yields a solution which enables complete customization without -any upstream maintenance burden. Operators don't have to rely on a subjective -approval process for configuration options nor rely on a -development/test/release cycle to obtain a desired customization. Instead -operators have ultimate freedom to make desired deployment choices immediately -without the approval of a third party. diff --git a/doc/designate-guide.rst b/doc/designate-guide.rst deleted file mode 100644 index 3c4b39047..000000000 --- a/doc/designate-guide.rst +++ /dev/null @@ -1,122 +0,0 @@ -.. _designate-guide: - -================== -Designate in Kolla -================== - -Overview -======== -Designate provides DNSaaS services for OpenStack: - - - REST API for domain/record management - - Multi-tenant - - Integrated with Keystone for authentication - - Framework in place to integrate with Nova and Neutron - notifications (for auto-generated records) - - Support for PowerDNS and Bind9 out of the box - -Configuration on Kolla deployment ---------------------------------- - -Enable Designate service in ``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_designate: "yes" - -Configure Designate options in ``/etc/kolla/globals.yml`` - -.. important:: - - Designate MDNS node requires the ``dns_interface`` to be reachable from - public network. - -.. code-block:: console - - dns_interface: "eth1" - designate_backend: "bind9" - designate_ns_record: "sample.openstack.org" - -Neutron and Nova Integration ----------------------------- - -Create default Designate Zone for Neutron: - -.. code-block:: console - - $ openstack zone create --email admin@sample.openstack.org sample.openstack.org. - -Create designate-sink custom configuration folder: - -.. code-block:: console - - $ mkdir -p /etc/kolla/config/designate/ - -Append Designate Zone ID in ``/etc/kolla/config/designate/designate-sink.conf`` - -.. code-block:: console - - [handler:nova_fixed] - zone_id = - [handler:neutron_floatingip] - zone_id = - -Reconfigure Designate: - -.. code-block:: console - - $ kolla-ansible reconfigure -i --tags designate - -Verify operation ----------------- - -List available networks: - -.. code-block:: console - - $ openstack network list - -Associate a domain to a network: - -.. code-block:: console - - $ neutron net-update --dns_domain sample.openstack.org. - -Start an instance: - -.. code-block:: console - - $ openstack server create \ - --image cirros \ - --flavor m1.tiny \ - --key-name mykey \ - --nic net-id=${NETWORK_ID} \ - my-vm - -Check DNS records in Designate: - -.. code-block:: console - - $ openstack recordset list sample.openstack.org. - +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ - | id | name | type | records | status | action | - +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ - | 5aec6f5b-2121-4a2e-90d7-9e4509f79506 | sample.openstack.org. | SOA | sample.openstack.org. | ACTIVE | NONE | - | | | | admin.sample.openstack.org. 1485266928 3514 | | | - | | | | 600 86400 3600 | | | - | 578dc94a-df74-4086-a352-a3b2db9233ae | sample.openstack.org. | NS | sample.openstack.org. | ACTIVE | NONE | - | de9ff01e-e9ef-4a0f-88ed-6ec5ecabd315 | 192-168-190-232.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | - | f67645ee-829c-4154-a988-75341050a8d6 | my-vm.None.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | - | e5623d73-4f9f-4b54-9045-b148e0c3342d | my-vm.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | - +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ - -Query instance DNS information to Designate ``dns_interface`` IP address: - -.. code-block:: console - - $ dig +short -p 5354 @ my-vm.sample.openstack.org. A - 192.168.190.232 - -For more information about how Designate works, see -`Designate, a DNSaaS component for OpenStack -`__. diff --git a/doc/external-ceph-guide.rst b/doc/external-ceph-guide.rst deleted file mode 100644 index ef5875e71..000000000 --- a/doc/external-ceph-guide.rst +++ /dev/null @@ -1,202 +0,0 @@ -.. _external-ceph-guide: - -============= -External Ceph -============= - -Sometimes it is necessary to connect OpenStack services to an existing Ceph -cluster instead of deploying it with Kolla. This can be achieved with only a -few configuration steps in Kolla. - -Requirements -============ - -* An existing installation of Ceph -* Existing Ceph storage pools -* Existing credentials in Ceph for OpenStack services to connect to Ceph - (Glance, Cinder, Nova) - -Enabling External Ceph -====================== - -Using external Ceph with Kolla means not to deploy Ceph via Kolla. Therefore, -disable Ceph deployment in ``/etc/kolla/global.yml`` - -:: - - enable_ceph: "no" - -There are flags indicating individual services to use ceph or not which default -to the value of ``enable_ceph``. Those flags now need to be activated in order -to activate external Ceph integration. This can be done individually per -service in ``/etc/kolla/global.yml``: - -:: - - glance_backend_ceph: "yes" - cinder_backend_ceph: "yes" - nova_backend_ceph: "yes" - -The combination of ``enable_ceph: "no"`` and ``_backend_ceph: "yes"`` -triggers the activation of external ceph mechanism in Kolla. - -Configuring External Ceph -========================= - -Glance ------- - -Configuring Glance for Ceph includes three steps: - -1) Configure RBD back end in glance-api.conf -2) Create Ceph configuration file in /etc/ceph/ceph.conf -3) Create Ceph keyring file in /etc/ceph/ceph.client..keyring - -Step 1 is done by using Kolla's INI merge mechanism: Create a file in -``/etc/kolla/config/glance/glance-api.conf`` with the following contents: - -:: - - [DEFAULT] - show_image_direct_url = True - - [glance_store] - stores = rbd - default_store = rbd - rbd_store_pool = images - rbd_store_user = glance - rbd_store_ceph_conf = /etc/ceph/ceph.conf - -Now put ceph.conf and the keyring file (name depends on the username created in -Ceph) into the same directory, for example: - -/etc/kolla/config/glance/ceph.conf - -:: - - [global] - fsid = 1d89fec3-325a-4963-a950-c4afedd37fe3 - mon_initial_members = ceph-0 - mon_host = 192.168.0.56 - auth_cluster_required = cephx - auth_service_required = cephx - auth_client_required = cephx - -/etc/kolla/config/glance/ceph.client.glance.keyring - -:: - - [client.glance] - key = AQAg5YRXS0qxLRAAXe6a4R1a15AoRx7ft80DhA== - -Kolla will pick up all files named ceph.* in this directory an copy them to the -/etc/ceph/ directory of the container. - -Cinder ------- - -Configuring external Ceph for Cinder works very similar to -Glance. - -Edit /etc/kolla/config/cinder/cinder-volume.conf with the following content: - -:: - - [DEFAULT] - enabled_backends=rbd-1 - - [rbd-1] - rbd_ceph_conf=/etc/ceph/ceph.conf - rbd_user=cinder - backend_host=rbd:volumes - rbd_pool=volumes - volume_backend_name=rbd-1 - volume_driver=cinder.volume.drivers.rbd.RBDDriver - rbd_secret_uuid = {{ cinder_rbd_secret_uuid }} - -.. note:: - - ``cinder_rbd_secret_uuid`` can be found in ``/etc/kolla/passwords.yml`` file. - -Edit /etc/kolla/config/cinder/cinder-backup.conf with the following content: - -:: - - [DEFAULT] - backup_ceph_conf=/etc/ceph/ceph.conf - backup_ceph_user=cinder - backup_ceph_chunk_size = 134217728 - backup_ceph_pool=backups - backup_driver = cinder.backup.drivers.ceph - backup_ceph_stripe_unit = 0 - backup_ceph_stripe_count = 0 - restore_discard_excess_bytes = true - -Next, place the ceph.conf file into -/etc/kolla/config/cinder/ceph.conf: - -:: - - [global] - fsid = 1d89fec3-325a-4963-a950-c4afedd37fe3 - mon_initial_members = ceph-0 - mon_host = 192.168.0.56 - auth_cluster_required = cephx - auth_service_required = cephx - auth_client_required = cephx - -Separate configuration options can be configured for -cinder-volume and cinder-backup by adding ceph.conf files to -/etc/kolla/config/cinder/cinder-volume and -/etc/kolla/config/cinder/cinder-backup respectively. They -will be merged with /etc/kolla/config/cinder/ceph.conf. - -Ceph keyrings are deployed per service and placed into -cinder-volume and cinder-backup directories: - -.. note:: - - ``cinder-backup`` requires two keyrings for accessing volumes - and backup pool. - -:: - - root@deploy:/etc/kolla/config# cat - cinder/cinder-backup/ceph.client.cinder.keyring - [client.cinder] - key = AQAg5YRXpChaGRAAlTSCleesthCRmCYrfQVX1w== - root@deploy:/etc/kolla/config# cat - cinder/cinder-backup/ceph.client.cinder-backup.keyring - [client.cinder-backup] - key = AQC9wNBYrD8MOBAAwUlCdPKxWZlhkrWIDE1J/w== - root@deploy:/etc/kolla/config# cat - cinder/cinder-volume/ceph.client.cinder.keyring - [client.cinder] - key = AQAg5YRXpChaGRAAlTSCleesthCRmCYrfQVX1w== - -It is important that the files are named ceph.client*. - -Nova ------- - -Put ceph.conf, nova client keyring file and cinder client keyring file into -``/etc/kolla/config/nova``: - -:: - - $ ls /etc/kolla/config/nova - ceph.client.cinder.keyring ceph.client.nova.keyring ceph.conf - -Configure nova-compute to use Ceph as the ephemeral back end by creating -``/etc/kolla/config/nova/nova-compute.conf`` and adding the following -contents: - -:: - - [libvirt] - images_rbd_pool=vms - images_type=rbd - images_rbd_ceph_conf=/etc/ceph/ceph.conf - rbd_user=nova - -.. note:: ``rbd_user`` might vary depending on your environment. diff --git a/doc/hyperv-guide.rst b/doc/hyperv-guide.rst deleted file mode 100644 index 3b175267b..000000000 --- a/doc/hyperv-guide.rst +++ /dev/null @@ -1,174 +0,0 @@ -.. _hyperv-guide: - -==================== -Nova-HyperV in Kolla -==================== - -Overview -======== -Currently, Kolla can deploy the following OpenStack services for Hyper-V: - -* nova-compute -* neutron-hyperv-agent -* wsgate - -It is possible to use Hyper-V as a compute node within an OpenStack Deployment. -The nova-compute service runs as openstack-compute, a 64-bit service directly -upon the Windows platform with the Hyper-V role enabled. The necessary Python -components as well as the nova-compute service are installed directly onto -the Windows platform. Windows Clustering Services are not needed for -functionality within the OpenStack infrastructure. - -The wsgate is the FreeRDP-WebConnect service that is used for accessing -virtual machines from Horizon web interface. - -.. note:: - - HyperV services are not currently deployed as containers. This functionality - is in development. The current implementation installs OpenStack services - via MSIs. - - -.. note:: - - HyperV services do not currently support outside the box upgrades. Manual - upgrades are required for this process. MSI release versions can be found - `here - `__. - To upgrade an existing MSI to a newer version, simply uninstall the current - MSI and install the newer one. This will not delete the configuration files. - To preserve the configuration files, check the Skip configuration checkbox - during installation. - - -Preparation for Hyper-V node -============================ - -Ansible communicates with Hyper-V host via WinRM protocol. An HTTPS WinRM -listener needs to be configured on the Hyper-V host, which can be easily -created with -`this PowerShell script -`__. - - -A virtual switch has to be created with which Hyper-V virtual machines -communicate with OpenStack. To quickly enable an interface to be used as a -Virtual Interface the following PowerShell may be used: - -.. code-block:: console - - PS C:\> $if = Get-NetIPAddress -IPAddress 192* | Get-NetIPInterface - PS C:\> New-VMSwitch -NetAdapterName $if.ifAlias -Name YOUR_BRIDGE_NAME -AllowManagementOS $false - -.. note:: - - It is very important to make sure that when you are using a Hyper-V node with only 1 NIC the - -AllowManagementOS option is set on True, otherwise you will lose connectivity to the Hyper-V node. - - -To prepare the Hyper-V node to be able to attach to volumes provided by -cinder you must first make sure the Windows iSCSI initiator service is -running and started automatically. - -.. code-block:: console - - PS C:\> Set-Service -Name MSiSCSI -StartupType Automatic - PS C:\> Start-Service MSiSCSI - - - -Preparation for Kolla deployer node -=================================== - -Hyper-V role is required, enable it in ``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_hyperv: "yes" - -Hyper-V options are also required in ``/etc/kolla/globals.yml``: - -.. code-block:: console - - hyperv_username: - hyperv_password: - vswitch_name: - nova_msi_url: "https://www.cloudbase.it/downloads/HyperVNovaCompute_Beta.msi" - -If tenant networks are to be built using VLAN add corresponding type in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - neutron_tenant_network_types: 'flat,vlan' - -The virtual switch is the same one created on the HyperV setup part. -For nova_msi_url, different Nova MSI (Mitaka/Newton/Ocata) versions can -be found on `Cloudbase website -`__. - - -Add the Hyper-V node in ``ansible/inventory`` file: - -.. code-block:: console - - [hyperv] - - - [hyperv:vars] - ansible_user= - ansible_password= - ansible_port=5986 - ansible_connection=winrm - ansible_winrm_server_cert_validation=ignore - -``pywinrm`` package needs to be installed in order for Ansible to work -on the HyperV node: - -.. code-block:: console - - pip install "pywinrm>=0.2.2" - -.. note:: - - In case of a test deployment with controller and compute nodes as virtual machines - on Hyper-V, if VLAN tenant networking is used, trunk mode has to be enabled on the - VMs: - -.. code-block:: console - - Set-VMNetworkAdapterVlan -Trunk -AllowedVlanIdList -NativeVlanId 0 - -networking-hyperv mechanism driver is needed for neutron-server to -communicate with HyperV nova-compute. This can be built with source -images by default. Manually it can be intalled in neutron-server -container with pip: - -.. code-block:: console - - pip install "networking-hyperv>=4.0.0" - -For neutron_extension_drivers, ``port_security`` and ``qos`` are -currently supported by the networking-hyperv mechanism driver. -By default only ``port_security`` is set. - - -Verify Operations -================= - -OpenStack HyperV services can be inspected and managed from PowerShell: - -.. code-block:: console - - PS C:\> Get-Service nova-compute - PS C:\> Get-Service neutron-hyperv-agent - -.. code-block:: console - - PS C:\> Restart-Service nova-compute - PS C:\> Restart-Service neutron-hyperv-agent - - -For more information on OpenStack HyperV, see -`Hyper-V virtualization platform -`__. diff --git a/doc/index.rst b/doc/index.rst deleted file mode 100644 index ea02ce5f1..000000000 --- a/doc/index.rst +++ /dev/null @@ -1,90 +0,0 @@ -.. - Copyright 2014-2015 OpenStack Foundation - All Rights Reserved. - - Licensed under the Apache License, Version 2.0 (the "License"); you may - not use this file except in compliance with the License. You may obtain - a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - License for the specific language governing permissions and limitations - under the License. - -========================================= -Welcome to Kolla-Ansible's documentation! -========================================= - -Kolla's Mission -=============== - -Kolla's mission is to provide production-ready containers and deployment tools -for operating OpenStack clouds. - -Kolla-Ansible is highly opinionated out of the box, but allows for complete -customization. This permits operators with minimal experience to deploy -OpenStack quickly and as experience grows modify the OpenStack configuration to -suit the operator's exact requirements. - -For information on building container images for use with Kolla-Ansible, please -refer to the `Kolla image documentation -`_. - - -Overview -======== - -.. toctree:: - :maxdepth: 1 - - deployment-philosophy - production-architecture-guide - quickstart - multinode - multi-regions - advanced-configuration - operating-kolla - security - kolla-for-openstack-development - troubleshooting - -Services -======== - -.. toctree:: - :maxdepth: 1 - - ceph-guide - central-logging-guide - external-ceph-guide - cinder-guide - cinder-guide-hnas - designate-guide - hyperv-guide - ironic-guide - manila-guide - manila-hnas-guide - nova-fake-driver - swift-guide - bifrost - networking-guide - kuryr-guide - zun-guide - osprofiler-guide - skydive-guide - vmware-guide - tacker-guide - -Developer Docs -============== - -.. toctree:: - :maxdepth: 1 - - CONTRIBUTING - vagrant-dev-env - running-tests - bug-triage diff --git a/doc/ironic-guide.rst b/doc/ironic-guide.rst deleted file mode 100644 index 0d324b2ef..000000000 --- a/doc/ironic-guide.rst +++ /dev/null @@ -1,75 +0,0 @@ -.. _ironic-guide: - -=============== -Ironic in Kolla -=============== - -Overview -======== -Currently Kolla can deploy the Ironic services: - -- ironic-api -- ironic-conductor -- ironic-inspector - -As well as a required PXE service, deployed as ironic-pxe. - -Current status -============== -The Ironic implementation is "tech preview", so currently instances can only be -deployed on baremetal. Further work will be done to allow scheduling for both -virtualized and baremetal deployments. - -Pre-deployment Configuration -============================ - -Enable Ironic role in ``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_ironic: "yes" - -Beside that an additional network type 'vlan,flat' has to be added to a list of -tenant network types: - -.. code-block:: console - - neutron_tenant_network_types: "vxlan,vlan,flat" - -Configuring Web Console -======================= -Configuration based off upstream web_console_documentation_. - -Serial speed must be the same as the serial configuration in the BIOS settings. -Default value: 115200bps, 8bit, non-parity.If you have different serial speed. - -Set ironic_console_serial_speed in ``/etc/kolla/globals.yml``: - -:: - - ironic_console_serial_speed: 9600n8 - -.. _web_console_documentation: https://docs.openstack.org/ironic/latest/admin/console.html#node-web-console - -Post-deployment configuration -============================= -Configuration based off upstream documentation_. - -Again, remember that enabling Ironic reconfigures nova compute (driver and -scheduler) as well as changes neutron network settings. Further neutron setup -is required as outlined below. - -Create the flat network to launch the instances: -:: - - neutron net-create --tenant-id $TENANT_ID sharednet1 --shared \ - --provider:network_type flat --provider:physical_network physnet1 - - neutron subnet-create sharednet1 $NETWORK_CIDR --name $SUBNET_NAME \ - --ip-version=4 --gateway=$GATEWAY_IP --allocation-pool \ - start=$START_IP,end=$END_IP --enable-dhcp - -And then the above ID is used to set cleaning_network in the neutron -section of ironic.conf. - -.. _documentation: https://docs.openstack.org/ironic/latest/install/index.html diff --git a/doc/kolla-for-openstack-development.rst b/doc/kolla-for-openstack-development.rst deleted file mode 100644 index af2d1f9f1..000000000 --- a/doc/kolla-for-openstack-development.rst +++ /dev/null @@ -1,76 +0,0 @@ -===================================== -Using Kolla For OpenStack Development -===================================== - -Kolla-ansible can be used to deploy containers in a way suitable for doing -development on OpenStack services. - -.. note:: - - This functionality is new in the Pike release. - -Heat was the first service to be supported, and so the following will use -submitting a patch to Heat using Kolla as an example. - -Only source containers are supported. - -.. WARNING:: - - Kolla dev mode is intended for OpenStack hacking/development only. Do not - use this in production! - -Enabling Kolla "dev mode" -------------------------- - -To enable dev mode for all supported services, set in -``/etc/kolla/globals.yml``: - -:: - - kolla_dev_mode: true - -To enable it just for heat, set: - -:: - - heat_dev_mode: true - -Usage ------ - -When enabled, the source repo for the service in question will be cloned under -``/opt/stack/`` on the target node(s). This will be bind mounted into the -container's virtualenv under the location expected by the service on startup. - -After making code changes, simply restart the container to pick them up: - -:: - - docker restart heat_api - -Debugging ---------- - -``remote_pdb`` can be used to perform debugging with Kolla containers. First, -make sure it is installed in the container in question: - -:: - - docker exec -it -u root heat_api pip install remote_pdb - -Then, set your breakpoint as follows: - -:: - - from remote_pdb import RemotePdb - RemotePdb('127.0.0.1', 4444).set_trace() - -Once you run the code(restart the container), pdb can be accessed using -``socat``: - -:: - - socat readline tcp:127.0.0.1:4444 - -For more information on remote_pdb, see -https://pypi.python.org/pypi/remote-pdb. diff --git a/doc/kollanet.png b/doc/kollanet.png deleted file mode 100644 index cfb0c6014..000000000 Binary files a/doc/kollanet.png and /dev/null differ diff --git a/doc/kuryr-guide.rst b/doc/kuryr-guide.rst deleted file mode 100644 index eb47ef87a..000000000 --- a/doc/kuryr-guide.rst +++ /dev/null @@ -1,63 +0,0 @@ -Kuryr in Kolla -============== - -"Kuryr is a Docker network plugin that uses Neutron to provide networking -services to Docker containers. It provides containerized images for the common -Neutron plugins" [1]. Kuryr requires at least Keystone and neutron. Kolla makes -kuryr deployment faster and accessible. - -Requirements ------------- - -* A minimum of 3 hosts for a vanilla deploy - -Preparation and Deployment --------------------------- - -To allow Docker daemon connect to the etcd, add the following in the -docker.service file. - -:: - - ExecStart= -H tcp://172.16.1.13:2375 -H unix:///var/run/docker.sock --cluster-store=etcd://172.16.1.13:2379 --cluster-advertise=172.16.1.13:2375 - -The IP address is host running the etcd service. ```2375``` is port that -allows Docker daemon to be accessed remotely. ```2379``` is the etcd listening -port. - -By default etcd and kuryr are disabled in the ``group_vars/all.yml``. -In order to enable them, you need to edit the file globals.yml and set the -following variables - -:: - - enable_etcd: "yes" - enable_kuryr: "yes" - -Deploy the OpenStack cloud and kuryr network plugin - -:: - - kolla-ansible deploy - -Create a Virtual Network --------------------------------- - -:: - - docker network create -d kuryr --ipam-driver=kuryr --subnet=10.1.0.0/24 --gateway=10.1.0.1 docker-net1 - -To list the created network: - -:: - - docker network ls - -The created network is also available from OpenStack CLI: - -:: - - openstack network list - - -[1] https://github.com/openstack/kuryr diff --git a/doc/manila-guide.rst b/doc/manila-guide.rst deleted file mode 100644 index d72a3b30c..000000000 --- a/doc/manila-guide.rst +++ /dev/null @@ -1,357 +0,0 @@ -.. _manila-guide: - -=============== -Manila in Kolla -=============== - -Overview -======== -Currently, Kolla can deploy following manila services: - -* manila-api -* manila-scheduler -* manila-share - -The OpenStack Shared File Systems service (Manila) provides file storage to a -virtual machine. The Shared File Systems service provides an infrastructure -for managing and provisioning of file shares. The service also enables -management of share types as well as share snapshots if a driver supports -them. - -Important -========= - -For simplicity, this guide describes configuring the Shared File Systems -service to use the ``generic`` back end with the driver handles share -server mode (DHSS) enabled that uses Compute (nova), Networking (neutron) -and Block storage (cinder) services. -Networking service configuration requires the capability of networks being -attached to a public router in order to create shared networks. - -Before you proceed, ensure that Compute, Networking and Block storage -services are properly working. - -Preparation and Deployment -========================== - -Cinder and Ceph are required, enable it in ``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_cinder: "yes" - enable_ceph: "yes" - -Enable Manila and generic back end in ``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_manila: "yes" - enable_manila_backend_generic: "yes" - -By default Manila uses instance flavor id 100 for its file systems. For Manila -to work, either create a new nova flavor with id 100 (use *nova flavor-create*) -or change *service_instance_flavor_id* to use one of the default nova flavor -ids. -Ex: *service_instance_flavor_id = 2* to use nova default flavor ``m1.small``. - -Create or modify the file ``/etc/kolla/config/manila-share.conf`` and add the -contents: - -.. code-block:: console - - [generic] - service_instance_flavor_id = 2 - -Verify Operation -================ - -Verify operation of the Shared File Systems service. List service components -to verify successful launch of each process: - -.. code-block:: console - - # manila service-list - +------------------+----------------+------+---------+-------+----------------------------+-----------------+ - | Binary | Host | Zone | Status | State | Updated_at | Disabled Reason | - +------------------+----------------+------+---------+-------+----------------------------+-----------------+ - | manila-scheduler | controller | nova | enabled | up | 2014-10-18T01:30:54.000000 | None | - | manila-share | share1@generic | nova | enabled | up | 2014-10-18T01:30:57.000000 | None | - +------------------+----------------+------+---------+-------+----------------------------+-----------------+ - -Launch an Instance -================== - -Before being able to create a share, the manila with the generic driver and the -DHSS mode enabled requires the definition of at least an image, a network and a -share-network for being used to create a share server. For that back end -configuration, the share server is an instance where NFS/CIFS shares are -served. - -Determine the configuration of the share server -=============================================== - -Create a default share type before running manila-share service: - -.. code-block:: console - - # manila type-create default_share_type True - +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ - | ID | Name | Visibility | is_default | required_extra_specs | optional_extra_specs | - +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ - | 8a35da28-0f74-490d-afff-23664ecd4f01 | default_share_type | public | - | driver_handles_share_servers : True | snapshot_support : True | - +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ - -Create a manila share server image to the Image service: - -.. code-block:: console - - # wget http://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2 - # glance image-create --name "manila-service-image" \ - --file manila-service-image-master.qcow2 \ - --disk-format qcow2 --container-format bare \ - --visibility public --progress - [=============================>] 100% - +------------------+--------------------------------------+ - | Property | Value | - +------------------+--------------------------------------+ - | checksum | 48a08e746cf0986e2bc32040a9183445 | - | container_format | bare | - | created_at | 2016-01-26T19:52:24Z | - | disk_format | qcow2 | - | id | 1fc7f29e-8fe6-44ef-9c3c-15217e83997c | - | min_disk | 0 | - | min_ram | 0 | - | name | manila-service-image | - | owner | e2c965830ecc4162a002bf16ddc91ab7 | - | protected | False | - | size | 306577408 | - | status | active | - | tags | [] | - | updated_at | 2016-01-26T19:52:28Z | - | virtual_size | None | - | visibility | public | - +------------------+--------------------------------------+ - -List available networks to get id and subnets of the private network: - -.. code-block:: console - - +--------------------------------------+---------+----------------------------------------------------+ - | id | name | subnets | - +--------------------------------------+---------+----------------------------------------------------+ - | 0e62efcd-8cee-46c7-b163-d8df05c3c5ad | public | 5cc70da8-4ee7-4565-be53-b9c011fca011 10.3.31.0/24 | - | 7c6f9b37-76b4-463e-98d8-27e5686ed083 | private | 3482f524-8bff-4871-80d4-5774c2730728 172.16.1.0/24 | - +--------------------------------------+---------+----------------------------------------------------+ - -Create a shared network - -.. code-block:: console - - # manila share-network-create --name demo-share-network1 \ - --neutron-net-id PRIVATE_NETWORK_ID \ - --neutron-subnet-id PRIVATE_NETWORK_SUBNET_ID - +-------------------+--------------------------------------+ - | Property | Value | - +-------------------+--------------------------------------+ - | name | demo-share-network1 | - | segmentation_id | None | - | created_at | 2016-01-26T20:03:41.877838 | - | neutron_subnet_id | 3482f524-8bff-4871-80d4-5774c2730728 | - | updated_at | None | - | network_type | None | - | neutron_net_id | 7c6f9b37-76b4-463e-98d8-27e5686ed083 | - | ip_version | None | - | nova_net_id | None | - | cidr | None | - | project_id | e2c965830ecc4162a002bf16ddc91ab7 | - | id | 58b2f0e6-5509-4830-af9c-97f525a31b14 | - | description | None | - +-------------------+--------------------------------------+ - -Create a flavor (**Required** if you not defined *manila_instance_flavor_id* in -``/etc/kolla/config/manila-share.conf`` file) - -.. code-block:: console - - # nova flavor-create manila-service-flavor 100 128 0 1 - -Create a share -============== - -Create a NFS share using the share network: - -.. code-block:: console - - # manila create NFS 1 --name demo-share1 --share-network demo-share-network1 - +-----------------------------+--------------------------------------+ - | Property | Value | - +-----------------------------+--------------------------------------+ - | status | None | - | share_type_name | None | - | description | None | - | availability_zone | None | - | share_network_id | None | - | export_locations | [] | - | host | None | - | snapshot_id | None | - | is_public | False | - | task_state | None | - | snapshot_support | True | - | id | 016ca18f-bdd5-48e1-88c0-782e4c1aa28c | - | size | 1 | - | name | demo-share1 | - | share_type | None | - | created_at | 2016-01-26T20:08:50.502877 | - | export_location | None | - | share_proto | NFS | - | consistency_group_id | None | - | source_cgsnapshot_member_id | None | - | project_id | 48e8c35b2ac6495d86d4be61658975e7 | - | metadata | {} | - +-----------------------------+--------------------------------------+ - -After some time, the share status should change from ``creating`` -to ``available``: - -.. code-block:: console - - # manila list - +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ - | ID | Name | Size | Share Proto | Status | Is Public | Share Type Name | Host | Availability Zone | - +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ - | e1e06b14-ba17-48d4-9e0b-ca4d59823166 | demo-share1 | 1 | NFS | available | False | default_share_type | share1@generic#GENERIC | nova | - +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ - -Configure user access to the new share before attempting to mount it via the -network: - -.. code-block:: console - - # manila access-allow demo-share1 ip INSTANCE_PRIVATE_NETWORK_IP - -Mount the share from an instance -================================ - -Get export location from share - -.. code-block:: console - - # manila show demo-share1 - +-----------------------------+----------------------------------------------------------------------+ - | Property | Value | - +-----------------------------+----------------------------------------------------------------------+ - | status | available | - | share_type_name | default_share_type | - | description | None | - | availability_zone | nova | - | share_network_id | fa07a8c3-598d-47b5-8ae2-120248ec837f | - | export_locations | | - | | path = 10.254.0.3:/shares/share-422dc546-8f37-472b-ac3c-d23fe410d1b6 | - | | preferred = False | - | | is_admin_only = False | - | | id = 5894734d-8d9a-49e4-b53e-7154c9ce0882 | - | | share_instance_id = 422dc546-8f37-472b-ac3c-d23fe410d1b6 | - | share_server_id | 4782feef-61c8-4ffb-8d95-69fbcc380a52 | - | host | share1@generic#GENERIC | - | access_rules_status | active | - | snapshot_id | None | - | is_public | False | - | task_state | None | - | snapshot_support | True | - | id | e1e06b14-ba17-48d4-9e0b-ca4d59823166 | - | size | 1 | - | name | demo-share1 | - | share_type | 6e1e803f-1c37-4660-a65a-c1f2b54b6e17 | - | has_replicas | False | - | replication_type | None | - | created_at | 2016-03-15T18:59:12.000000 | - | share_proto | NFS | - | consistency_group_id | None | - | source_cgsnapshot_member_id | None | - | project_id | 9dc02df0f2494286ba0252b3c81c01d0 | - | metadata | {} | - +-----------------------------+----------------------------------------------------------------------+ - - -Create a folder where the mount will be placed: - -.. code-block:: console - - # mkdir ~/test_folder - -Mount the NFS share in the instance using the export location of the share: - -.. code-block:: console - - # mount -v 10.254.0.3:/shares/share-422dc546-8f37-472b-ac3c-d23fe410d1b6 ~/test_folder - -Share Migration -=============== - -As administrator, you can migrate a share with its data from one location to -another in a manner that is transparent to users and workloads. You can use -manila client commands to complete a share migration. - -For share migration, is needed modify ``manila.conf`` and set a ip in the same -provider network for ``data_node_access_ip``. - -Modify the file ``/etc/kolla/config/manila.conf`` and add the contents: - -.. code-block:: console - - [DEFAULT] - data_node_access_ip = 10.10.10.199 - - -.. note:: - - Share migration requires have more than one back end configured. - `Configure multiple back ends - `__. - -Use the manila migration command, as shown in the following example: - -.. code-block:: console - - manila migration-start --preserve-metadata True|False \ - --writable True|False --force_host_assisted_migration True|False \ - --new_share_type share_type --new_share_network share_network \ - shareID destinationHost - -- ``--force-host-copy``: Forces the generic host-based migration mechanism and - bypasses any driver optimizations. -- ``destinationHost``: Is in this format ``host#pool`` which includes - destination host and pool. -- ``--writable`` and ``--preserve-metadata``: Are only for driver assisted. -- ``--new_share_network``: Only if driver supports shared network. -- ``--new_share_type``: Choose share type compatible with destinationHost. - -Checking share migration progress ---------------------------------- - -Use the ``manila migration-get-progress shareID`` command to check progress. - -.. code-block:: console - - manila migration-get-progress demo-share1 - +----------------+-----------------------+ - | Property | Value | - +----------------+-----------------------+ - | task_state | data_copying_starting | - | total_progress | 0 | - +----------------+-----------------------+ - - manila migration-get-progress demo-share1 - +----------------+-------------------------+ - | Property | Value | - +----------------+-------------------------+ - | task_state | data_copying_completing | - | total_progress | 100 | - +----------------+-------------------------+ - -Use the ``manila migration-complete shareID`` command to complete share -migration process - -For more information about how to manage shares, see the -`OpenStack User Guide -`__. diff --git a/doc/manila-hnas-guide.rst b/doc/manila-hnas-guide.rst deleted file mode 100644 index 258c7e5b8..000000000 --- a/doc/manila-hnas-guide.rst +++ /dev/null @@ -1,330 +0,0 @@ -.. _manila-hnas-guide: - -======================================================== -Hitachi NAS Platform File Services Driver for OpenStack -======================================================== - -Overview -======== -The Hitachi NAS Platform File Services Driver for OpenStack -provides NFS Shared File Systems to OpenStack. - - -Requirements ------------- -- Hitachi NAS Platform Models 3080, 3090, 4040, 4060, 4080, and 4100. - -- HNAS/SMU software version is 12.2 or higher. - -- HNAS configuration and management utilities to create a storage pool (span) - and an EVS. - - - GUI (SMU). - - - SSC CLI. - - -Supported shared file systems and operations --------------------------------------------- -The driver supports CIFS and NFS shares. - -The following operations are supported: - -- Create a share. - -- Delete a share. - -- Allow share access. - -- Deny share access. - -- Create a snapshot. - -- Delete a snapshot. - -- Create a share from a snapshot. - -- Extend a share. - -- Shrink a share. - -- Manage a share. - -- Unmanage a share. - - -Preparation and Deployment -========================== - -.. note:: - - The manila-share node only requires the HNAS EVS data interface if you - plan to use share migration. - -.. important :: - - It is mandatory that HNAS management interface is reachable from the - Shared File System node through the admin network, while the selected - EVS data interface is reachable from OpenStack Cloud, such as through - Neutron flat networking. - - -Configuration on Kolla deployment ---------------------------------- - -Enable Shared File Systems service and HNAS driver in -``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_manila: "yes" - enable_manila_backend_hnas: "yes" - -Configure the OpenStack networking so it can reach HNAS Management -interface and HNAS EVS Data interface. - -To configure two physical networks, physnet1 and physnet2, with -ports eth1 and eth2 associated respectively: - -In ``/etc/kolla/globals.yml`` set: - -.. code-block:: console - - neutron_bridge_name: "br-ex,br-ex2" - neutron_external_interface: "eth1,eth2" - -.. note:: - - eth1: Neutron external interface. - eth2: HNAS EVS data interface. - - -HNAS back end configuration ---------------------------- - -In ``/etc/kolla/globals.yml`` uncomment and set: - -.. code-block:: console - - hnas_ip: "172.24.44.15" - hnas_user: "supervisor" - hnas_password: "supervisor" - hnas_evs_id: "1" - hnas_evs_ip: "10.0.1.20" - hnas_file_system_name: "FS-Manila" - - -Configuration on HNAS ---------------------- - -Create the data HNAS network in Kolla OpenStack: - -List the available tenants: - -.. code-block:: console - - $ openstack project list - -Create a network to the given tenant (service), providing the tenant ID, -a name for the network, the name of the physical network over which the -virtual network is implemented, and the type of the physical mechanism by -which the virtual network is implemented: - -.. code-block:: console - - $ neutron net-create --tenant-id hnas_network \ - --provider:physical_network=physnet2 --provider:network_type=flat - -*Optional* - List available networks: - -.. code-block:: console - - $ neutron net-list - -Create a subnet to the same tenant (service), the gateway IP of this subnet, -a name for the subnet, the network ID created before, and the CIDR of -subnet: - -.. code-block:: console - - $ neutron subnet-create --tenant-id --gateway \ - --name hnas_subnet - -*Optional* - List available subnets: - -.. code-block:: console - - $ neutron subnet-list - -Add the subnet interface to a router, providing the router ID and subnet -ID created before: - -.. code-block:: console - - $ neutron router-interface-add - -Create a file system on HNAS. See the `Hitachi HNAS reference `_. - -.. important :: - - Make sure that the filesystem is not created as a replication target. - Refer official HNAS administration guide. - -Prepare the HNAS EVS network. - -Create a route in HNAS to the tenant network: - -.. code-block:: console - - $ console-context --evs route-net-add --gateway \ - - -.. important :: - - Make sure multi-tenancy is enabled and routes are configured per EVS. - -.. code-block:: console - - $ console-context --evs 3 route-net-add --gateway 192.168.1.1 \ - 10.0.0.0/24 - - -Create a share -============== - -Create a default share type before running manila-share service: - -.. code-block:: console - - $ manila type-create default_share_hitachi False - - +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ - | ID | Name | visibility | is_default | required_extra_specs | optional_extra_specs | - +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ - | 3e54c8a2-1e50-455e-89a0-96bb52876c35 | default_share_hitachi | public | - | driver_handles_share_servers : False | snapshot_support : True | - +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ - -Create a NFS share using the HNAS back end: - -.. code-block:: console - - manila create NFS 1 \ - --name mysharehnas \ - --description "My Manila share" \ - --share-type default_share_hitachi - -Verify Operation - -.. code-block:: console - - $ manila list - - +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ - | ID | Name | Size | Share Proto | Status | Is Public | Share Type Name | Host | Availability Zone | - +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ - | 721c0a6d-eea6-41af-8c10-72cd98985203 | mysharehnas | 1 | NFS | available | False | default_share_hitachi | control@hnas1#HNAS1 | nova | - +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ - -.. code-block:: console - - $ manila show mysharehnas - - +-----------------------------+-----------------------------------------------------------------+ - | Property | Value | - +-----------------------------+-----------------------------------------------------------------+ - | status | available | - | share_type_name | default_share_hitachi | - | description | My Manila share | - | availability_zone | nova | - | share_network_id | None | - | export_locations | | - | | path = 172.24.53.1:/shares/45ed6670-688b-4cf0-bfe7-34956648fb84 | - | | preferred = False | - | | is_admin_only = False | - | | id = e81e716f-f1bd-47b2-8a56-2c2f9e33a98e | - | | share_instance_id = 45ed6670-688b-4cf0-bfe7-34956648fb84 | - | share_server_id | None | - | host | control@hnas1#HNAS1 | - | access_rules_status | active | - | snapshot_id | None | - | is_public | False | - | task_state | None | - | snapshot_support | True | - | id | 721c0a6d-eea6-41af-8c10-72cd98985203 | - | size | 1 | - | user_id | ba7f6d543713488786b4b8cb093e7873 | - | name | mysharehnas | - | share_type | 3e54c8a2-1e50-455e-89a0-96bb52876c35 | - | has_replicas | False | - | replication_type | None | - | created_at | 2016-10-14T14:50:47.000000 | - | share_proto | NFS | - | consistency_group_id | None | - | source_cgsnapshot_member_id | None | - | project_id | c3810d8bcc3346d0bdc8100b09abbbf1 | - | metadata | {} | - +-----------------------------+-----------------------------------------------------------------+ - -Configure multiple back ends -============================ - -An administrator can configure an instance of Manila to provision shares from -one or more back ends. Each back end leverages an instance of a vendor-specific -implementation of the Manila driver API. - -The name of the back end is declared as a configuration option -share_backend_name within a particular configuration stanza that contains the -related configuration options for that back end. - -So, in the case of an multiple back ends deployment, it is necessary to change -the default share backends before deployment. - -Modify the file ``/etc/kolla/config/manila.conf`` and add the contents: - -.. code-block:: console - - [DEFAULT] - enabled_share_backends = generic,hnas1,hnas2 - -Modify the file ``/etc/kolla/config/manila-share.conf`` and add the contents: - -.. code-block:: console - - [generic] - share_driver = manila.share.drivers.generic.GenericShareDriver - interface_driver = manila.network.linux.interface.OVSInterfaceDriver - driver_handles_share_servers = True - service_instance_password = manila - service_instance_user = manila - service_image_name = manila-service-image - share_backend_name = GENERIC - - [hnas1] - share_backend_name = HNAS1 - share_driver = manila.share.drivers.hitachi.hnas.driver.HitachiHNASDriver - driver_handles_share_servers = False - hitachi_hnas_ip = - hitachi_hnas_user = - hitachi_hnas_password = - hitachi_hnas_evs_id = - hitachi_hnas_evs_ip = - hitachi_hnas_file_system_name = FS-Manila1 - - [hnas2] - share_backend_name = HNAS2 - share_driver = manila.share.drivers.hitachi.hnas.driver.HitachiHNASDriver - driver_handles_share_servers = False - hitachi_hnas_ip = - hitachi_hnas_user = - hitachi_hnas_password = - hitachi_hnas_evs_id = - hitachi_hnas_evs_ip = - hitachi_hnas_file_system_name = FS-Manila2 - -For more information about how to manage shares, see the -`OpenStack User Guide -`__. - -For more information about how HNAS driver works, see -`Hitachi NAS Platform File Services Driver for OpenStack -`__. diff --git a/doc/multi-regions.rst b/doc/multi-regions.rst deleted file mode 100644 index 045f657f6..000000000 --- a/doc/multi-regions.rst +++ /dev/null @@ -1,144 +0,0 @@ -.. _multi-regions: - -====================================== -Multiple Regions Deployment with Kolla -====================================== - -This section describes how to perform a basic multiple regions deployment -with Kolla. A basic multiple regions deployment consists of separate -OpenStack installation in two or more regions (RegionOne, RegionTwo, ...) -with a shared Keystone and Horizon. The rest of this documentation assumes -Keystone and Horizon are deployed in RegionOne, and other regions have -access to the admin endpoint (i.e., ``kolla_internal_fqdn``) of RegionOne. -It also assumes that the operator knows the name of all OpenStack regions -in advance, and considers as many Kolla deployments as there are regions. - -There are specifications of multiple regions deployment at: -``__ -and -``__. - -Deployment of the first region with Keystone and Horizon -======================================================== - -Deployment of the first region results in a typical Kolla deployment -whenever, it is an *all-in-one* or *multinode* deployment (see -:doc:`quickstart`). It only requires slight modifications in the -``/etc/kolla/globals.yml`` configuration file. First of all, ensure that -Keystone and Horizon are enabled: - -:: - - enable_keystone: "yes" - enable_horizon: "yes" - -Then, change the value of ``multiple_regions_names`` to add names of other -regions. In this example, we consider two regions. The current one, -formerly knows as RegionOne, that is hided behind -``openstack_region_name`` variable, and the RegionTwo: - -:: - - openstack_region_name: "RegionOne" - multiple_regions_names: - - "{{ openstack_region_name }}" - - "RegionTwo" - -.. note:: Kolla uses these variables to create necessary endpoints into - Keystone so that services of other regions can access it. Kolla - also updates the Horizon ``local_settings`` to support multiple - regions. - -Finally, note the value of ``kolla_internal_fqdn`` and run -``kolla-ansible``. The ``kolla_internal_fqdn`` value will be used by other -regions to contact Keystone. For the sake of this example, we assume the -value of ``kolla_internal_fqdn`` is ``10.10.10.254``. - -Deployment of other regions -=========================== - -Deployment of other regions follows an usual Kolla deployment except that -OpenStack services connect to the RegionOne's Keystone. This implies to -update the ``/etc/kolla/globals.yml`` configuration file to tell Kolla how -to reach Keystone. In the following, ``kolla_internal_fqdn_r1`` refers to -the value of ``kolla_internal_fqdn`` in RegionOne: - -:: - - kolla_internal_fqdn_r1: 10.10.10.254 - - keystone_admin_url: "{{ admin_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_admin_port }}" - keystone_internal_url: "{{ internal_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_public_port }}" - - openstack_auth: - auth_url: "{{ admin_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_admin_port }}" - username: "admin" - password: "{{ keystone_admin_password }}" - project_name: "admin" - -Configuration files of cinder,nova,neutron,glance... have to be updated to -contact RegionOne's Keystone. Fortunately, Kolla offers to override all -configuration files at the same time thanks to the -``node_custom_config`` variable (see :ref:`service-config`). This -implies to create a ``global.conf`` file with the following content: - -:: - - [keystone_authtoken] - auth_uri = {{ keystone_internal_url }} - auth_url = {{ keystone_admin_url }} - -The Placement API section inside the nova configuration file also has -to be updated to contact RegionOne's Keystone. So create, in the same -directory, a ``nova.conf`` file with below content: - -:: - - [placement] - auth_url = {{ keystone_admin_url }} - -The Heat section inside the configuration file also -has to be updated to contact RegionOne's Keystone. So create, in the same -directory, a ``heat.conf`` file with below content: - -:: - [trustee] - auth_uri = {{ keystone_internal_url }} - auth_url = {{ keystone_internal_url }} - - [ec2authtoken] - auth_uri = {{ keystone_internal_url }} - - [clients_keystone] - auth_uri = {{ keystone_internal_url }} - -The Ceilometer section inside the configuration file also -has to be updated to contact RegionOne's Keystone. So create, in the same -directory, a ``ceilometer.conf`` file with below content: - -:: - [service_credentials] - auth_url = {{ keystone_internal_url }} - -And link the directory that contains these files into the -``/etc/kolla/globals.yml``: - -:: - - node_custom_config: path/to/the/directory/of/global&nova_conf/ - -Also, change the name of the current region. For instance, RegionTwo: - -:: - - openstack_region_name: "RegionTwo" - -Finally, disable the deployment of Keystone and Horizon that are -unnecessary in this region and run ``kolla-ansible``: - -:: - - enable_keystone: "no" - enable_horizon: "no" - -The configuration is the same for any other region. diff --git a/doc/multinode.rst b/doc/multinode.rst deleted file mode 100644 index 75c671fd7..000000000 --- a/doc/multinode.rst +++ /dev/null @@ -1,210 +0,0 @@ -.. _multinode: - -============================= -Multinode Deployment of Kolla -============================= - -.. _deploy_a_registry: - -Deploy a registry -================= - -A Docker registry is a locally hosted registry that replaces the need to pull -from the Docker Hub to get images. Kolla can function with or without a local -registry, however for a multinode deployment some type of registry is -mandatory. Only one registry must be deployed, although HA features exist for -registry services. - -The Docker registry prior to version 2.3 has extremely bad performance because -all container data is pushed for every image rather than taking advantage of -Docker layering to optimize push operations. For more information reference -`pokey registry `__. - -Edit the ``/etc/kolla/globals.yml`` and add the following where 192.168.1.100 -is the IP address of the machine and 5000 is the port where the registry is -currently running: - -:: - - docker_registry = 192.168.1.100:5000 - -The Kolla community recommends using registry 2.3 or later. To deploy registry -with version 2.3 or later, do the following: - -:: - - cd kolla - tools/start-registry - -The Docker registry can be configured as a pull through cache to proxy the -official Kolla images hosted in Docker Hub. In order to configure the local -registry as a pull through cache, in the host machine set the environment -variable ``REGISTRY_PROXY_REMOTEURL`` to the URL for the repository on -Docker Hub. - -:: - - export REGISTRY_PROXY_REMOTEURL=https://registry-1.docker.io - -.. note:: - - Pushing to a registry configured as a pull-through cache is unsupported. - For more information, Reference the `Docker Documentation - `__. - -.. _configure_docker_all_nodes: - -Configure Docker on all nodes -============================= - -.. note:: As the subtitle for this section implies, these steps should be - applied to all nodes, not just the deployment node. - -After starting the registry, it is necessary to instruct Docker that it will -be communicating with an insecure registry. To enable insecure registry -communication on CentOS, modify the ``/etc/sysconfig/docker`` file to contain -the following where 192.168.1.100 is the IP address of the machine where the -registry is currently running: - -:: - - # CentOS - INSECURE_REGISTRY="--insecure-registry 192.168.1.100:5000" - -For Ubuntu, check whether its using upstart or systemd. - -:: - - # stat /proc/1/exe - File: '/proc/1/exe' -> '/lib/systemd/systemd' - -Edit ``/etc/default/docker`` and add: - -:: - - # Ubuntu - DOCKER_OPTS="--insecure-registry 192.168.1.100:5000" - -If Ubuntu is using systemd, additional settings needs to be configured. -Copy Docker's systemd unit file to ``/etc/systemd/system/`` directory: - -:: - - cp /lib/systemd/system/docker.service /etc/systemd/system/docker.service - -Next, modify ``/etc/systemd/system/docker.service``, add ``environmentFile`` -variable and add ``$DOCKER_OPTS`` to the end of ExecStart in ``[Service]`` -section: - -:: - - # CentOS - [Service] - MountFlags=shared - EnvironmentFile=/etc/sysconfig/docker - ExecStart= - ExecStart=/usr/bin/docker daemon $INSECURE_REGISTRY - - # Ubuntu - [Service] - MountFlags=shared - EnvironmentFile=-/etc/default/docker - ExecStart= - ExecStart=/usr/bin/docker daemon -H fd:// $DOCKER_OPTS - -Restart Docker by executing the following commands: - -:: - - # CentOS or Ubuntu with systemd - systemctl daemon-reload - systemctl restart docker - - # Ubuntu with upstart or sysvinit - sudo service docker restart - -.. _edit-inventory: - -Edit the Inventory File -======================= - -The ansible inventory file contains all the information needed to determine -what services will land on which hosts. Edit the inventory file in the -Kolla-Ansible directory ``ansible/inventory/multinode``. If Kolla-Ansible -was installed with pip, it can be found in ``/usr/share/kolla-ansible``. - -Add the IP addresses or hostnames to a group and the services associated with -that group will land on that host. IP addresses or hostnames must be added to -the groups control, network, compute, monitoring and storage. Also, define -additional behavioral inventory parameters such as ``ansible_ssh_user``, -``ansible_become`` and ``ansible_private_key_file/ansible_ssh_pass`` which -controls how ansible interacts with remote hosts. - -.. note:: - - Ansible uses SSH to connect the deployment host and target hosts. For more - information about SSH authentication please reference - `Ansible documentation `__. - -:: - - # These initial groups are the only groups required to be modified. The - # additional groups are for more control of the environment. - [control] - # These hostname must be resolvable from your deployment host - control01 ansible_ssh_user= ansible_become=True ansible_private_key_file= - 192.168.122.24 ansible_ssh_user= ansible_become=True ansible_private_key_file= - -.. note:: - - Additional inventory parameters might be required according to your - environment setup. Reference `Ansible Documentation - `__ for more - information. - - -For more advanced roles, the operator can edit which services will be -associated in with each group. Keep in mind that some services have to be -grouped together and changing these around can break your deployment: - -:: - - [kibana:children] - control - - [elasticsearch:children] - control - - [haproxy:children] - network - -Deploying Kolla -=============== - -.. note:: - - If there are multiple keepalived clusters running within the same layer 2 - network, edit the file ``/etc/kolla/globals.yml`` and specify a - ``keepalived_virtual_router_id``. The ``keepalived_virtual_router_id`` should - be unique and belong to the range 0 to 255. - -.. note:: - - If glance is configured to use ``file`` as backend, only one ``glance_api`` - container will be started. ``File`` is enabled by default when no other - backend is specified in globals.yml - -First, check that the deployment targets are in a state where Kolla may deploy -to them: - -:: - - kolla-ansible prechecks -i - -Run the deployment: - -:: - - kolla-ansible deploy -i - -.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/networking-guide.rst b/doc/networking-guide.rst deleted file mode 100644 index 04f29f3d4..000000000 --- a/doc/networking-guide.rst +++ /dev/null @@ -1,350 +0,0 @@ -.. _networking-guide: - -========================== -Enabling Provider Networks -========================== -Provider networks allow to connect compute instances directly to physical -networks avoiding tunnels. This is necessary for example for some performance -critical applications. Only administrators of OpenStack can create such -networks. For provider networks compute hosts must have external bridge -created and configured by Ansible tasks like it is already done for tenant -DVR mode networking. Normal tenant non-DVR networking does not need external -bridge on compute hosts and therefore operators don't need additional -dedicated network interface. - -To enable provider networks modify the configuration -file ``/etc/kolla/globals.yml``: - -:: - - enable_neutron_provider_networks: "yes" - -=========================== -Enabling Neutron Extensions -=========================== - -Overview -======== -Kolla deploys Neutron by default as OpenStack networking component. This guide -describes configuring and running Neutron extensions like LBaaS, -Networking-SFC, QoS, etc. - -Networking-SFC -============== - -Preparation and deployment --------------------------- - -Modify the configuration file ``/etc/kolla/globals.yml`` and change -the following: - -:: - - enable_neutron_sfc: "yes" - -Networking-SFC is an additional Neutron plugin. For SFC to work, this plugin -has to be installed in ``neutron-server`` container as well. Modify the -configuration file ``/etc/kolla/kolla-build.conf`` and add the following -contents: - -:: - - [neutron-server-plugin-networking-sfc] - type = git - location = https://github.com/openstack/networking-sfc.git - reference = mitaka - -Verification ------------- - -Verify the build and deploy operation of Networking-SFC container. Successful -deployment will bring up an SFC container in the list of running containers. -Run the following command to login into the ``neutron-server`` container: - -:: - - docker exec -it neutron_server bash - -Neutron should provide the following CLI extensions. - -:: - - #neutron help|grep port - - port-chain-create [port_chain] Create a Port Chain. - port-chain-delete [port_chain] Delete a given Port Chain. - port-chain-list [port_chain] List Port Chains that belong - to a given tenant. - port-chain-show [port_chain] Show information of a - given Port Chain. - port-chain-update [port_chain] Update Port Chain's - information. - port-pair-create [port_pair] Create a Port Pair. - port-pair-delete [port_pair] Delete a given Port Pair. - port-pair-group-create [port_pair_group] Create a Port Pair - Group. - port-pair-group-delete [port_pair_group] Delete a given - Port Pair Group. - port-pair-group-list [port_pair_group] List Port Pair Groups - that belongs to a given tenant. - port-pair-group-show [port_pair_group] Show information of a - given Port Pair Group. - port-pair-group-update [port_pair_group] Update Port Pair - Group's information. - port-pair-list [port_pair] List Port Pairs that belongs - to a given tenant. - port-pair-show [port_pair] Show information of a given - Port Pair. - port-pair-update [port_pair] Update Port Pair's - information. - -For setting up a testbed environment and creating a port chain, please refer -to the following link: - - https://wiki.openstack.org/wiki/Neutron/ServiceInsertionAndChaining - -For the source code, please refer to the following link: - - https://github.com/openstack/networking-sfc - - -Neutron VPNaaS (VPN-as-a-Service) -================================= - -Preparation and deployment --------------------------- - -Modify the configuration file ``/etc/kolla/globals.yml`` and change -the following: - -:: - - enable_neutron_vpnaas: "yes" - -Verification ------------- - -VPNaaS is a complex subject, hence this document provides directions for a -simple smoke test to verify the service is up and running. - -On the network node(s), the ``neutron_vpnaas_agent`` should be up (image naming -and versioning may differ depending on deploy configuration): - -:: - - docker ps --filter name=neutron_vpnaas_agent - CONTAINER ID IMAGE - COMMAND CREATED STATUS PORTS - NAMES - 97d25657d55e - operator:5000/kolla/oraclelinux-source-neutron-vpnaas-agent:4.0.0 - "kolla_start" 44 minutes ago Up 44 minutes - neutron_vpnaas_agent - -Kolla-Ansible includes a small script that can be used in tandem with -``tools/init-runonce`` to verify the VPN using two routers and two Nova VMs: - -:: - - tools/init-runonce - tools/init-vpn - -Verify both VPN services are active: - -:: - - neutron vpn-service-list - +--------------------------------------+----------+--------------------------------------+--------+ - | id | name | router_id | status | - +--------------------------------------+----------+--------------------------------------+--------+ - | ad941ec4-5f3d-4a30-aae2-1ab3f4347eb1 | vpn_west | 051f7ce3-4301-43cc-bfbd-7ffd59af539e | ACTIVE | - | edce15db-696f-46d8-9bad-03d087f1f682 | vpn_east | 058842e0-1d01-4230-af8d-0ba6d0da8b1f | ACTIVE | - +--------------------------------------+----------+--------------------------------------+--------+ - -Two VMs can now be booted, one on vpn_east, the other on vpn_west, and -encrypted ping packets observed being sent from one to the other. - -For more information on this and VPNaaS in Neutron refer to the VPNaaS area on -the OpenStack wiki: - - https://wiki.openstack.org/wiki/Neutron/VPNaaS/HowToInstall - https://wiki.openstack.org/wiki/Neutron/VPNaaS - -Networking-ODL -============== - -Preparation and deployment --------------------------- - -Modify the configuration file ``/etc/kolla/globals.yml`` and enable -the following: - -:: - - enable_opendaylight: "yes" - -Networking-ODL is an additional Neutron plugin that allows the OpenDaylight -SDN Controller to utilize its networking virtualization features. -For OpenDaylight to work, the Networking-ODL plugin has to be installed in -the ``neutron-server`` container. In this case, one could use the -neutron-server-opendaylight container and the opendaylight container by -pulling from Kolla dockerhub or by building them locally. - -OpenDaylight globals.yml configurable options with their defaults include: -:: - - opendaylight_release: "0.6.1-Carbon" - opendaylight_mechanism_driver: "opendaylight_v2" - opendaylight_l3_service_plugin: "odl-router_v2" - opendaylight_acl_impl: "learn" - enable_opendaylight_qos: "no" - enable_opendaylight_l3: "yes" - enable_opendaylight_legacy_netvirt_conntrack: "no" - opendaylight_port_binding_type: "pseudo-agentdb-binding" - opendaylight_features: "odl-mdsal-apidocs,odl-netvirt-openstack" - opendaylight_allowed_network_types: '"flat", "vlan", "vxlan"' - -Clustered OpenDaylight Deploy ------------------------------ -High availability clustered OpenDaylight requires modifying the inventory file -and placing three or more hosts in the OpenDaylight or Networking groups. -Note: The OpenDaylight role will allow deploy of one or three plus hosts for -OpenDaylight/Networking role. - -Verification ------------- - -Verify the build and deploy operation of Networking-ODL containers. Successful -deployment will bring up an Opendaylight container in the list of running -containers on network/opendaylight node. - -For the source code, please refer to the following link: - - https://github.com/openstack/networking-odl - - -OVS with DPDK -============= - -Introduction ------------- - -Open vSwitch (ovs) is an open source software virtual switch developed -and distributed via openvswitch.org. -The Data Plane Development Kit (dpdk) is a collection of userspace -libraries and tools that facilitate the development of high-performance -userspace networking applications. - -As of the ovs 2.2 release, the ovs netdev datapath has supported integration -with dpdk for accelerated userspace networking. As of the pike release -of kolla support for deploying ovs with dpdk (ovs-dpdk) has been added -to kolla ansible. The ovs-dpdk role introduced in the pike release has been -tested on centos 7 and ubuntu 16.04 hosts, however, ubuntu is recommended due -to conflicts with the cgroup configuration created by the default systemd -version shipped with centos 7. - -Prerequisites -------------- - -DPDK is a high-performance userspace networking library, as such it has -several requirements to function correctly that are not required when -deploying ovs without dpdk. - -To function efficiently one of the mechanisms dpdk uses to accelerate -memory access is the utilisation of kernel hugepages. The use of hugepage -memory minimises the chance of a translation lookaside buffer(TLB) miss when -translating virtual to physical memory as it increases the total amount of -addressable memory that can be cached via the TLB. Hugepage memory pages are -unswappable contiguous blocks of memory of typically 2MiB or 1GiB in size, -that can be used to facilitate efficient sharing of memory between guests and -a vSwitch or DMA mapping between physical nics and the userspace ovs datapath. - -To deploy ovs-dpdk on a platform a proportion of system memory should -be allocated hugepages. While it is possible to allocate hugepages at runtime -it is advised to allocate them via the kernel command line instead to prevent -memory fragmentation. This can be achieved by adding the following to the grub -config and regenerating your grub file. - -:: - - default_hugepagesz=2M hugepagesz=2M hugepages=25000 - - -As dpdk is a userspace networking library it requires userspace compatible -drivers to be able to control the physical interfaces on the platform. -dpdk technically support 3 kernel drivers igb_uio,uio_pci_generic and vfio_pci. -While it is technically possible to use all 3 only uio_pci_generic and vfio_pci -are recommended for use with kolla. igb_uio is BSD licenced and distributed -as part of the dpdk library. While it has some advantages over uio_pci_generic -loading the igb_uio module will taint the kernel and possibly invalidate -distro support. To successfully deploy ovs-dpdk, vfio_pci or uio_pci_generic -kernel module must be present on the platform. Most distros include vfio_pci -or uio_pci_generic as part of the default kernel though on some distros you -may need to install kernel-modules-extra or the distro equivalent prior to -running kolla-ansible deploy. - -Install -------- - -To enable ovs-dpdk add the following to /etc/kolla/globals.yml - -:: - - ovs_datapath: "netdev" - enable_ovs_dpdk: yes - enable_openvswitch: yes - tunnel_interface: "dpdk_bridge" - neutron_bridge_name: "dpdk_bridge" - -Unlike standard Open vSwitch deployments, the interface specified by -neutron_external_interface should have an ip address assigned. -The ip address assigned to neutron_external_interface will be moved to -the "dpdk_bridge" as part of deploy action. -When using ovs-dpdk the tunnel_interface must be an ovs bridge with a physical -interfaces attached for tunnelled traffic to be accelerated by dpdk. -Note that due to a limitation in ansible variable names which excluded -the use of - in a variable name it is not possible to use the default -br-ex name for the neutron_bridge_name or tunnel_interface. - -At present, the tunnel interface ip is configured using network manager on -on ubuntu and systemd on centos family operating systems. systemd is used -to work around a limitation of the centos network manager implementation which -does not consider the creation of an ovs bridge to be a hotplug event. In -the future, a new config option will be introduced to allow systemd to be used -on all host distros for those who do not wish to enable the network manager -service on ubuntu. - -To manage ovs-dpdk the neutron ovs agent must be configured to use -the netdev datapath_type in the ml2.conf. At present this is not automated -and must be set via kolla's external config support. To set the datapath_type -create a file with the following content at -/etc/kolla/config/neutron/ml2_conf.ini - -:: - - [ovs] - datapath_type = netdev - - -In the future, the requirement to use the external config will be removed by -automatically computing the value of ovs_datapath based on the value of -enable_ovs_dpdk and then using the ovs_datapath variable to template out this -setting in the ml2_conf.ini automatically. - -Limitations ------------ - -Reconfiguration from kernel ovs to ovs dpdk is currently not supported. -Changing ovs datapaths on a deployed node requires neutron config changes -and libvirt xml changes for all running instances including a hard reboot -of the vm. - -When upgrading ovs-dpdk it should be noted that this will always involve -a dataplane outage. Unlike kernel OVS the dataplane for ovs-dpdk executes in -the ovs-vswitchd process. This means the lifetime of the dpdk dataplane is -tied to the lifetime of the ovsdpdk_vswitchd container. As such it is -recommended to always evacuate all vm workloads from a node running ovs-dpdk -prior to upgrading. - -On ubuntu network manager is required for tunnel networking. -This requirement will be removed in the future. diff --git a/doc/nova-fake-driver.rst b/doc/nova-fake-driver.rst deleted file mode 100644 index dd1557710..000000000 --- a/doc/nova-fake-driver.rst +++ /dev/null @@ -1,37 +0,0 @@ -.. nova-fake-driver: - -================ -Nova Fake Driver -================ - -One common question from OpenStack operators is that "how does the control -plane (e.g., database, messaging queue, nova-scheduler ) scales?". To answer -this question, operators setup Rally to drive workload to the OpenStack cloud. -However, without a large number of nova-compute nodes, it becomes difficult to -exercise the control performance. - -Given the built-in feature of Docker container, Kolla enables standing up many -of nova-compute nodes with nova fake driver on a single host. For example, -we can create 100 nova-compute containers on a real host to simulate the -100-hypervisor workload to the nova-conductor and the messaging queue. - -Use nova-fake driver -==================== - -Nova fake driver can not work with all-in-one deployment. This is because the -fake neutron-openvswitch-agent for the fake nova-compute container conflicts -with neutron-openvswitch-agent on the compute nodes. Therefore, in the -inventory the network node must be different than the compute node. - -By default, Kolla uses libvirt driver on the compute node. To use nova-fake -driver, edit the following parameters in ``ansible/group_vars`` or in the -command line options. - -:: - - enable_nova_fake: "yes" - num_nova_fake_per_node: 5 - -Each compute node will run 5 nova-compute containers and 5 -neutron-plugin-agent containers. When booting instance, there will be no real -instances created. But *nova list* shows the fake instances. diff --git a/doc/operating-kolla.rst b/doc/operating-kolla.rst deleted file mode 100644 index 6d08b4206..000000000 --- a/doc/operating-kolla.rst +++ /dev/null @@ -1,129 +0,0 @@ -.. _operating-kolla: - -=============== -Operating Kolla -=============== - -Upgrading -========= -Kolla's strategy for upgrades is to never make a mess and to follow consistent -patterns during deployment such that upgrades from one environment to the next -are simple to automate. - -Kolla implements a one command operation for upgrading an existing deployment -consisting of a set of containers and configuration data to a new deployment. - -Kolla uses the ``x.y.z`` semver nomenclature for naming versions. Kolla's -Liberty version is ``1.0.0`` and the Mitaka version is ``2.0.0``. The Kolla -community commits to release z-stream updates every 45 days that resolve -defects in the stable version in use and publish those images to the Docker Hub -registry. To prevent confusion, the Kolla community recommends using an alpha -identifier ``x.y.z.a`` where ``a`` represents any customization done on the -part of the operator. For example, if an operator intends to modify one of the -Docker files or the repos from the originals and build custom images for the -Liberty version, the operator should start with version 1.0.0.0 and increase -alpha for each release. Alpha tag usage is at discretion of the operator. The -alpha identifier could be a number as recommended or a string of the operator's -choosing. - -If the alpha identifier is not used, Kolla will deploy or upgrade using the -version number information contained in the release. To customize the -version number uncomment openstack_version in globals.yml and specify -the version number desired. - -For example, to deploy a custom built Liberty version built with the -``kolla-build --tag 1.0.0.0`` operation, change globals.yml:: - - openstack_version: 1.0.0.0 - -Then run the command to deploy:: - - kolla-ansible deploy - -If using Liberty and a custom alpha number of 0, and upgrading to 1, change -globals.yml:: - - openstack_version: 1.0.0.1 - -Then run the command to upgrade:: - - kolla-ansible upgrade - -.. note:: Varying degrees of success have been reported with upgrading - the libvirt container with a running virtual machine in it. The libvirt - upgrade still needs a bit more validation, but the Kolla community feels - confident this mechanism can be used with the correct Docker graph driver. - -.. note:: The Kolla community recommends the btrfs or aufs graph drivers for - storing data as sometimes the LVM graph driver loses track of its reference - counting and results in an unremovable container. - -.. note:: Because of system technical limitations, upgrade of a libvirt - container when using software emulation (``virt_type = qemu`` in nova.conf), - does not work at all. This is acceptable because KVM is the recommended - virtualization driver to use with Nova. - - -Tips and Tricks -=============== -Kolla ships with several utilities intended to facilitate ease of operation. - -``tools/cleanup-containers`` is used to remove deployed containers from the -system. This can be useful when you want to do a new clean deployment. It will -preserve the registry and the locally built images in the registry, but will -remove all running Kolla containers from the local Docker daemon. It also -removes the named volumes. - -``tools/cleanup-host`` is used to remove remnants of network changes -triggered on the Docker host when the neutron-agents containers are launched. -This can be useful when you want to do a new clean deployment, particularly one -changing the network topology. - -``tools/cleanup-images --all`` is used to remove all Docker images built by -Kolla from the local Docker cache. - -``kolla-ansible -i INVENTORY deploy`` is used to deploy and start all Kolla -containers.. - -``kolla-ansible -i INVENTORY destroy`` is used to clean up containers and -volumes in the cluster. - -``kolla-ansible -i INVENTORY mariadb_recovery`` is used to recover a -completely stopped mariadb cluster. - -``kolla-ansible -i INVENTORY prechecks`` is used to check if all requirements -are meet before deploy for each of the OpenStack services. - -``kolla-ansible -i INVENTORY post-deploy`` is used to do post deploy on deploy -node to get the admin openrc file. - -``kolla-ansible -i INVENTORY pull`` is used to pull all images for containers. - -``kolla-ansible -i INVENTORY reconfigure`` is used to reconfigure OpenStack -service. - -``kolla-ansible -i INVENTORY upgrade`` is used to upgrades existing OpenStack -Environment. - -``kolla-ansible -i INVENTORY check`` is used to do post-deployment smoke -tests. - -.. note:: - In order to do smoke tests, requires ``kolla_enable_sanity_checks=yes``. - -``kolla-mergepwd --old OLD_PASSWDS --new NEW_PASSWDS --final FINAL_PASSWDS`` -is used to merge passwords from old installation with newly generated -passwords during upgrade of Kolla release. The workflow is: - -- Save old passwords from ``/etc/kolla/passwords.yml`` into - ``passwords.yml.old`` -- Generate new passwords via ``kolla-genpwd`` as ``passwords.yml.new`` -- Merge ``passwords.yml.old`` and ``passwords.yml.new`` into - ``/etc/kolla/passwords.yml`` - -For example:: - - mv /etc/kolla/passwords.yml passwords.yml.old - cp kolla-ansible/etc/kolla/passwords.yml passwords.yml.new - kolla-genpwd -p passwords.yml.new - kolla-mergepwd --old passwords.yml.old --new passwords.yml.new --final /etc/kolla/passwords.yml diff --git a/doc/osprofiler-guide.rst b/doc/osprofiler-guide.rst deleted file mode 100644 index b94b65571..000000000 --- a/doc/osprofiler-guide.rst +++ /dev/null @@ -1,57 +0,0 @@ -.. _osprofiler-guide: - -=================== -OSprofiler in Kolla -=================== - -Overview -======== -OSProfiler provides a tiny but powerful library that is used by most -(soon to be all) OpenStack projects and their corresponding python clients -as well as the Openstack client. -It provides functionality to generate 1 trace per request, that goes -through all involved services. This trace can then be extracted and used -to build a tree of calls which can be quite handy for a variety of reasons -(for example in isolating cross-project performance issues). - -Configuration on Kolla deployment ---------------------------------- - -Enable OSprofiler in ``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_osprofiler: "yes" - enable_elasticsearch: "yes" - -Verify operation ----------------- - -Retrieve ``osprofiler_secret`` key present at ``/etc/kolla/passwords.yml``. - -Profiler UUIDs can be created executing OpenStack clients (Nova, Glance, -Cinder, Heat, Keystone) with ``--profile`` option or using the official -Openstack client with ``--os-profile``. In example to get the OSprofiler trace -UUID for ``openstack server create``. - -.. code-block:: console - - $ openstack --os-profile \ - server create \ - --image cirros \ - --flavor m1.tiny \ - --key-name mykey \ - --nic net-id=${NETWORK_ID} \ - demo - - -The previous command will output the command to retrieve OSprofiler trace. - -.. code-block:: console - - $ osprofiler trace show --html --connection-string \ - elasticsearch://:9200 - -For more information about how OSprofiler works, see -`OSProfiler – Cross-project profiling library -`__. diff --git a/doc/production-architecture-guide.rst b/doc/production-architecture-guide.rst deleted file mode 100644 index afeef30c7..000000000 --- a/doc/production-architecture-guide.rst +++ /dev/null @@ -1,120 +0,0 @@ -.. architecture-guide: - -============================= -Production architecture guide -============================= - -This guide will help with configuring Kolla to suit production needs. It is -meant to answer some questions regarding basic configuration options that Kolla -requires. This document also contains other useful pointers. - -Node types and services running on them -======================================= - -A basic Kolla inventory consists of several types of nodes, known in Ansible as -``groups``. - -* Control - Cloud controller nodes which host control services - like APIs and databases. This group should have odd number of nodes for - quorum. - -* Network - Network nodes host Neutron agents along with - haproxy / keepalived. These nodes will have a floating ip defined in - ``kolla_internal_vip_address``. - -* Compute - Compute nodes for compute services. This is where guest VMs - live. - -* Storage - Storage nodes, for cinder-volume, LVM or ceph-osd. - -* Monitoring - Monitor nodes which host monitoring services. - -Network configuration -===================== - -.. _interface-configuration: - -Interface configuration -*********************** - -In Kolla operators should configure following network interfaces: - -* ``network_interface`` - While it is not used on its own, this provides the - required default for other interfaces below. - -* ``api_interface`` - This interface is used for the management network. The - management network is the network OpenStack services uses to communicate to - each other and the databases. There are known security risks here, so it's - recommended to make this network internal, not accessible from outside. - Defaults to ``network_interface``. - -* ``kolla_external_vip_interface`` - This interface is public-facing one. It's - used when you want HAProxy public endpoints to be exposed in different - network than internal ones. It is mandatory to set this option when - ``kolla_enable_tls_external`` is set to yes. Defaults to - ``network_interface``. - -* ``storage_interface`` - This is the interface that is used by virtual - machines to communicate to Ceph. This can be heavily utilized so it's - recommended to put this network on 10Gig networking. Defaults to - ``network_interface``. - -* ``cluster_interface`` - This is another interface used by Ceph. It's used for - data replication. It can be heavily utilized also and if it becomes a - bottleneck it can affect data consistency and performance of whole cluster. - Defaults to ``network_interface``. - -* ``tunnel_interface`` - This interface is used by Neutron for vm-to-vm traffic - over tunneled networks (like VxLan). Defaults to ``network_interface``. - -* ``neutron_external_interface`` - This interface is required by Neutron. - Neutron will put br-ex on it. It will be used for flat networking as well as - tagged vlan networks. Has to be set separately. - -* ``dns_interface`` - This interface is required by Designate and Bind9. - Is used by public facing DNS requests and queries to bind9 and designate - mDNS services. Defaults to ``network_interface``. - -* ``bifrost_network_interface`` - This interface is required by Bifrost. - Is used to provision bare metal cloud hosts, require L2 connectivity - with the bare metal cloud hosts in order to provide DHCP leases with - PXE boot options. Defaults to ``network_interface``. - -.. WARNING:: - - Ansible facts does not recognize interface names containing dashes, - in example ``br-ex`` or ``bond-0`` cannot be used because ansible will read - them as ``br_ex`` and ``bond_0`` respectively. - -Docker configuration -==================== - -Because Docker is core dependency of Kolla, proper configuration of Docker can -change the experience of Kolla significantly. Following section will highlight -several Docker configuration details relevant to Kolla operators. - -Storage driver -************** - -In certain distributions Docker storage driver defaults to devicemapper, which -can heavily hit performance of builds and deploys. We suggest to use btrfs or -aufs as driver. More details on which storage driver to use in -`Docker documentation `_. - -Volumes -******* - -Kolla puts nearly all of persistent data in Docker volumes. These volumes are -created in Docker working directory, which defaults to - -:: - - /var/lib/docker - -We recommend to ensure that this directory has enough space and is placed on -fast disk as it will affect performance of builds, deploys as well as database -commits and rabbitmq. - -This becomes especially relevant when ``enable_central_logging`` and -``openstack_logging_debug`` are both set to true, as fully loaded 130 node -cluster produced 30-50GB of logs daily. diff --git a/doc/quickstart.rst b/doc/quickstart.rst deleted file mode 100644 index ab52bc58b..000000000 --- a/doc/quickstart.rst +++ /dev/null @@ -1,693 +0,0 @@ -.. quickstart: - -=========== -Quick Start -=========== - -This guide provides step by step instructions to deploy OpenStack using Kolla -and Kolla-Ansible on bare metal servers or virtual machines. - -Host machine requirements -========================= - -The host machine must satisfy the following minimum requirements: - -- 2 network interfaces -- 8GB main memory -- 40GB disk space - -.. note:: - - Root access to the deployment host machine is required. - -Recommended environment -======================= - -This guide recommends using a bare metal server or a virtual machine. Follow -the instructions in this document to get started with deploying OpenStack on -bare metal or a virtual machine with Kolla. - -If developing Kolla on a system that provides VirtualBox or Libvirt in addition -to Vagrant, use the Vagrant virtual environment documented in -`Development Environment with Vagrant `_. - -Prerequisites -============= - -Verify the state of network interfaces. If using a VM spawned on -OpenStack as the host machine, the state of the second interface will be DOWN -on booting the VM. - -:: - - ip addr show - -Bring up the second network interface if it is down. - -:: - - ip link set ens4 up - -Verify if the second interface has an IP address. - -:: - - ip addr show - -Install dependencies -==================== - -Kolla builds images which are used by Kolla-Ansible to deploy OpenStack. The -deployment is tested on CentOS, Oracle Linux and Ubuntu as both container OS -platforms and bare metal deployment targets. - -.. note:: Install is *very* sensitive about version of components. Please - review carefully because default Operating System repos are likely out of - date. - -Dependencies for the stable/mitaka branch are: - -===================== =========== =========== ========================= -Component Min Version Max Version Comment -===================== =========== =========== ========================= -Ansible 1.9.4 <2.0.0 On deployment host -Docker 1.10.0 none On target nodes -Docker Python 1.6.0 none On target nodes -Python Jinja2 2.6.0 none On deployment host -===================== =========== =========== ========================= - -Dependencies for the stable/newton are: - -===================== =========== =========== ========================= -Component Min Version Max Version Comment -===================== =========== =========== ========================= -Ansible 2.0.0 none On deployment host -Docker 1.10.0 none On target nodes -Docker Python 1.6.0 none On target nodes -Python Jinja2 2.8.0 none On deployment host -===================== =========== =========== ========================= - -Dependencies for the stable/ocata branch are: - -===================== =========== =========== ========================= -Component Min Version Max Version Comment -===================== =========== =========== ========================= -Ansible 2.0.0 none On deployment host -Docker 1.10.0 none On target nodes -Docker Python 1.8.1 none On target nodes -Python Jinja2 2.8.0 none On deployment host -===================== =========== =========== ========================= - -Dependencies since pike (including master branch) are: - -===================== =========== =========== ========================= -Component Min Version Max Version Comment -===================== =========== =========== ========================= -Ansible 2.2.0 none On deployment host -Docker 1.10.0 none On target nodes -Docker Python 2.0.0 none On target nodes -Python Jinja2 2.8.0 none On deployment host -===================== =========== =========== ========================= - -Make sure the ``pip`` package manager is installed and upgraded to the latest -before proceeding: - -:: - - #CentOS - yum install epel-release - yum install python-pip - pip install -U pip - - #Ubuntu - apt-get update - apt-get install python-pip - pip install -U pip - -Install dependencies needed to build the code with ``pip`` package manager. - -:: - - #CentOS - yum install python-devel libffi-devel gcc openssl-devel libselinux-python - - #Ubuntu - apt-get install python-dev libffi-dev gcc libssl-dev python-selinux - -Kolla deploys OpenStack using `Ansible `__. Install -Ansible from distribution packaging if the distro packaging has recommended -version available. - -Some implemented distro versions of Ansible are too old to use distro -packaging. Currently, CentOS and RHEL package Ansible >2.0 which is suitable -for use with Kolla. Note that you will need to enable access to the EPEL -repository to install via yum -- to do so, take a look at Fedora's EPEL `docs -`__ and `FAQ -`__. - -On CentOS or RHEL systems, this can be done using: - -:: - - yum install ansible - -Many DEB based systems do not meet Kolla's Ansible version requirements. It is -recommended to use pip to install Ansible >2.0. Finally Ansible >2.0 may be -installed using: - -:: - - pip install -U ansible - -.. note:: It is recommended to use virtualenv to install non-system packages. - -If DEB based systems include a version of Ansible that meets Kolla's version -requirements it can be installed by: - -:: - - apt-get install ansible - -.. WARNING:: - - Kolla uses PBR in its implementation. PBR provides version information - to Kolla about the package in use. This information is later used when - building images to specify the Docker tag used in the image built. When - installing the Kolla package via pip, PBR will always use the PBR version - information. When obtaining a copy of the software via git, PBR will use - the git version information, but **ONLY** if Kolla has not been pip - installed via the pip package manager. This is why there is an operator - workflow and a developer workflow. - -The following dependencies can be installed by bootstraping the host machine -as described in the `Automatic host bootstrap`_ section. For manual -installation, follow the instructions below: - -Since Docker is required to build images as well as be present on all deployed -targets, the Kolla community recommends installing the official Docker, Inc. -packaged version of Docker for maximum stability and compatibility with the -following command: - -:: - - curl -sSL https://get.docker.io | bash - -This command will install the most recent stable version of Docker, but please -note that Kolla releases are not in sync with Docker in any way, so some things -could stop working with new version. The latest release of Kolla is tested to -work with docker-engine>=1.10.0,!=1.13.0. To check your Docker version run this -command: - -:: - - docker --version - -When running with systemd, setup docker-engine with the appropriate information -in the Docker daemon to launch with. This means setting up the following -information in the ``docker.service`` file. If you do not set the MountFlags -option correctly then ``kolla-ansible`` will fail to deploy the -``neutron-dhcp-agent`` container and throws APIError/HTTPError. After adding -the drop-in unit file as follows, reload and restart the Docker service: - -:: - - # Create the drop-in unit directory for docker.service - mkdir -p /etc/systemd/system/docker.service.d - - # Create the drop-in unit file - tee /etc/systemd/system/docker.service.d/kolla.conf <<-'EOF' - [Service] - MountFlags=shared - EOF - -Restart Docker by executing the following commands: - -:: - - # Run these commands to reload the daemon - systemctl daemon-reload - systemctl restart docker - -On the target hosts you also need to install the latest version of the Docker -python libraries with pip: - -:: - - pip install -U docker - - -OpenStack, RabbitMQ, and Ceph require all hosts to have matching times to -ensure proper message delivery. In the case of Ceph, it will complain if the -hosts differ by more than 0.05 seconds. Some OpenStack services have timers as -low as 2 seconds by default. For these reasons it is highly recommended to -setup an NTP service of some kind. While ``ntpd`` will achieve more accurate -time for the deployment if the NTP servers are running in the local deployment -environment, `chrony `_ is more accurate when -syncing the time across a WAN connection. When running Ceph it is recommended -to setup ``ntpd`` to sync time locally due to the tight time constraints. - -To install, start, and enable ntp on CentOS execute the following: - -:: - - # CentOS 7 - yum install ntp - systemctl enable ntpd.service - systemctl start ntpd.service - -To install and start on Debian based systems execute the following: - -:: - - apt-get install ntp - -Libvirt is started by default on many operating systems. Please disable -``libvirt`` on any machines that will be deployment targets. Only one copy of -libvirt may be running at a time. - -:: - - # CentOS 7 - systemctl stop libvirtd.service - systemctl disable libvirtd.service - - # Ubuntu - service libvirt-bin stop - update-rc.d libvirt-bin disable - -On Ubuntu, apparmor will sometimes prevent libvirt from working. - -:: - - /usr/sbin/libvirtd: error while loading shared libraries: - libvirt-admin.so.0: cannot open shared object file: Permission denied - -If you are seeing the libvirt container fail with the error above, disable the -libvirt profile. - -:: - - sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.libvirtd - - -.. note:: - - On Ubuntu 16.04, please uninstall lxd and lxc packages. (An issue exists - with cgroup mounts, mounts exponentially increasing when restarting - container). - -Additional steps for upstart and other non-systemd distros -========================================================== - -For other non-systemd distros, run the following. - -:: - - mount --make-shared /run - mount --make-shared /var/lib/nova/mnt - -If /var/lib/nova/mnt is not present, do the workaround below. - -:: - - mkdir -p /var/lib/nova/mnt /var/lib/nova/mnt1 - mount --bind /var/lib/nova/mnt1 /var/lib/nova/mnt - mount --make-shared /var/lib/nova/mnt - -For mounting /run and /var/lib/nova/mnt as shared upon startup, edit -/etc/rc.local to add the following. - -:: - - mount --make-shared /run - mount --make-shared /var/lib/nova/mnt - -.. note:: - - If CentOS/Fedora/OracleLinux container images are built on an Ubuntu host, - the back-end storage driver must not be AUFS (see the known issues in - `Building Container Images`_). - -Install Kolla for deployment or evaluation -========================================== - -Install kolla-ansible and its dependencies using pip. - -:: - - pip install kolla-ansible - -Copy the configuration files globals.yml and passwords.yml to /etc directory. - -:: - - #CentOS - cp -r /usr/share/kolla-ansible/etc_examples/kolla /etc/kolla/ - - #Ubuntu - cp -r /usr/local/share/kolla-ansible/etc_examples/kolla /etc/kolla/ - -The inventory files (all-in-one and multinode) are located in -/usr/local/share/kolla-ansible/ansible/inventory. Copy the configuration files -to the current directory. - -:: - - #CentOS - cp /usr/share/kolla-ansible/ansible/inventory/* . - - #Ubuntu - cp /usr/local/share/kolla-ansible/ansible/inventory/* . - -Install Kolla for development -============================= - -Clone the Kolla and Kolla-Ansible repositories from git. - -:: - - git clone https://github.com/openstack/kolla - git clone https://github.com/openstack/kolla-ansible - -Kolla-ansible holds configuration files (globals.yml and passwords.yml) in -etc/kolla. Copy the configuration files to /etc directory. - -:: - - cp -r kolla-ansible/etc/kolla /etc/kolla/ - -Kolla-ansible holds the inventory files (all-in-one and multinode) in -ansible/inventory. Copy the configuration files to the current directory. - -:: - - cp kolla-ansible/ansible/inventory/* . - -Local Registry -============== - -A local registry is recommended but not required for an ``all-in-one`` -installation when developing for master. Since no master images are available -on docker hub, the docker cache may be used for all-in-one deployments. When -deploying multinode, a registry is strongly recommended to serve as a single -source of images. Reference the -`Multinode Deployment of Kolla `_ -for more information on using a local Docker registry. -Otherwise, the Docker Hub Image Registry contains all -images from each of Kolla’s major releases. The latest release tag is 3.0.2 for -Newton. - -Automatic host bootstrap -======================== - -Edit the ``/etc/kolla/globals.yml`` file to configure interfaces. - -:: - - network_interface: "ens3" - neutron_external_interface: "ens4" - -Generate passwords. This will populate all empty fields in the -``/etc/kolla/passwords.yml`` file using randomly generated values to secure the -deployment. Optionally, the passwords may be populated in the file by hand. - -:: - - kolla-genpwd - -To quickly prepare hosts, playbook bootstrap-servers can be used. This is an -Ansible playbook which works on Ubuntu 16.04 and CentOS 7 hosts to -install and prepare the cluster for OpenStack installation. - -:: - - kolla-ansible -i <> bootstrap-servers - -Build container images -====================== - -When running with systemd, edit the file -``/etc/systemd/system/docker.service.d/kolla.conf`` -to include the MTU size to be used for Docker containers. - -:: - - [Service] - MountFlags=shared - ExecStart= - ExecStart=/usr/bin/docker daemon \ - -H fd:// \ - --mtu 1400 - -.. note:: - - Depend of your Docker version and distro, ExecStart command may be different which may cause - Docker start failures. The default ExecStart command for your system can be obtained from - ``/usr/lib/systemd/system/docker.service``. - -.. note:: - - The MTU size should be less than or equal to the MTU size allowed on the - network interfaces of the host machine. If the MTU size allowed on the - network interfaces of the host machine is 1500 then this step can be - skipped. This step is relevant for building containers. Actual openstack - services won't be affected. - -.. note:: - - Verify that the MountFlags parameter is configured as shared. If you do not - set the MountFlags option correctly then kolla-ansible will fail to deploy the - neutron-dhcp-agent container and throws APIError/HTTPError. - -Restart Docker and ensure that Docker is running. - -:: - - systemctl daemon-reload - systemctl restart docker - -The Kolla community builds and pushes tested images for each tagged release of -Kolla. Pull required images with appropriate tags in target nodes. - -:: - - kolla-ansible pull -i /path/to/all-in-one - -View the images. - -:: - - docker images - -Developers running from master are required to build container images as the -Docker Hub does not contain built images for the master branch. Reference the -`Building Container Images`_ for more advanced build configuration. - -To build images using default parameters run: - -:: - - kolla-build - -By default kolla-build will build all containers using CentOS as the base image -and binary installation as base installation method. To change this behavior, -please use the following parameters with kolla-build: - -:: - - --base [ubuntu|centos|oraclelinux] - --type [binary|source] - -.. note:: - - --base and --type can be added to the above kolla-build command if - different distributions or types are desired. - -It is also possible to build individual container images. As an example, if the -glance images failed to build, all glance related images can be rebuilt as -follows: - -:: - - kolla-build glance - -In order to see all available parameters, run: - -:: - - kolla-build -h - -View the images. - -:: - - docker images - -.. WARNING:: - - Mixing of OpenStack releases with Kolla releases (example, updating - kolla-build.conf to build Mitaka Keystone to be deployed with Newton Kolla) is - not recommended and will likely cause issues. - -Deploy Kolla -============ - -Kolla-Ansible is used to deploy containers by using images built by Kolla. -There are two methods of deployment: *all-in-one* and *multinode*. The -*all-in-one* deployment is similar to `devstack -`__ deploy which installs all -OpenStack services on a single host. In the *multinode* deployment, OpenStack -services can be run on specific hosts. This documentation describes deploying -an *all-in-one* setup. To setup *multinode* see the -`Multinode Deployment of Kolla `_. - -.. note:: - - For *multinode* deployment of kolla, check if all the hostnames are - resolvable. RabbitMQ can't work with IP addresses, so we need to make - sure that all RabbitMQ cluster hosts can resolve each other's hostnames. - -Each method is represented as an Ansible inventory file. More information on -the Ansible inventory file can be found in the Ansible `inventory introduction -`_. - -All variables for the environment can be specified in the files: -``/etc/kolla/globals.yml`` and ``/etc/kolla/passwords.yml``. - -Generate passwords for ``/etc/kolla/passwords.yml`` using the provided -``kolla-genpwd`` tool. The tool will populate all empty fields in the -``/etc/kolla/passwords.yml`` file using randomly generated values to secure the -deployment. Optionally, the passwords may be populate in the file by hand. - -:: - - kolla-genpwd - -Start by editing ``/etc/kolla/globals.yml``. Check and edit, if needed, these -parameters: ``kolla_base_distro``, ``kolla_install_type``. The default for -``kolla_base_distro`` is ``centos`` and for ``kolla_install_type`` is -``binary``. If you want to use ubuntu with source type, then you should make -sure globals.yml has the following entries: - -:: - - kolla_base_distro: "ubuntu" - kolla_install_type: "source" - -Please specify an unused IP address in the network to act as a VIP for -``kolla_internal_vip_address``. The VIP will be used with keepalived and added -to the ``api_interface`` as specified in the ``globals.yml`` - -:: - - kolla_internal_vip_address: “192.168.137.79” - -.. note:: - - The kolla_internal_vip_address must be unique and should belong to the same - network to which the first network interface belongs to. - -.. note:: - - The kolla_base_distro and kolla_install_type should be same as base and - install_type used in kolla-build command line. - -The ``network_interface`` variable is the interface to which Kolla binds API -services. For example, when starting Mariadb, it will bind to the IP on the -interface list in the ``network_interface`` variable. - -:: - - network_interface: "ens3" - -The ``neutron_external_interface`` variable is the interface that will be used -for the external bridge in Neutron. Without this bridge the deployment instance -traffic will be unable to access the rest of the Internet. - -:: - - neutron_external_interface: "ens4" - -In case of deployment using the **nested** environment (eg. Using Virtualbox -VM’s, KVM VM’s), verify if your compute node supports hardware acceleration for -virtual machines by executing the following command in the *compute node*. - -:: - - egrep -c '(vmx|svm)' /proc/cpuinfo - -If this command returns a value of **zero**, your compute node does not support -hardware acceleration and you **must** configure libvirt to use **QEMU** -instead of KVM. Create a file /etc/kolla/config/nova/nova-compute.conf and add -the content shown below. - -:: - - mkdir -p /etc/kolla/config/nova - cat << EOF > /etc/kolla/config/nova/nova-compute.conf - [libvirt] - virt_type = qemu - cpu_mode = none - EOF - -For *all-in-one* deployments, the following commands can be run. These will -setup all of the containers on the localhost. These commands will be -wrapped in the kolla-script in the future. - -.. note:: Even for all-in-one installs it is possible to use the Docker - registry for deployment, although not strictly required. - -First, validate that the deployment targets are in a state where Kolla may -deploy to them. Provide the correct path to inventory file in the following -commands. - -:: - - kolla-ansible prechecks -i /path/to/all-in-one - -Deploy OpenStack. - -:: - - kolla-ansible deploy -i /path/to/all-in-one - -List the running containers. - -:: - - docker ps -a - -Generate the ``admin-openrc.sh`` file. The file will be created in -``/etc/kolla/`` directory. - -:: - - kolla-ansible post-deploy - -To test your deployment, run the following commands to initialize the network -with a glance image and neutron networks. - -:: - - . /etc/kolla/admin-openrc.sh - - #centOS - cd /usr/share/kolla-ansible - ./init-runonce - - #ubuntu - cd /usr/local/share/kolla-ansible - ./init-runonce - -.. note:: - - Different hardware results in variance with deployment times. - -After successful deployment of OpenStack, the Horizon dashboard will be -available by entering IP address or hostname from ``kolla_external_fqdn``, or -``kolla_internal_fqdn``. If these variables were not set during deploy they -default to ``kolla_internal_vip_address``. - -.. _Docker Hub Image Registry: https://hub.docker.com/u/kolla/ -.. _launchpad bug: https://bugs.launchpad.net/kolla/+filebug -.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/running-tests.rst b/doc/running-tests.rst deleted file mode 100644 index 317f2d948..000000000 --- a/doc/running-tests.rst +++ /dev/null @@ -1,106 +0,0 @@ -.. _running-tests: - -============= -Running tests -============= - -Kolla-ansible contains a suit of tests in the ``tests`` directory. - -Any proposed code change in gerrit is automatically rejected by the OpenStack -Jenkins server [#f1]_ if the change causes test failures. - -It is recommended for developers to run the test suite before submitting patch -for review. This allows to catch errors as early as possible. - -Preferred way to run the tests -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The preferred way to run the unit tests is using ``tox``. It executes tests in -isolated environment, by creating separate virtualenv and installing -dependencies from the ``requirements.txt`` and ``test-requirements.txt`` files, -so the only package you install is ``tox`` itself: - -.. code-block:: console - - $ pip install tox - -See `the unit testing section of the Testing wiki page`_ for more information. -Following are some simple examples. - -To run the Python 2.7 tests: - -.. code-block:: console - - $ tox -e py27 - -To run the style tests: - -.. code-block:: console - - $ tox -e pep8 - -To run multiple tests separate items by commas: - -.. code-block:: console - - $ tox -e py27,py34,pep8 - -.. _the unit testing section of the Testing wiki page: https://wiki.openstack.org/wiki/Testing#Unit_Tests - -Running a subset of tests -------------------------- - -Instead of running all tests, you can specify an individual directory, file, -class or method that contains test code, i.e. filter full names of tests by a -string. - -To run the tests located only in the ``kolla-ansible/tests`` -directory use: - -.. code-block:: console - - $ tox -e py27 kolla-ansible.tests - -To run the tests of a specific file -say ``kolla-ansible/tests/test_kolla_docker.py``: - -.. code-block:: console - - $ tox -e py27 test_kolla_docker - -To run the tests in the ``ModuleArgsTest`` class in -the ``kolla-ansible/tests/test_kolla_docker.py`` file: - -.. code-block:: console - - $ tox -e py27 test_kolla_docker.ModuleArgsTest - -To run the ``ModuleArgsTest.test_module_args`` test method in -the ``kolla-ansible/tests/test_kolla_docker.py`` file: - -.. code-block:: console - - $ tox -e py27 test_kolla_docker.ModuleArgsTest.test_module_args - -Debugging unit tests ------------------------- - -In order to break into the debugger from a unit test we need to insert -a breaking point to the code: - -.. code-block:: python - - import pdb; pdb.set_trace() - -Then run ``tox`` with the debug environment as one of the following:: - - tox -e debug - tox -e debug test_file_name.TestClass.test_name - -For more information see the `oslotest documentation -`_. - - -.. rubric:: Footnotes - -.. [#f1] See https://docs.openstack.org/infra/system-config/jjb.html diff --git a/doc/security.rst b/doc/security.rst deleted file mode 100644 index f14dabaeb..000000000 --- a/doc/security.rst +++ /dev/null @@ -1,56 +0,0 @@ -.. _security: - -============== -Kolla Security -============== - -Non Root containers -=================== -The OpenStack services, with a few exceptions, run as non root inside of -Kolla's containers. Kolla uses the Docker provided USER flag to set the -appropriate user for each service. - -SELinux -======= -The state of SELinux in Kolla is a work in progress. The short answer is you -must disable it until selinux polices are written for the Docker containers. - -To understand why Kolla needs to set certain selinux policies for services that -you wouldn't expect to need them (rabbitmq, mariadb, glance, etc.) we must take -a step back and talk about Docker. - -Docker has not had the concept of persistent containerized data until recently. -This means when a container is run the data it creates is destroyed when the -container goes away, which is obviously no good in the case of upgrades. - -It was suggested data containers could solve this issue by only holding data if -they were never recreated, leading to a scary state where you could lose access -to your data if the wrong command was executed. The real answer to this problem -came in Docker 1.9 with the introduction of named volumes. You could now -address volumes directly by name removing the need for so called **data -containers** all together. - -Another solution to the persistent data issue is to use a host bind mount which -involves making, for sake of example, host directory ``var/lib/mysql`` -available inside the container at ``var/lib/mysql``. This absolutely solves the -problem of persistent data, but it introduces another security issue, -permissions. With this host bind mount solution the data in ``var/lib/mysql`` -will be owned by the mysql user in the container. Unfortunately, that mysql -user in the container could have any UID/GID and thats who will own the data -outside the container introducing a potential security risk. Additionally, this -method dirties the host and requires host permissions to the directories to -bind mount. - -The solution Kolla chose is named volumes. - -Why does this matter in the case of selinux? Kolla does not run the process it -is launching as root in most cases. So glance-api is run as the glance user, -and mariadb is run as the mysql user, and so on. When mounting a named volume -in the location that the persistent data will be stored it will be owned by the -root user and group. The mysql user has no permissions to write to this folder -now. What Kolla does is allow a select few commands to be run with sudo as the -mysql user. This allows the mysql user to chown a specific, explicit directory -and store its data in a named volume without the security risk and other -downsides of host bind mounts. The downside to this is selinux blocks those -sudo commands and it will do so until we make explicit policies to allow those -operations. diff --git a/doc/skydive-guide.rst b/doc/skydive-guide.rst deleted file mode 100644 index 4e4f201f7..000000000 --- a/doc/skydive-guide.rst +++ /dev/null @@ -1,37 +0,0 @@ -.. _skydive-guide: - -================ -Skydive in Kolla -================ - -Overview -======== -Skydive is an open source real-time network topology and protocols analyzer. -It aims to provide a comprehensive way of understanding what is happening in -the network infrastructure. -Skydive agents collect topology information and flows and forward them to a -central agent for further analysis. -All the information is stored in an Elasticsearch database. - -Configuration on Kolla deployment ---------------------------------- - -Enable Skydive in ``/etc/kolla/globals.yml`` - -.. code-block:: console - - enable_skydive: "yes" - enable_elasticsearch: "yes" - -Verify operation ----------------- - -After successful deployment, Skydive can be accessed using a browser on -``:8085``. - -The default username is ``admin``, the password can be located under -```` in ``/etc/kolla/passwords.yml``. - -For more information about how Skydive works, see -`Skydive – An open source real-time network topology and protocols analyzer -`__. diff --git a/doc/source/conf.py b/doc/source/conf.py new file mode 100644 index 000000000..7219f5feb --- /dev/null +++ b/doc/source/conf.py @@ -0,0 +1,90 @@ +# -*- coding: utf-8 -*- +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or +# implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import os +import sys + +sys.path.insert(0, os.path.abspath('../..')) +# -- General configuration ---------------------------------------------------- + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. +extensions = [ + 'openstackdocstheme', + 'sphinx.ext.autodoc', +] + +# autodoc generation is a bit aggressive and a nuisance when doing heavy +# text edit cycles. +# execute "export SPHINX_DEBUG=1" in your terminal to disable + +# The suffix of source filenames. +source_suffix = '.rst' + +# The master toctree document. +master_doc = 'index' + +# General information about the project. +project = u'kolla-ansible' +copyright = u'2013, OpenStack Foundation' + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. +# +# The short X.Y version. +from kolla_ansible.version import version_info as kolla_version +# The full version, including alpha/beta/rc tags. +release = kolla_version.version_string_with_vcs() +# The short X.Y version. +version = kolla_version.canonical_version_string() + +# If true, '()' will be appended to :func: etc. cross-reference text. +add_function_parentheses = True + +# If true, the current module name will be prepended to all description +# unit titles (such as .. function::). +add_module_names = True + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# -- Options for HTML output -------------------------------------------------- + +# The theme to use for HTML and HTML Help pages. Major themes that come with +# Sphinx are currently 'default' and 'sphinxdoc'. +# html_theme_path = [] +html_theme = 'openstackdocs' +# html_static_path = ['static'] + +# Output file base name for HTML help builder. +htmlhelp_basename = '%sdoc' % project + +# Must set this variable to include year, month, day, hours, and minutes. +html_last_updated_fmt = '%Y-%m-%d %H:%M' + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, author, documentclass +# [howto/manual]). +latex_documents = [ + ('index', + '%s.tex' % project, + u'%s Documentation' % project, + u'OpenStack Foundation', 'manual'), +] + +# openstackdocstheme options +repository_name = 'openstack/kolla-ansible' +bug_project = 'kolla-ansible' +bug_tag = '' diff --git a/doc/source/contributor/CONTRIBUTING.rst b/doc/source/contributor/CONTRIBUTING.rst new file mode 100644 index 000000000..7092cd88b --- /dev/null +++ b/doc/source/contributor/CONTRIBUTING.rst @@ -0,0 +1,133 @@ +.. _CONTRIBUTING: + +================= +How To Contribute +================= + +Basics +====== + +#. Our source code is hosted on `OpenStack Kolla-Ansible Git`_. Bugs should be + filed on launchpad_. + +#. Please follow OpenStack `Gerrit Workflow`_ to contribute to Kolla. + +#. Note the branch you're proposing changes to. ``master`` is the current focus + of development. Kolla project has a strict policy of only allowing backports + in ``stable/branch``, unless when not applicable. A bug in a + ``stable/branch`` will first have to be fixed in ``master``. + +#. Please file a launchpad_ blueprint for any significant code change and a bug + for any significant bug fix or add a TrivialFix tag for simple changes. + See how to reference a bug or a blueprint in the commit message here_ + +#. TrivialFix tags or bugs are not required for documentation changes. + +.. _OpenStack Kolla-Ansible Git: https://git.openstack.org/cgit/openstack/kolla-ansible/ +.. _launchpad: https://bugs.launchpad.net/kolla-ansible +.. _here: https://wiki.openstack.org/wiki/GitCommitMessages + +Development Environment +======================= + +Please follow our `quickstart`_ to deploy your environment and test your +changes. + +.. _quickstart: https://docs.openstack.org/kolla-ansible/latest/quickstart.html + +Please use the existing sandbox repository, available at +https://git.openstack.org/cgit/openstack-dev/sandbox, for learning, understanding +and testing the `Gerrit Workflow`_. + +.. _Gerrit Workflow: https://docs.openstack.org/infra/manual/developers.html#development-workflow + +Adding a new service +==================== + +Kolla aims to both containerise and deploy all services within the OpenStack +"big tent". This is a constantly moving target as the ecosystem grows, so these +guidelines aim to help make adding a new service to Kolla a smooth experience. + +When adding a role for a new service in Ansible, there are couple of patterns +that Kolla uses throughout that should be followed. + +* The sample inventories + + Entries should be added for the service in each of + ``ansible/inventory/multinode`` and ``ansible/inventory/all-in-one``. + +* The playbook + + The main playbook that ties all roles together is in ``ansible/site.yml``, + this should be updated with appropriate roles, tags, and conditions. Ensure + also that supporting hosts such as haproxy are updated when necessary. + +* The common role + + A ``common`` role exists which sets up logging, ``kolla-toolbox`` and other + supporting components. This should be included in all services within + ``meta/main.yml`` of your role. + +* Common tasks + + All services should include the following tasks: + + - ``reconfigure.yml`` : Used to push new configuration files to the host + and restart the service. + + - ``pull.yml`` : Used to pre fetch the image into the Docker image cache + on hosts, to speed up initial deploys. + + - ``upgrade.yml`` : Used for upgrading the service in a rolling fashion. May + include service specific setup and steps as not all services can be + upgraded in the same way. + +* Logrotation + + - For OpenStack services there should be a ``cron-logrotate-PROJECT.conf.j2`` + template file in ``ansible/roles/common/templates`` with the following + content: + + .. code:: + + "/var/log/kolla/PROJECT/*.log" + { + } + + - For OpenStack services there should be an entry in the ``services`` list + in the ``cron.json.j2`` template file in ``ansible/roles/common/templates``. + +* Log delivery + + - For OpenStack services the service should add a new ``rewriterule`` in the + ``match`` element in the ``01-rewrite.conf.j2`` template file in + ``ansible/roles/common/templates/conf/filter`` to deliver log messages to + Elasticsearch. + +* Documentation + + - For OpenStack services there should be an entry in the list + ``OpenStack services`` in the ``README.rst`` file. + + - For infrastructure services there should be an entry in the list + ``Infrastructure components`` in the ``README.rst`` file. + +* Syntax + + - All YAML data files should start with three dashes (``---``). + +Other than the above, most roles follow the following pattern: + + - ``Register``: Involves registering the service with Keystone, creating + endpoints, roles, users, etc. + + - ``Config``: Distributes the config files to the nodes to be pulled into + the container on startup. + + - ``Bootstrap``: Creating the database (but not tables), database user for + the service, permissions, etc. + + - ``Bootstrap Service``: Starts a one shot container on the host to create + the database tables, and other initial run time config. + + - ``Start``: Start the service(s). diff --git a/doc/source/contributor/bug-triage.rst b/doc/source/contributor/bug-triage.rst new file mode 100644 index 000000000..d5d24ca15 --- /dev/null +++ b/doc/source/contributor/bug-triage.rst @@ -0,0 +1,8 @@ +========== +Bug triage +========== + +The triage of Kolla bugs follows the OpenStack-wide process documented +on `BugTriage `_ in the wiki. +Please reference `Bugs `_ in the +wiki for further details. diff --git a/doc/source/contributor/index.rst b/doc/source/contributor/index.rst new file mode 100644 index 000000000..c2d7d4d97 --- /dev/null +++ b/doc/source/contributor/index.rst @@ -0,0 +1,10 @@ +Developer Docs +============== + +.. toctree:: + :maxdepth: 1 + + CONTRIBUTING + vagrant-dev-env + running-tests + bug-triage diff --git a/doc/source/contributor/running-tests.rst b/doc/source/contributor/running-tests.rst new file mode 100644 index 000000000..317f2d948 --- /dev/null +++ b/doc/source/contributor/running-tests.rst @@ -0,0 +1,106 @@ +.. _running-tests: + +============= +Running tests +============= + +Kolla-ansible contains a suit of tests in the ``tests`` directory. + +Any proposed code change in gerrit is automatically rejected by the OpenStack +Jenkins server [#f1]_ if the change causes test failures. + +It is recommended for developers to run the test suite before submitting patch +for review. This allows to catch errors as early as possible. + +Preferred way to run the tests +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The preferred way to run the unit tests is using ``tox``. It executes tests in +isolated environment, by creating separate virtualenv and installing +dependencies from the ``requirements.txt`` and ``test-requirements.txt`` files, +so the only package you install is ``tox`` itself: + +.. code-block:: console + + $ pip install tox + +See `the unit testing section of the Testing wiki page`_ for more information. +Following are some simple examples. + +To run the Python 2.7 tests: + +.. code-block:: console + + $ tox -e py27 + +To run the style tests: + +.. code-block:: console + + $ tox -e pep8 + +To run multiple tests separate items by commas: + +.. code-block:: console + + $ tox -e py27,py34,pep8 + +.. _the unit testing section of the Testing wiki page: https://wiki.openstack.org/wiki/Testing#Unit_Tests + +Running a subset of tests +------------------------- + +Instead of running all tests, you can specify an individual directory, file, +class or method that contains test code, i.e. filter full names of tests by a +string. + +To run the tests located only in the ``kolla-ansible/tests`` +directory use: + +.. code-block:: console + + $ tox -e py27 kolla-ansible.tests + +To run the tests of a specific file +say ``kolla-ansible/tests/test_kolla_docker.py``: + +.. code-block:: console + + $ tox -e py27 test_kolla_docker + +To run the tests in the ``ModuleArgsTest`` class in +the ``kolla-ansible/tests/test_kolla_docker.py`` file: + +.. code-block:: console + + $ tox -e py27 test_kolla_docker.ModuleArgsTest + +To run the ``ModuleArgsTest.test_module_args`` test method in +the ``kolla-ansible/tests/test_kolla_docker.py`` file: + +.. code-block:: console + + $ tox -e py27 test_kolla_docker.ModuleArgsTest.test_module_args + +Debugging unit tests +------------------------ + +In order to break into the debugger from a unit test we need to insert +a breaking point to the code: + +.. code-block:: python + + import pdb; pdb.set_trace() + +Then run ``tox`` with the debug environment as one of the following:: + + tox -e debug + tox -e debug test_file_name.TestClass.test_name + +For more information see the `oslotest documentation +`_. + + +.. rubric:: Footnotes + +.. [#f1] See https://docs.openstack.org/infra/system-config/jjb.html diff --git a/doc/source/contributor/vagrant-dev-env.rst b/doc/source/contributor/vagrant-dev-env.rst new file mode 100644 index 000000000..9c9a0c075 --- /dev/null +++ b/doc/source/contributor/vagrant-dev-env.rst @@ -0,0 +1,190 @@ +.. vagrant-dev-env: + +==================================== +Development Environment with Vagrant +==================================== + +This guide describes how to use `Vagrant `__ to assist in +developing for Kolla. + +Vagrant is a tool to assist in scripted creation of virtual machines. Vagrant +takes care of setting up CentOS-based VMs for Kolla development, each with +proper hardware like memory amount and number of network interfaces. + +Getting Started +=============== + +The Vagrant script implements **all-in-one** or **multi-node** deployments. +**all-in-one** is the default. + +In the case of **multi-node** deployment, the Vagrant setup builds a cluster +with the following nodes by default: + +* 3 control nodes +* 1 compute node +* 1 storage node (Note: ceph requires at least 3 storage nodes) +* 1 network node +* 1 operator node + +The cluster node count can be changed by editing the Vagrantfile. + +Kolla runs from the operator node to deploy OpenStack. + +All nodes are connected with each other on the secondary NIC. The primary NIC +is behind a NAT interface for connecting with the Internet. The third NIC is +connected without IP configuration to a public bridge interface. This may be +used for Neutron/Nova to connect to instances. + +Start by downloading and installing the Vagrant package for the distro of +choice. Various downloads can be found at the `Vagrant downloads +`__. + +Install required dependencies as follows: + +On CentOS:: + + sudo yum install ruby-devel libvirt-devel zlib-devel libpng-devel gcc \ + qemu-kvm qemu-img libvirt libvirt-python libvirt-client virt-install \ + bridge-utils + +On Ubuntu 16.04 or later:: + + sudo apt-get install vagrant ruby-dev ruby-libvirt python-libvirt libvirt-dev nfs-kernel-server zlib1g-dev libpng12-dev gcc git + +.. note:: Many distros ship outdated versions of Vagrant by default. When in + doubt, always install the latest from the downloads page above. + +Next install the hostmanager plugin so all hosts are recorded in ``/etc/hosts`` +(inside each vm):: + + vagrant plugin install vagrant-hostmanager + +If you are going to use VirtualBox, then install vagrant-vbguest:: + + vagrant plugin install vagrant-vbguest + +Vagrant supports a wide range of virtualization technologies. If VirtualBox is +used, the vbguest plugin will be required to install the VirtualBox Guest +Additions in the virtual machine:: + + vagrant plugin install vagrant-vbguest + +This documentation focuses on libvirt specifics. To install vagrant-libvirt +plugin:: + + vagrant plugin install --plugin-version ">= 0.0.31" vagrant-libvirt + +Some Linux distributions offer vagrant-libvirt packages, but the version they +provide tends to be too old to run Kolla. A version of >= 0.0.31 is required. + +To use libvirt from Vagrant with a low privileges user without being asked for +a password, add the user to the libvirt group:: + + sudo gpasswd -a ${USER} libvirt + newgrp libvirt + +Setup NFS to permit file sharing between host and VMs. Contrary to the rsync +method, NFS allows both way synchronization and offers much better performance +than VirtualBox shared folders. On CentOS:: + + # Add the virtual interfaces to the internal zone + sudo firewall-cmd --zone=internal --add-interface=virbr0 + sudo firewall-cmd --zone=internal --add-interface=virbr1 + # Enable nfs, rpc-bind and mountd services for firewalld + sudo firewall-cmd --permanent --zone=internal --add-service=nfs + sudo firewall-cmd --permanent --zone=internal --add-service=rpc-bind + sudo firewall-cmd --permanent --zone=internal --add-service=mountd + sudo firewall-cmd --permanent --zone=internal --add-port=2049/udp + sudo firewall-cmd --permanent --add-port=2049/tcp + sudo firewall-cmd --permanent --add-port=111/udp + sudo firewall-cmd --permanent --add-port=111/tcp + sudo firewall-cmd --reload + # Start required services for NFS + sudo systemctl restart firewalld + sudo systemctl start nfs-server + sudo systemctl start rpcbind.service + +Ensure your system has libvirt and associated software installed and setup +correctly. On CentOS:: + + sudo systemctl start libvirtd + sudo systemctl enable libvirtd + +Find a location in the system's home directory and checkout Kolla repos:: + + git clone https://git.openstack.org/openstack/kolla-ansible + git clone https://git.openstack.org/openstack/kolla + +Both repos must share the same parent directory so the bootstrap code can +locate them. + +Developers can now tweak the Vagrantfile or bring up the default **all-in-one** +CentOS 7-based environment:: + + cd kolla-ansible/contrib/dev/vagrant && vagrant up + +The command ``vagrant status`` provides a quick overview of the VMs composing +the environment. + +Vagrant Up +========== + +Once Vagrant has completed deploying all nodes, the next step is to launch +Kolla. First, connect with the **operator** node:: + + vagrant ssh operator + +To speed things up, there is a local registry running on the operator. All +nodes are configured so they can use this insecure repo to pull from, and use +it as a mirror. Ansible may use this registry to pull images from. + +All nodes have a local folder shared between the group and the hypervisor, and +a folder shared between **all** nodes and the hypervisor. This mapping is lost +after reboots, so make sure to use the command ``vagrant reload `` when +reboots are required. Having this shared folder provides a method to supply +a different Docker binary to the cluster. The shared folder is also used to +store the docker-registry files, so they are save from destructive operations +like ``vagrant destroy``. + +Building images +--------------- + +Once logged on the **operator** VM call the ``kolla-build`` utility:: + + kolla-build + +``kolla-build`` accept arguments as documented in `Building Container Images`_. +It builds Docker images and pushes them to the local registry if the **push** +option is enabled (in Vagrant this is the default behaviour). + +Deploying OpenStack with Kolla +------------------------------ + +Deploy **all-in-one** with:: + + sudo kolla-ansible deploy + +Deploy multinode +On Centos 7:: + + sudo kolla-ansible deploy -i /usr/share/kolla-ansible/ansible/inventory/multinode + +On Ubuntu 16.04 or later:: + + sudo kolla-ansible deploy -i /usr/local/share/kolla-ansible/ansible/inventory/multinode + +Validate OpenStack is operational:: + + kolla-ansible post-deploy + . /etc/kolla/admin-openrc.sh + openstack user list + +Or navigate to http://172.28.128.254/ with a web browser. + +Further Reading +=============== + +All Vagrant documentation can be found at +`docs.vagrantup.com `__. + +.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/source/index.rst b/doc/source/index.rst new file mode 100644 index 000000000..c7c33fa52 --- /dev/null +++ b/doc/source/index.rst @@ -0,0 +1,59 @@ +.. + Copyright 2014-2015 OpenStack Foundation + All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); you may + not use this file except in compliance with the License. You may obtain + a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + License for the specific language governing permissions and limitations + under the License. + +========================================= +Welcome to Kolla-Ansible's documentation! +========================================= + +Kolla's Mission +=============== + +Kolla's mission is to provide production-ready containers and deployment tools +for operating OpenStack clouds. + +Kolla-Ansible is highly opinionated out of the box, but allows for complete +customization. This permits operators with minimal experience to deploy +OpenStack quickly and as experience grows modify the OpenStack configuration to +suit the operator's exact requirements. + +For information on building container images for use with Kolla-Ansible, please +refer to the `Kolla image documentation +`_. + + +User Guides +=========== + +.. toctree:: + :maxdepth: 2 + + user/index + +Reference +========= + +.. toctree:: + :maxdepth: 2 + + reference/index + +Developer Docs +============== + +.. toctree:: + :maxdepth: 2 + + contributor/index diff --git a/doc/source/reference/bifrost.rst b/doc/source/reference/bifrost.rst new file mode 100644 index 000000000..592ed093b --- /dev/null +++ b/doc/source/reference/bifrost.rst @@ -0,0 +1,475 @@ +============= +Bifrost Guide +============= + +From the bifrost developer documentation: + + Bifrost (pronounced bye-frost) is a set of Ansible playbooks that automates + the task of deploying a base image onto a set of known hardware using + Ironic. It provides modular utility for one-off operating system + deployment with as few operational requirements as reasonably possible. + +Kolla uses bifrost as a mechanism for bootstrapping an OpenStack control plane +on a set of baremetal servers. Kolla provides a container image for bifrost. +Kolla-ansible provides a playbook to configure and deploy the bifrost +container, as well as building a base OS image and provisioning it onto the +baremetal nodes. + +Hosts in the System +=================== + +In a system deployed by bifrost we define a number of classes of hosts. + +Control host + The control host is the host on which kolla and kolla-ansible will be + installed, and is typically where the cloud will be managed from. +Deployment host + The deployment host runs the bifrost deploy container and is used to + provision the cloud hosts. +Cloud hosts + The cloud hosts run the OpenStack control plane, compute and storage + services. +Bare metal compute hosts: + In a cloud providing bare metal compute services to tenants via Ironic, + these hosts will run the bare metal tenant workloads. In a cloud with only + virtualised compute this category of hosts does not exist. + +.. note:: + + In many cases the control and deployment host will be the same, although + this is not mandatory. + +.. note:: + + Bifrost supports provisioning of bare metal nodes. While kolla-ansible is + agnostic to whether the host OS runs on bare metal or is virtualised, in a + virtual environment the provisioning of VMs for cloud hosts and their base + OS images is currently out of scope. + +Cloud Deployment Procedure +========================== + +Cloud deployment using kolla and bifrost follows the following high level +steps: + +#. Install and configure kolla and kolla-ansible on the control host. +#. Deploy bifrost on the deployment host. +#. Use bifrost to build a base OS image and provision cloud hosts with this + image. +#. Deploy OpenStack services on the cloud hosts provisioned by bifrost. + +Preparation +=========== + +Prepare the Control Host +------------------------ + +Follow the **Install dependencies** section of the :doc:`../user/quickstart` +guide instructions to set up kolla and kolla-ansible dependencies. Follow +the instructions in either the **Install kolla for development** section or +the **Install kolla for deployment or evaluation** section to install kolla +and kolla-ansible. + +Prepare the Deployment Host +--------------------------- + +RabbitMQ requires that the system's hostname resolves to the IP address that it +has been configured to use, which with bifrost will be ``127.0.0.1``. Bifrost +will attempt to modify ``/etc/hosts`` on the deployment host to ensure that +this is the case. Docker bind mounts ``/etc/hosts`` into the container from a +volume. This prevents atomic renames which will prevent Ansible from fixing +the +``/etc/hosts`` file automatically. + +To enable bifrost to be bootstrapped correctly add an entry to ``/etc/hosts`` +resolving the deployment host's hostname to ``127.0.0.1``, for example:: + + ubuntu@bifrost:/repo/kolla$ cat /etc/hosts + 127.0.0.1 bifrost localhost + + # The following lines are desirable for IPv6 capable hosts + ::1 ip6-localhost ip6-loopback + fe00::0 ip6-localnet + ff00::0 ip6-mcastprefix + ff02::1 ip6-allnodes + ff02::2 ip6-allrouters + ff02::3 ip6-allhosts + 192.168.100.15 bifrost + +Build a Bifrost Container Image +=============================== + +This section provides instructions on how to build a container image for +bifrost using kolla. + +Enable Source Build Type +------------------------ + +Currently kolla only supports the source install type for the bifrost image. + +Configuration File +~~~~~~~~~~~~~~~~~~ + +If required, generate a default configuration file for ``kolla-build``:: + + cd kolla + tox -e genconfig + +Modify ``kolla-build.conf``, setting ``install_type`` to ``source``:: + + install_type = source + +Command line +~~~~~~~~~~~~ + +Alternatively, instead of using ``kolla-build.conf``, a source build can be +enabled by appending ``--type source`` to the ``kolla-build`` or +``tools/build.py`` command. + +Build Container +--------------- + +Development +~~~~~~~~~~~ + +:: + + cd kolla + tools/build.py bifrost-deploy + +Production +~~~~~~~~~~ + +:: + + kolla-build bifrost-deploy + +.. note:: + + By default kolla-build will build all containers using CentOS as the base + image. To change this behavior, use the following parameter with + ``kolla-build`` or ``tools/build.py`` command:: + + --base [ubuntu|centos|oraclelinux] + +Configure and Deploy a Bifrost Container +======================================== + +This section provides instructions for how to configure and deploy a container +running bifrost services. + +Prepare Kolla-Ansible Inventory +------------------------------- + +Kolla-ansible will deploy bifrost on the hosts in the ``bifrost`` Ansible +group. In the ``all-in-one`` and ``multinode`` inventory files, a ``bifrost`` +group is defined which contains all hosts in the ``deployment`` group. This +top level ``deployment`` group is intended to represent the host running the +``bifrost_deploy`` container. By default, this group contains ``localhost``. +See `Multinode Deployment of Kolla `_ +for details on how to modify the Ansible inventory in a multinode deployment. + +Bifrost does not currently support running on multiple hosts so the ``bifrost`` +group should contain only a single host, however this is not enforced by +kolla-ansible. Bifrost manages a number of services that conflict with +services deployed by kolla including OpenStack Ironic, MariaDB, RabbitMQ and +(optionally) OpenStack Keystone. These services should not be deployed on the +host on which bifrost is deployed. + +Prepare Kolla-Ansible Configuration +----------------------------------- + +Follow the instructions in :doc:`../user/quickstart` to prepare kolla-ansible's +global configuration file ``globals.yml``. For bifrost, the +``bifrost_network_interface`` variable should be set to the name of the +interface that will be used to provision bare metal cloud hosts if this is +different than ``network_interface``. For example to use ``eth1``: + +.. code-block:: yaml + + bifrost_network_interface: eth1 + +Note that this interface should typically have L2 network connectivity with the +bare metal cloud hosts in order to provide DHCP leases with PXE boot options. + +Since bifrost only supports the source image type, ensure that this is +reflected in ``globals.yml`` + +.. code-block:: yaml + + kolla_install_type: source + +Prepare Bifrost Configuration +----------------------------- + +Kolla ansible custom configuration files can be placed in a directory given by +the ``node_custom_config`` variable, which defaults do ``/etc/kolla/config``. +Bifrost configuration files should be placed in this directory or in a +``bifrost`` subdirectory of it (e.g. ``/etc/kolla/config/bifrost``). Within +these directories the files ``bifrost.yml``, ``servers.yml`` and ``dib.yml`` +can be used to configure Bifrost. + +Create a Bifrost Inventory +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The file ``servers.yml`` defines the bifrost hardware inventory that will be +used to populate Ironic. See the `bifrost dynamic inventory examples +`_ for +further details. + +For example, the following inventory defines a single node managed via the +Ironic ``agent_ipmitool`` driver. The inventory contains credentials required +to access the node's BMC via IPMI, the MAC addresses of the node's NICs, an IP +address to configure the node's configdrive with, a set of scheduling +properties and a logical name. + +.. code-block:: yaml + + --- + cloud1: + uuid: "31303735-3934-4247-3830-333132535336" + driver_info: + power: + ipmi_username: "admin" + ipmi_address: "192.168.1.30" + ipmi_password: "root" + nics: + - + mac: "1c:c1:de:1c:aa:53" + - + mac: "1c:c1:de:1c:aa:52" + driver: "agent_ipmitool" + ipv4_address: "192.168.1.10" + properties: + cpu_arch: "x86_64" + ram: "24576" + disk_size: "120" + cpus: "16" + name: "cloud1" + +The required inventory will be specific to the hardware and environment in use. + +Create Bifrost Configuration +~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The file ``bifrost.yml`` provides global configuration for the bifrost +playbooks. By default kolla mostly uses bifrost's default variable values. +For details on bifrost's variables see the bifrost documentation. + +For example: + +.. code-block:: yaml + + mysql_service_name: mysql + ansible_python_interpreter: /var/lib/kolla/venv/bin/python + enabled_drivers: agent_ipmitool,agent_ipminative + # uncomment below if needed + # dhcp_pool_start: 192.168.2.200 + # dhcp_pool_end: 192.168.2.250 + # dhcp_lease_time: 12h + # dhcp_static_mask: 255.255.255.0 + +Create Disk Image Builder Configuration +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The file ``dib.yml`` provides configuration for bifrost's image build +playbooks. By default kolla mostly uses bifrost's default variable values when +building the baremetal OS and deployment images, and will build an +**Ubuntu-based** image for deployment to nodes. For details on bifrost's +variables see the bifrost documentation. + +For example to use the ``debian`` Disk Image Builder OS element: + +.. code-block:: yaml + + dib_os_element: debian + +See the `diskimage-builder documentation +`__ for more details. + +Deploy Bifrost +-------------- + +The bifrost container can be deployed either using kolla-ansible or manually. + +Kolla-Ansible +~~~~~~~~~~~~~ + +Development +___________ + +:: + + cd kolla-ansible + tools/kolla-ansible deploy-bifrost + +Production +__________ + +:: + + kolla-ansible deploy-bifrost + +Manual +~~~~~~ + +Start Bifrost Container +_______________________ + +:: + + docker run -it --net=host -v /dev:/dev -d \ + --privileged --name bifrost_deploy \ + kolla/ubuntu-source-bifrost-deploy:3.0.1 + +Copy Configuration Files +________________________ + +.. code-block:: console + + docker exec -it bifrost_deploy mkdir /etc/bifrost + docker cp /etc/kolla/config/bifrost/servers.yml bifrost_deploy:/etc/bifrost/servers.yml + docker cp /etc/kolla/config/bifrost/bifrost.yml bifrost_deploy:/etc/bifrost/bifrost.yml + docker cp /etc/kolla/config/bifrost/dib.yml bifrost_deploy:/etc/bifrost/dib.yml + +Bootstrap Bifrost +_________________ + +:: + + docker exec -it bifrost_deploy bash + +Generate an SSH Key +___________________ + +:: + + ssh-keygen + +Bootstrap and Start Services +____________________________ + +.. code-block:: console + + cd /bifrost + ./scripts/env-setup.sh + . env-vars + cat > /etc/rabbitmq/rabbitmq-env.conf << EOF + HOME=/var/lib/rabbitmq + EOF + ansible-playbook -vvvv \ + -i /bifrost/playbooks/inventory/target \ + /bifrost/playbooks/install.yaml \ + -e @/etc/bifrost/bifrost.yml \ + -e @/etc/bifrost/dib.yml \ + -e skip_package_install=true + +Validate the Deployed Container +=============================== + +.. code-block:: console + + docker exec -it bifrost_deploy bash + cd /bifrost + . env-vars + +Running "ironic node-list" should return with no nodes, for example + +.. code-block:: console + + (bifrost-deploy)[root@bifrost bifrost]# ironic node-list + +------+------+---------------+-------------+--------------------+-------------+ + | UUID | Name | Instance UUID | Power State | Provisioning State | Maintenance | + +------+------+---------------+-------------+--------------------+-------------+ + +------+------+---------------+-------------+--------------------+-------------+ + +Enroll and Deploy Physical Nodes +================================ + +Once we have deployed a bifrost container we can use it to provision the bare +metal cloud hosts specified in the inventory file. Again, this can be done +either using kolla-ansible or manually. + +Kolla-Ansible +------------- + +Development +~~~~~~~~~~~ + +:: + + tools/kolla-ansible deploy-servers + +Production +~~~~~~~~~~ + +:: + + kolla-ansible deploy-servers + +Manual +------ + +.. code-block:: console + + docker exec -it bifrost_deploy bash + cd /bifrost + . env-vars + export BIFROST_INVENTORY_SOURCE=/etc/bifrost/servers.yml + ansible-playbook -vvvv \ + -i /bifrost/playbooks/inventory/bifrost_inventory.py \ + /bifrost/playbooks/enroll-dynamic.yaml \ + -e "ansible_python_interpreter=/var/lib/kolla/venv/bin/python" \ + -e @/etc/bifrost/bifrost.yml + + docker exec -it bifrost_deploy bash + cd /bifrost + . env-vars + export BIFROST_INVENTORY_SOURCE=/etc/bifrost/servers.yml + ansible-playbook -vvvv \ + -i /bifrost/playbooks/inventory/bifrost_inventory.py \ + /bifrost/playbooks/deploy-dynamic.yaml \ + -e "ansible_python_interpreter=/var/lib/kolla/venv/bin/python" \ + -e @/etc/bifrost/bifrost.yml + +At this point Ironic should clean down the nodes and install the default +OS image. + +Advanced Configuration +====================== + +Bring Your Own Image +-------------------- + +TODO + +Bring Your Own SSH Key +---------------------- + +To use your own SSH key after you have generated the ``passwords.yml`` file +update the private and public keys under ``bifrost_ssh_key``. + +Known issues +============ + +SSH daemon not running +---------------------- + +By default ``sshd`` is installed in the image but may not be enabled. If you +encounter this issue you will have to access the server physically in recovery +mode to enable the ``sshd`` service. If your hardware supports it, this can be +done remotely with ``ipmitool`` and Serial Over LAN. For example + +.. code-block:: console + + ipmitool -I lanplus -H 192.168.1.30 -U admin -P root sol activate + +References +========== + +Bifrost documentation: https://docs.openstack.org/bifrost/latest/ + +Bifrost troubleshooting guide: https://docs.openstack.org/bifrost/latest/troubleshooting.html + +Bifrost code repository: https://github.com/openstack/bifrost + diff --git a/doc/source/reference/central-logging-guide.rst b/doc/source/reference/central-logging-guide.rst new file mode 100644 index 000000000..938b8b137 --- /dev/null +++ b/doc/source/reference/central-logging-guide.rst @@ -0,0 +1,156 @@ +.. _central-logging-guide: + +======================== +Central Logging in Kolla +======================== + +An OpenStack deployment generates vast amounts of log data. In order to +successfully monitor this and use it to diagnose problems, the standard "ssh +and grep" solution quickly becomes unmanageable. + +Preparation and deployment +========================== + +Modify the configuration file ``/etc/kolla/globals.yml`` and change +the following: + +:: + + enable_central_logging: "yes" + +Elasticsearch +============= + +Kolla deploys Elasticsearch as part of the E*K stack to store, organize +and make logs easily accessible. + +By default Elasticsearch is deployed on port ``9200``. + +.. note:: + + Elasticsearch stores a lot of logs, so if you are running centralized logging, + remember to give ``/var/lib/docker`` an adequate space. + + +Kibana +====== + +Kolla deploys Kibana as part of the E*K stack in order to allow operators to +search and visualise logs in a centralised manner. + +After successful deployment, Kibana can be accessed using a browser on +``:5601``. + +The default username is ``kibana``, the password can be located under +```` in ``/etc/kolla/passwords.yml``. + +Search logs - Discover tab +-------------------------- + +Operators can create and store searches based on various fields from logs, for +example, "show all logs marked with ERROR on nova-compute". + +To do this, click the ``Discover`` tab. Fields from the logs can be filtered by +hovering over entries from the left hand side, and clicking ``add`` or +``remove``. Add the following fields: + +* Hostname +* Payload +* severity_label +* programname + +This yields an easy to read list of all log events from each node in the +deployment within the last 15 minutes. A "tail like" functionality can be +achieved by clicking the clock icon in the top right hand corner of the screen, +and selecting ``Auto-refresh``. + +Logs can also be filtered down further. To use the above example, type +``programname:nova-compute`` in the search bar. Click the drop-down arrow from +one of the results, then the small magnifying glass icon from beside the +programname field. This should now show a list of all events from nova-compute +services across the cluster. + +The current search can also be saved by clicking the ``Save Search`` icon +available from the menu on the right hand side. + +Example: using Kibana to diagnose a common failure +-------------------------------------------------- + +The following example demonstrates how Kibana can be used to diagnose a common +OpenStack problem, where an instance fails to launch with the error 'No valid +host was found'. + +First, re-run the server creation with ``--debug``: + +:: + + openstack --debug server create --image cirros --flavor m1.tiny \ + --key-name mykey --nic net-id=00af016f-dffe-4e3c-a9b8-ec52ccd8ea65 \ + demo1 + +In this output, look for the key ``X-Compute-Request-Id``. This is a unique +identifier that can be used to track the request through the system. An +example ID looks like this: + +:: + + X-Compute-Request-Id: req-c076b50a-6a22-48bf-8810-b9f41176a6d5 + +Taking the value of ``X-Compute-Request-Id``, enter the value into the Kibana +search bar, minus the leading ``req-``. Assuming some basic filters have been +added as shown in the previous section, Kibana should now show the path this +request made through the OpenStack deployment, starting at a ``nova-api`` on +a control node, through the ``nova-scheduler``, ``nova-conductor``, and finally +``nova-compute``. Inspecting the ``Payload`` of the entries marked ``ERROR`` +should quickly lead to the source of the problem. + +While some knowledge is still required of how Nova works in this instance, it +can still be seen how Kibana helps in tracing this data, particularly in a +large scale deployment scenario. + +Visualize data - Visualize tab +------------------------------ + +In the visualization tab a wide range of charts is available. If any +visualization has not been saved yet, after choosing this tab *Create a new +visualization* panel is opened. If a visualization has already been saved, +after choosing this tab, lately modified visualization is opened. In this +case, one can create a new visualization by choosing *add visualization* +option in the menu on the right. In order to create new visualization, one +of the available options has to be chosen (pie chart, area chart). Each +visualization can be created from a saved or a new search. After choosing +any kind of search, a design panel is opened. In this panel, a chart can be +generated and previewed. In the menu on the left, metrics for a chart can +be chosen. The chart can be generated by pressing a green arrow on the top +of the left-side menu. + +.. note:: After creating a visualization, it can be saved by choosing *save + visualization* option in the menu on the right. If it is not saved, it + will be lost after leaving a page or creating another visualization. + +Organize visualizations and searches - Dashboard tab +---------------------------------------------------- + +In the Dashboard tab all of saved visualizations and searches can be +organized in one Dashboard. To add visualization or search, one can choose +*add visualization* option in the menu on the right and then choose an item +from all saved ones. The order and size of elements can be changed directly +in this place by moving them or resizing. The color of charts can also be +changed by checking a colorful dots on the legend near each visualization. + +.. note:: After creating a dashboard, it can be saved by choosing *save dashboard* + option in the menu on the right. If it is not saved, it will be lost after + leaving a page or creating another dashboard. + +If a Dashboard has already been saved, it can be opened by choosing *open +dashboard* option in the menu on the right. + +Exporting and importing created items - Settings tab +---------------------------------------------------- + +Once visualizations, searches or dashboards are created, they can be exported +to a JSON format by choosing Settings tab and then Objects tab. Each of the +item can be exported separately by selecting it in the menu. All of the items +can also be exported at once by choosing *export everything* option. +In the same tab (Settings - Objects) one can also import saved items by +choosing *import* option. diff --git a/doc/source/reference/ceph-guide.rst b/doc/source/reference/ceph-guide.rst new file mode 100644 index 000000000..61e2f7b1c --- /dev/null +++ b/doc/source/reference/ceph-guide.rst @@ -0,0 +1,360 @@ +.. _ceph-guide: + +============= +Ceph in Kolla +============= + +The out-of-the-box Ceph deployment requires 3 hosts with at least one block +device on each host that can be dedicated for sole use by Ceph. However, with +tweaks to the Ceph cluster you can deploy a **healthy** cluster with a single +host and a single block device. + +Requirements +============ + +* A minimum of 3 hosts for a vanilla deploy +* A minimum of 1 block device per host + +Preparation +=========== + +To prepare a disk for use as a +`Ceph OSD `_ you must add a +special partition label to the disk. This partition label is how Kolla detects +the disks to format and bootstrap. Any disk with a matching partition label +will be reformatted so use caution. + +To prepare an OSD as a storage drive, execute the following operations: + +:: + + # + # where $DISK is /dev/sdb or something similar + parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 + +The following shows an example of using parted to configure ``/dev/sdb`` for +usage with Kolla. + +:: + + parted /dev/sdb -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 + parted /dev/sdb print + Model: VMware, VMware Virtual S (scsi) + Disk /dev/sdb: 10.7GB + Sector size (logical/physical): 512B/512B + Partition Table: gpt + Number Start End Size File system Name Flags + 1 1049kB 10.7GB 10.7GB KOLLA_CEPH_OSD_BOOTSTRAP + + +Using an external journal drive +------------------------------- + +The steps documented above created a journal partition of 5 GByte +and a data partition with the remaining storage capacity on the same tagged +drive. + +It is a common practice to place the journal of an OSD on a separate +journal drive. This section documents how to use an external journal drive. + +Prepare the storage drive in the same way as documented above: + +:: + + # + # where $DISK is /dev/sdb or something similar + parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_FOO 1 -1 + +To prepare the journal external drive execute the following command: + +:: + + # + # where $DISK is /dev/sdc or something similar + parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP_FOO_J 1 -1 + +.. note:: + + Use different suffixes (``_42``, ``_FOO``, ``_FOO42``, ..) to use different external + journal drives for different storage drives. One external journal drive can only + be used for one storage drive. + +.. note:: + + The partition labels ``KOLLA_CEPH_OSD_BOOTSTRAP`` and ``KOLLA_CEPH_OSD_BOOTSTRAP_J`` + are not working when using external journal drives. It is required to use + suffixes (``_42``, ``_FOO``, ``_FOO42``, ..). If you want to setup only one + storage drive with one external journal drive it is also necessary to use a suffix. + + +Configuration +============= + +Edit the [storage] group in the inventory which contains the hostname of the +hosts that have the block devices you have prepped as shown above. + +:: + + [storage] + controller + compute1 + + +Enable Ceph in ``/etc/kolla/globals.yml``: + +:: + + enable_ceph: "yes" + + +RadosGW is optional, enable it in ``/etc/kolla/globals.yml``: + +:: + + enable_ceph_rgw: "yes" + +RGW requires a healthy cluster in order to be successfully deployed. On initial +start up, RGW will create several pools. The first pool should be in an +operational state to proceed with the second one, and so on. So, in the case of +an **all-in-one** deployment, it is necessary to change the default number of +copies for the pools before deployment. Modify the file +``/etc/kolla/config/ceph.conf`` and add the contents:: + + [global] + osd pool default size = 1 + osd pool default min size = 1 + + +Deployment +========== + +Finally deploy the Ceph-enabled OpenStack: + +:: + + kolla-ansible deploy -i path/to/inventory + +Using a Cache Tier +================== + +An optional `cache tier `_ +can be deployed by formatting at least one cache device and enabling cache. +tiering in the globals.yml configuration file. + +To prepare an OSD as a cache device, execute the following operations: + +:: + + # + # where $DISK is /dev/sdb or something similar + parted $DISK -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_CACHE_BOOTSTRAP 1 -1 + +Enable the Ceph cache tier in ``/etc/kolla/globals.yml``: + +:: + + enable_ceph: "yes" + ceph_enable_cache: "yes" + # Valid options are [ forward, none, writeback ] + ceph_cache_mode: "writeback" + +After this run the playbooks as you normally would. For example: + +:: + + kolla-ansible deploy -i path/to/inventory + +Setting up an Erasure Coded Pool +================================ + +`Erasure code `_ +is the new big thing from Ceph. Kolla has the ability to setup your Ceph pools +as erasure coded pools. Due to technical limitations with Ceph, using erasure +coded pools as OpenStack uses them requires a cache tier. Additionally, you +must make the choice to use an erasure coded pool or a replicated pool +(the default) when you initially deploy. You cannot change this without +completely removing the pool and recreating it. + +To enable erasure coded pools add the following options to your +``/etc/kolla/globals.yml`` configuration file: + +:: + + # A requirement for using the erasure-coded pools is you must setup a cache tier + # Valid options are [ erasure, replicated ] + ceph_pool_type: "erasure" + # Optionally, you can change the profile + #ceph_erasure_profile: "k=4 m=2 ruleset-failure-domain=host" + +Managing Ceph +============= + +Check the Ceph status for more diagnostic information. The sample output below +indicates a healthy cluster: + +:: + + docker exec ceph_mon ceph -s + cluster 5fba2fbc-551d-11e5-a8ce-01ef4c5cf93c + health HEALTH_OK + monmap e1: 1 mons at {controller=10.0.0.128:6789/0} + election epoch 2, quorum 0 controller + osdmap e18: 2 osds: 2 up, 2 in + pgmap v27: 64 pgs, 1 pools, 0 bytes data, 0 objects + 68676 kB used, 20390 MB / 20457 MB avail + 64 active+clean + +If Ceph is run in an **all-in-one** deployment or with less than three storage +nodes, further configuration is required. It is necessary to change the default +number of copies for the pool. The following example demonstrates how to change +the number of copies for the pool to 1: + +:: + + docker exec ceph_mon ceph osd pool set rbd size 1 + +All the pools must be modified if Glance, Nova, and Cinder have been deployed. +An example of modifying the pools to have 2 copies: + +:: + + for p in images vms volumes backups; do docker exec ceph_mon ceph osd pool set ${p} size 2; done + +If using a cache tier, these changes must be made as well: + +:: + + for p in images vms volumes backups; do docker exec ceph_mon ceph osd pool set ${p}-cache size 2; done + +The default pool Ceph creates is named **rbd**. It is safe to remove this pool: + +:: + + docker exec ceph_mon ceph osd pool delete rbd rbd --yes-i-really-really-mean-it + +Troubleshooting +=============== + +Deploy fails with 'Fetching Ceph keyrings ... No JSON object could be decoded' +------------------------------------------------------------------------------ + +If an initial deploy of Ceph fails, perhaps due to improper configuration or +similar, the cluster will be partially formed and will need to be reset for a +successful deploy. + +In order to do this the operator should remove the `ceph_mon_config` volume +from each Ceph monitor node: + +:: + + ansible \ + -i ansible/inventory/multinode \ + -a 'docker volume rm ceph_mon_config' \ + ceph-mon + +===================== +Simple 3 Node Example +===================== + +This example will show how to deploy Ceph in a very simple setup using 3 +storage nodes. 2 of those nodes (kolla1 and kolla2) will also provide other +services like control, network, compute, and monitoring. The 3rd +(kolla3) node will only act as a storage node. + +This example will only focus on the Ceph aspect of the deployment and assumes +that you can already deploy a fully functional environment using 2 nodes that +does not employ Ceph yet. So we will be adding to the existing multinode +inventory file you already have. + +Each of the 3 nodes are assumed to have two disk, ``/dev/sda`` (40GB) +and ``/dev/sdb`` (10GB). Size is not all that important... but for now make +sure each sdb disk are of the same size and are at least 10GB. This example +will use a single disk (/dev/sdb) for both Ceph data and journal. It will not +implement caching. + +Here is the top part of the multinode inventory file used in the example +environment before adding the 3rd node for Ceph: + +:: + + [control] + # These hostname must be resolvable from your deployment host + kolla1.ducourrier.com + kolla2.ducourrier.com + + [network] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [compute] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [monitoring] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [storage] + kolla1.ducourrier.com + kolla2.ducourrier.com + + + +Configuration +============= + +To prepare the 2nd disk (/dev/sdb) of each nodes for use by Ceph you will need +to add a partition label to it as shown below: + +:: + + # + parted /dev/sdb -s -- mklabel gpt mkpart KOLLA_CEPH_OSD_BOOTSTRAP 1 -1 + +Make sure to run this command on each of the 3 nodes or the deployment will +fail. + +Next, edit the multinode inventory file and make sure the 3 nodes are listed +under [storage]. In this example I will add kolla3.ducourrier.com to the +existing inventory file: + +:: + + [control] + # These hostname must be resolvable from your deployment host + kolla1.ducourrier.com + kolla2.ducourrier.com + + [network] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [compute] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [monitoring] + kolla1.ducourrier.com + kolla2.ducourrier.com + + [storage] + kolla1.ducourrier.com + kolla2.ducourrier.com + kolla3.ducourrier.com + +It is now time to enable Ceph in the environment by editing the +``/etc/kolla/globals.yml`` file: + +:: + + enable_ceph: "yes" + enable_ceph_rgw: "yes" + enable_cinder: "yes" + glance_backend_file: "no" + glance_backend_ceph: "yes" + +Finally deploy the Ceph-enabled configuration: + +:: + + kolla-ansible deploy -i path/to/inventory-file diff --git a/doc/source/reference/cinder-guide-hnas.rst b/doc/source/reference/cinder-guide-hnas.rst new file mode 100644 index 000000000..c064e3c05 --- /dev/null +++ b/doc/source/reference/cinder-guide-hnas.rst @@ -0,0 +1,231 @@ +.. _cinder-guide-hnas: + +======================================================== +Hitachi NAS Platform iSCSI and NFS drives for OpenStack +======================================================== + +Overview +======== +The Block Storage service provides persistent block storage resources that +Compute instances can consume. This includes secondary attached storage similar +to the Amazon Elastic Block Storage (EBS) offering. In addition, you can write +images to a Block Storage device for Compute to use as a bootable persistent +instance. + +Requirements +------------ +- Hitachi NAS Platform Models 3080, 3090, 4040, 4060, 4080, and 4100. + +- HNAS/SMU software version is 12.2 or higher. + +- HNAS configuration and management utilities to create a storage pool (span) + and an EVS. + + - GUI (SMU). + + - SSC CLI. + +- You must set an iSCSI domain to EVS + +Supported shared file systems and operations +-------------------------------------------- + +The NFS and iSCSI drivers support these operations: + +- Create, delete, attach, and detach volumes. + +- Create, list, and delete volume snapshots. + +- Create a volume from a snapshot. + +- Copy an image to a volume. + +- Copy a volume to an image. + +- Clone a volume. + +- Extend a volume. + +- Get volume statistics. + +- Manage and unmanage a volume. + +- Manage and unmanage snapshots (HNAS NFS only). + +Configuration example for Hitachi NAS Platform iSCSI and NFS +============================================================ + +iSCSI backend +------------- + +Enable cinder hnas backend iscsi in ``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_cinder_backend_hnas_iscsi: "yes" + +Create or modify the file ``/etc/kolla/config/cinder.conf`` and add the +contents: + +.. code-block:: console + + [DEFAULT] + enabled_backends = hnas-iscsi + + [hnas-iscsi] + volume_driver = cinder.volume.drivers.hitachi.hnas_iscsi.HNASISCSIDriver + volume_iscsi_backend = hnas_iscsi_backend + hnas_iscsi_username = supervisor + hnas_iscsi_password = supervisor + hnas_iscsi_mgmt_ip0 = + hnas_chap_enabled = True + + hnas_iscsi_svc0_volume_type = iscsi_gold + hnas_iscsi_svc0_hdp = FS-Baremetal1 + hnas_iscsi_svc0_iscsi_ip = + +NFS backend +----------- + +Enable cinder hnas backend nfs in ``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_cinder_backend_hnas_nfs: "yes" + +Create or modify the file ``/etc/kolla/config/cinder.conf`` and +add the contents: + +.. code-block:: console + + [DEFAULT] + enabled_backends = hnas-nfs + + [hnas-nfs] + volume_driver = cinder.volume.drivers.hitachi.hnas_nfs.HNASNFSDriver + volume_nfs_backend = hnas_nfs_backend + hnas_nfs_username = supervisor + hnas_nfs_password = supervisor + hnas_nfs_mgmt_ip0 = + hnas_chap_enabled = True + + hnas_nfs_svc0_volume_type = nfs_gold + hnas_nfs_svc0_hdp = / + +Configuration on Kolla deployment +--------------------------------- + +Enable Shared File Systems service and HNAS driver in +``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_cinder: "yes" + +Configuration on HNAS +--------------------- + +Create the data HNAS network in Kolla OpenStack: + +List the available tenants: + +.. code-block:: console + + $ openstack project list + +Create a network to the given tenant (service), providing the tenant ID, +a name for the network, the name of the physical network over which the +virtual network is implemented, and the type of the physical mechanism by +which the virtual network is implemented: + +.. code-block:: console + + $ neutron net-create --tenant-id hnas_network \ + --provider:physical_network=physnet2 --provider:network_type=flat + +Create a subnet to the same tenant (service), the gateway IP of this subnet, +a name for the subnet, the network ID created before, and the CIDR of +subnet: + +.. code-block:: console + + $ neutron subnet-create --tenant-id --gateway \ + --name hnas_subnet + +Add the subnet interface to a router, providing the router ID and subnet +ID created before: + +.. code-block:: console + + $ neutron router-interface-add + +Create volume +============= + +Create a non-bootable volume. + +.. code-block:: console + + $ openstack volume create --size 1 my-volume + +Verify Operation. + +.. code-block:: console + + $ cinder show my-volume + + +--------------------------------+--------------------------------------+ + | Property | Value | + +--------------------------------+--------------------------------------+ + | attachments | [] | + | availability_zone | nova | + | bootable | false | + | consistencygroup_id | None | + | created_at | 2017-01-17T19:02:45.000000 | + | description | None | + | encrypted | False | + | id | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | + | metadata | {} | + | migration_status | None | + | multiattach | False | + | name | my-volume | + | os-vol-host-attr:host | compute@hnas-iscsi#iscsi_gold | + | os-vol-mig-status-attr:migstat | None | + | os-vol-mig-status-attr:name_id | None | + | os-vol-tenant-attr:tenant_id | 16def9176bc64bd283d419ac2651e299 | + | replication_status | disabled | + | size | 1 | + | snapshot_id | None | + | source_volid | None | + | status | available | + | updated_at | 2017-01-17T19:02:46.000000 | + | user_id | fb318b96929c41c6949360c4ccdbf8c0 | + | volume_type | None | + +--------------------------------+--------------------------------------+ + + $ nova volume-attach INSTANCE_ID VOLUME_ID auto + + +----------+--------------------------------------+ + | Property | Value | + +----------+--------------------------------------+ + | device | /dev/vdc | + | id | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | + | serverId | 3bf5e176-be05-4634-8cbd-e5fe491f5f9c | + | volumeId | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | + +----------+--------------------------------------+ + + $ openstack volume list + + +--------------------------------------+---------------+----------------+------+-------------------------------------------+ + | ID | Display Name | Status | Size | Attached to | + +--------------------------------------+---------------+----------------+------+-------------------------------------------+ + | 4f5b8ae8-9781-411e-8ced-de616ae64cfd | my-volume | in-use | 1 | Attached to private-instance on /dev/vdb | + +--------------------------------------+---------------+----------------+------+-------------------------------------------+ + +For more information about how to manage volumes, see the +`OpenStack User Guide +`__. + +For more information about how HNAS driver works, see +`Hitachi NAS Platform iSCSI and NFS drives for OpenStack +`__. diff --git a/doc/source/reference/cinder-guide.rst b/doc/source/reference/cinder-guide.rst new file mode 100644 index 000000000..937e99ac8 --- /dev/null +++ b/doc/source/reference/cinder-guide.rst @@ -0,0 +1,166 @@ +.. _cinder-guide: + +=============== +Cinder in Kolla +=============== + +Overview +======== + +Cinder can be deploying using Kolla and supports the following storage +backends: + +* ceph +* hnas_iscsi +* hnas_nfs +* iscsi +* lvm +* nfs + +LVM +=== + +When using the ``lvm`` backend, a volume group will need to be created on each +storage node. This can either be a real physical volume or a loopback mounted +file for development. Use ``pvcreate`` and ``vgcreate`` to create the volume +group. For example with the devices ``/dev/sdb`` and ``/dev/sdc``: + +:: + + + + pvcreate /dev/sdb /dev/sdc + vgcreate cinder-volumes /dev/sdb /dev/sdc + +During development, it may be desirable to use file backed block storage. It +is possible to use a file and mount it as a block device via the loopback +system. :: + + + free_device=$(losetup -f) + fallocate -l 20G /var/lib/cinder_data.img + losetup $free_device /var/lib/cinder_data.img + pvcreate $free_device + vgcreate cinder-volumes $free_device + +Enable the ``lvm`` backend in ``/etc/kolla/globals.yml``: + +:: + + enable_cinder_backend_lvm: "yes" + +.. note :: + There are currently issues using the LVM backend in a multi-controller setup, + see `_bug 1571211 `__ for more info. + +NFS +=== + +To use the ``nfs`` backend, configure ``/etc/exports`` to contain the mount +where the volumes are to be stored:: + + /kolla_nfs 192.168.5.0/24(rw,sync,no_root_squash) + +In this example, ``/kolla_nfs`` is the directory on the storage node which will +be ``nfs`` mounted, ``192.168.5.0/24`` is the storage network, and +``rw,sync,no_root_squash`` means make the share read-write, synchronous, and +prevent remote root users from having access to all files. + +Then start ``nfsd``:: + + systemctl start nfs + +On the deploy node, create ``/etc/kolla/config/nfs_shares`` with an entry for +each storage node:: + + storage01:/kolla_nfs + storage02:/kolla_nfs + +Finally, enable the ``nfs`` backend in ``/etc/kolla/globals.yml``:: + + enable_cinder_backend_nfs: "yes" + +Validation +========== + +Create a volume as follows: + +:: + + $ openstack volume create --size 1 steak_volume + + +Verify it is available. If it says "error" here something went wrong during +LVM creation of the volume. :: + + $ openstack volume list + +--------------------------------------+--------------+-----------+------+-------------+ + | ID | Display Name | Status | Size | Attached to | + +--------------------------------------+--------------+-----------+------+-------------+ + | 0069c17e-8a60-445a-b7f0-383a8b89f87e | steak_volume | available | 1 | | + +--------------------------------------+--------------+-----------+------+-------------+ + +Attach the volume to a server using: + +:: + + openstack server add volume steak_server 0069c17e-8a60-445a-b7f0-383a8b89f87e + +Check the console log added the disk: + +:: + + openstack console log show steak_server + +A ``/dev/vdb`` should appear in the console log, at least when booting cirros. +If the disk stays in the available state, something went wrong during the +iSCSI mounting of the volume to the guest VM. + +Cinder LVM2 back end with iSCSI +=============================== + +As of Newton-1 milestone, Kolla supports LVM2 as cinder back end. It is +accomplished by introducing two new containers ``tgtd`` and ``iscsid``. +``tgtd`` container serves as a bridge between cinder-volume process and a +server hosting Logical Volume Groups (LVG). ``iscsid`` container serves as +a bridge between nova-compute process and the server hosting LVG. + +In order to use Cinder's LVM back end, a LVG named ``cinder-volumes`` should +exist on the server and following parameter must be specified in +``globals.yml`` :: + + enable_cinder_backend_lvm: "yes" + +For Ubuntu and LVM2/iSCSI +~~~~~~~~~~~~~~~~~~~~~~~~~ + +``iscsd`` process uses configfs which is normally mounted at +``/sys/kernel/config`` to store discovered targets information, on centos/rhel +type of systems this special file system gets mounted automatically, which is +not the case on debian/ubuntu. Since ``iscsid`` container runs on every nova +compute node, the following steps must be completed on every Ubuntu server +targeted for nova compute role. + + - Add configfs module to ``/etc/modules`` + - Rebuild initramfs using: ``update-initramfs -u`` command + - Stop ``open-iscsi`` system service due to its conflicts + with iscsid container. + + Ubuntu 16.04 (systemd): + ``systemctl stop open-iscsi; systemctl stop iscsid`` + + - Make sure configfs gets mounted during a server boot up process. There are + multiple ways to accomplish it, one example: + :: + + mount -t configfs /etc/rc.local /sys/kernel/config + +Cinder back end with external iSCSI storage +=========================================== + +In order to use external storage system (like one from EMC or NetApp) +the following parameter must be specified in ``globals.yml`` :: + + enable_cinder_backend_iscsi: "yes" + +Also ``enable_cinder_backend_lvm`` should be set to "no" in this case. diff --git a/doc/source/reference/designate-guide.rst b/doc/source/reference/designate-guide.rst new file mode 100644 index 000000000..3c4b39047 --- /dev/null +++ b/doc/source/reference/designate-guide.rst @@ -0,0 +1,122 @@ +.. _designate-guide: + +================== +Designate in Kolla +================== + +Overview +======== +Designate provides DNSaaS services for OpenStack: + + - REST API for domain/record management + - Multi-tenant + - Integrated with Keystone for authentication + - Framework in place to integrate with Nova and Neutron + notifications (for auto-generated records) + - Support for PowerDNS and Bind9 out of the box + +Configuration on Kolla deployment +--------------------------------- + +Enable Designate service in ``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_designate: "yes" + +Configure Designate options in ``/etc/kolla/globals.yml`` + +.. important:: + + Designate MDNS node requires the ``dns_interface`` to be reachable from + public network. + +.. code-block:: console + + dns_interface: "eth1" + designate_backend: "bind9" + designate_ns_record: "sample.openstack.org" + +Neutron and Nova Integration +---------------------------- + +Create default Designate Zone for Neutron: + +.. code-block:: console + + $ openstack zone create --email admin@sample.openstack.org sample.openstack.org. + +Create designate-sink custom configuration folder: + +.. code-block:: console + + $ mkdir -p /etc/kolla/config/designate/ + +Append Designate Zone ID in ``/etc/kolla/config/designate/designate-sink.conf`` + +.. code-block:: console + + [handler:nova_fixed] + zone_id = + [handler:neutron_floatingip] + zone_id = + +Reconfigure Designate: + +.. code-block:: console + + $ kolla-ansible reconfigure -i --tags designate + +Verify operation +---------------- + +List available networks: + +.. code-block:: console + + $ openstack network list + +Associate a domain to a network: + +.. code-block:: console + + $ neutron net-update --dns_domain sample.openstack.org. + +Start an instance: + +.. code-block:: console + + $ openstack server create \ + --image cirros \ + --flavor m1.tiny \ + --key-name mykey \ + --nic net-id=${NETWORK_ID} \ + my-vm + +Check DNS records in Designate: + +.. code-block:: console + + $ openstack recordset list sample.openstack.org. + +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ + | id | name | type | records | status | action | + +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ + | 5aec6f5b-2121-4a2e-90d7-9e4509f79506 | sample.openstack.org. | SOA | sample.openstack.org. | ACTIVE | NONE | + | | | | admin.sample.openstack.org. 1485266928 3514 | | | + | | | | 600 86400 3600 | | | + | 578dc94a-df74-4086-a352-a3b2db9233ae | sample.openstack.org. | NS | sample.openstack.org. | ACTIVE | NONE | + | de9ff01e-e9ef-4a0f-88ed-6ec5ecabd315 | 192-168-190-232.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | + | f67645ee-829c-4154-a988-75341050a8d6 | my-vm.None.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | + | e5623d73-4f9f-4b54-9045-b148e0c3342d | my-vm.sample.openstack.org. | A | 192.168.190.232 | ACTIVE | NONE | + +--------------------------------------+---------------------------------------+------+---------------------------------------------+--------+--------+ + +Query instance DNS information to Designate ``dns_interface`` IP address: + +.. code-block:: console + + $ dig +short -p 5354 @ my-vm.sample.openstack.org. A + 192.168.190.232 + +For more information about how Designate works, see +`Designate, a DNSaaS component for OpenStack +`__. diff --git a/doc/source/reference/external-ceph-guide.rst b/doc/source/reference/external-ceph-guide.rst new file mode 100644 index 000000000..ef5875e71 --- /dev/null +++ b/doc/source/reference/external-ceph-guide.rst @@ -0,0 +1,202 @@ +.. _external-ceph-guide: + +============= +External Ceph +============= + +Sometimes it is necessary to connect OpenStack services to an existing Ceph +cluster instead of deploying it with Kolla. This can be achieved with only a +few configuration steps in Kolla. + +Requirements +============ + +* An existing installation of Ceph +* Existing Ceph storage pools +* Existing credentials in Ceph for OpenStack services to connect to Ceph + (Glance, Cinder, Nova) + +Enabling External Ceph +====================== + +Using external Ceph with Kolla means not to deploy Ceph via Kolla. Therefore, +disable Ceph deployment in ``/etc/kolla/global.yml`` + +:: + + enable_ceph: "no" + +There are flags indicating individual services to use ceph or not which default +to the value of ``enable_ceph``. Those flags now need to be activated in order +to activate external Ceph integration. This can be done individually per +service in ``/etc/kolla/global.yml``: + +:: + + glance_backend_ceph: "yes" + cinder_backend_ceph: "yes" + nova_backend_ceph: "yes" + +The combination of ``enable_ceph: "no"`` and ``_backend_ceph: "yes"`` +triggers the activation of external ceph mechanism in Kolla. + +Configuring External Ceph +========================= + +Glance +------ + +Configuring Glance for Ceph includes three steps: + +1) Configure RBD back end in glance-api.conf +2) Create Ceph configuration file in /etc/ceph/ceph.conf +3) Create Ceph keyring file in /etc/ceph/ceph.client..keyring + +Step 1 is done by using Kolla's INI merge mechanism: Create a file in +``/etc/kolla/config/glance/glance-api.conf`` with the following contents: + +:: + + [DEFAULT] + show_image_direct_url = True + + [glance_store] + stores = rbd + default_store = rbd + rbd_store_pool = images + rbd_store_user = glance + rbd_store_ceph_conf = /etc/ceph/ceph.conf + +Now put ceph.conf and the keyring file (name depends on the username created in +Ceph) into the same directory, for example: + +/etc/kolla/config/glance/ceph.conf + +:: + + [global] + fsid = 1d89fec3-325a-4963-a950-c4afedd37fe3 + mon_initial_members = ceph-0 + mon_host = 192.168.0.56 + auth_cluster_required = cephx + auth_service_required = cephx + auth_client_required = cephx + +/etc/kolla/config/glance/ceph.client.glance.keyring + +:: + + [client.glance] + key = AQAg5YRXS0qxLRAAXe6a4R1a15AoRx7ft80DhA== + +Kolla will pick up all files named ceph.* in this directory an copy them to the +/etc/ceph/ directory of the container. + +Cinder +------ + +Configuring external Ceph for Cinder works very similar to +Glance. + +Edit /etc/kolla/config/cinder/cinder-volume.conf with the following content: + +:: + + [DEFAULT] + enabled_backends=rbd-1 + + [rbd-1] + rbd_ceph_conf=/etc/ceph/ceph.conf + rbd_user=cinder + backend_host=rbd:volumes + rbd_pool=volumes + volume_backend_name=rbd-1 + volume_driver=cinder.volume.drivers.rbd.RBDDriver + rbd_secret_uuid = {{ cinder_rbd_secret_uuid }} + +.. note:: + + ``cinder_rbd_secret_uuid`` can be found in ``/etc/kolla/passwords.yml`` file. + +Edit /etc/kolla/config/cinder/cinder-backup.conf with the following content: + +:: + + [DEFAULT] + backup_ceph_conf=/etc/ceph/ceph.conf + backup_ceph_user=cinder + backup_ceph_chunk_size = 134217728 + backup_ceph_pool=backups + backup_driver = cinder.backup.drivers.ceph + backup_ceph_stripe_unit = 0 + backup_ceph_stripe_count = 0 + restore_discard_excess_bytes = true + +Next, place the ceph.conf file into +/etc/kolla/config/cinder/ceph.conf: + +:: + + [global] + fsid = 1d89fec3-325a-4963-a950-c4afedd37fe3 + mon_initial_members = ceph-0 + mon_host = 192.168.0.56 + auth_cluster_required = cephx + auth_service_required = cephx + auth_client_required = cephx + +Separate configuration options can be configured for +cinder-volume and cinder-backup by adding ceph.conf files to +/etc/kolla/config/cinder/cinder-volume and +/etc/kolla/config/cinder/cinder-backup respectively. They +will be merged with /etc/kolla/config/cinder/ceph.conf. + +Ceph keyrings are deployed per service and placed into +cinder-volume and cinder-backup directories: + +.. note:: + + ``cinder-backup`` requires two keyrings for accessing volumes + and backup pool. + +:: + + root@deploy:/etc/kolla/config# cat + cinder/cinder-backup/ceph.client.cinder.keyring + [client.cinder] + key = AQAg5YRXpChaGRAAlTSCleesthCRmCYrfQVX1w== + root@deploy:/etc/kolla/config# cat + cinder/cinder-backup/ceph.client.cinder-backup.keyring + [client.cinder-backup] + key = AQC9wNBYrD8MOBAAwUlCdPKxWZlhkrWIDE1J/w== + root@deploy:/etc/kolla/config# cat + cinder/cinder-volume/ceph.client.cinder.keyring + [client.cinder] + key = AQAg5YRXpChaGRAAlTSCleesthCRmCYrfQVX1w== + +It is important that the files are named ceph.client*. + +Nova +------ + +Put ceph.conf, nova client keyring file and cinder client keyring file into +``/etc/kolla/config/nova``: + +:: + + $ ls /etc/kolla/config/nova + ceph.client.cinder.keyring ceph.client.nova.keyring ceph.conf + +Configure nova-compute to use Ceph as the ephemeral back end by creating +``/etc/kolla/config/nova/nova-compute.conf`` and adding the following +contents: + +:: + + [libvirt] + images_rbd_pool=vms + images_type=rbd + images_rbd_ceph_conf=/etc/ceph/ceph.conf + rbd_user=nova + +.. note:: ``rbd_user`` might vary depending on your environment. diff --git a/doc/source/reference/hyperv-guide.rst b/doc/source/reference/hyperv-guide.rst new file mode 100644 index 000000000..3b175267b --- /dev/null +++ b/doc/source/reference/hyperv-guide.rst @@ -0,0 +1,174 @@ +.. _hyperv-guide: + +==================== +Nova-HyperV in Kolla +==================== + +Overview +======== +Currently, Kolla can deploy the following OpenStack services for Hyper-V: + +* nova-compute +* neutron-hyperv-agent +* wsgate + +It is possible to use Hyper-V as a compute node within an OpenStack Deployment. +The nova-compute service runs as openstack-compute, a 64-bit service directly +upon the Windows platform with the Hyper-V role enabled. The necessary Python +components as well as the nova-compute service are installed directly onto +the Windows platform. Windows Clustering Services are not needed for +functionality within the OpenStack infrastructure. + +The wsgate is the FreeRDP-WebConnect service that is used for accessing +virtual machines from Horizon web interface. + +.. note:: + + HyperV services are not currently deployed as containers. This functionality + is in development. The current implementation installs OpenStack services + via MSIs. + + +.. note:: + + HyperV services do not currently support outside the box upgrades. Manual + upgrades are required for this process. MSI release versions can be found + `here + `__. + To upgrade an existing MSI to a newer version, simply uninstall the current + MSI and install the newer one. This will not delete the configuration files. + To preserve the configuration files, check the Skip configuration checkbox + during installation. + + +Preparation for Hyper-V node +============================ + +Ansible communicates with Hyper-V host via WinRM protocol. An HTTPS WinRM +listener needs to be configured on the Hyper-V host, which can be easily +created with +`this PowerShell script +`__. + + +A virtual switch has to be created with which Hyper-V virtual machines +communicate with OpenStack. To quickly enable an interface to be used as a +Virtual Interface the following PowerShell may be used: + +.. code-block:: console + + PS C:\> $if = Get-NetIPAddress -IPAddress 192* | Get-NetIPInterface + PS C:\> New-VMSwitch -NetAdapterName $if.ifAlias -Name YOUR_BRIDGE_NAME -AllowManagementOS $false + +.. note:: + + It is very important to make sure that when you are using a Hyper-V node with only 1 NIC the + -AllowManagementOS option is set on True, otherwise you will lose connectivity to the Hyper-V node. + + +To prepare the Hyper-V node to be able to attach to volumes provided by +cinder you must first make sure the Windows iSCSI initiator service is +running and started automatically. + +.. code-block:: console + + PS C:\> Set-Service -Name MSiSCSI -StartupType Automatic + PS C:\> Start-Service MSiSCSI + + + +Preparation for Kolla deployer node +=================================== + +Hyper-V role is required, enable it in ``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_hyperv: "yes" + +Hyper-V options are also required in ``/etc/kolla/globals.yml``: + +.. code-block:: console + + hyperv_username: + hyperv_password: + vswitch_name: + nova_msi_url: "https://www.cloudbase.it/downloads/HyperVNovaCompute_Beta.msi" + +If tenant networks are to be built using VLAN add corresponding type in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + neutron_tenant_network_types: 'flat,vlan' + +The virtual switch is the same one created on the HyperV setup part. +For nova_msi_url, different Nova MSI (Mitaka/Newton/Ocata) versions can +be found on `Cloudbase website +`__. + + +Add the Hyper-V node in ``ansible/inventory`` file: + +.. code-block:: console + + [hyperv] + + + [hyperv:vars] + ansible_user= + ansible_password= + ansible_port=5986 + ansible_connection=winrm + ansible_winrm_server_cert_validation=ignore + +``pywinrm`` package needs to be installed in order for Ansible to work +on the HyperV node: + +.. code-block:: console + + pip install "pywinrm>=0.2.2" + +.. note:: + + In case of a test deployment with controller and compute nodes as virtual machines + on Hyper-V, if VLAN tenant networking is used, trunk mode has to be enabled on the + VMs: + +.. code-block:: console + + Set-VMNetworkAdapterVlan -Trunk -AllowedVlanIdList -NativeVlanId 0 + +networking-hyperv mechanism driver is needed for neutron-server to +communicate with HyperV nova-compute. This can be built with source +images by default. Manually it can be intalled in neutron-server +container with pip: + +.. code-block:: console + + pip install "networking-hyperv>=4.0.0" + +For neutron_extension_drivers, ``port_security`` and ``qos`` are +currently supported by the networking-hyperv mechanism driver. +By default only ``port_security`` is set. + + +Verify Operations +================= + +OpenStack HyperV services can be inspected and managed from PowerShell: + +.. code-block:: console + + PS C:\> Get-Service nova-compute + PS C:\> Get-Service neutron-hyperv-agent + +.. code-block:: console + + PS C:\> Restart-Service nova-compute + PS C:\> Restart-Service neutron-hyperv-agent + + +For more information on OpenStack HyperV, see +`Hyper-V virtualization platform +`__. diff --git a/doc/source/reference/index.rst b/doc/source/reference/index.rst new file mode 100644 index 000000000..aa819df04 --- /dev/null +++ b/doc/source/reference/index.rst @@ -0,0 +1,26 @@ +Reference +========= + +.. toctree:: + :maxdepth: 1 + + ceph-guide + central-logging-guide + external-ceph-guide + cinder-guide + cinder-guide-hnas + designate-guide + hyperv-guide + ironic-guide + manila-guide + manila-hnas-guide + nova-fake-driver + swift-guide + bifrost + networking-guide + kuryr-guide + zun-guide + osprofiler-guide + skydive-guide + vmware-guide + tacker-guide diff --git a/doc/source/reference/ironic-guide.rst b/doc/source/reference/ironic-guide.rst new file mode 100644 index 000000000..0d324b2ef --- /dev/null +++ b/doc/source/reference/ironic-guide.rst @@ -0,0 +1,75 @@ +.. _ironic-guide: + +=============== +Ironic in Kolla +=============== + +Overview +======== +Currently Kolla can deploy the Ironic services: + +- ironic-api +- ironic-conductor +- ironic-inspector + +As well as a required PXE service, deployed as ironic-pxe. + +Current status +============== +The Ironic implementation is "tech preview", so currently instances can only be +deployed on baremetal. Further work will be done to allow scheduling for both +virtualized and baremetal deployments. + +Pre-deployment Configuration +============================ + +Enable Ironic role in ``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_ironic: "yes" + +Beside that an additional network type 'vlan,flat' has to be added to a list of +tenant network types: + +.. code-block:: console + + neutron_tenant_network_types: "vxlan,vlan,flat" + +Configuring Web Console +======================= +Configuration based off upstream web_console_documentation_. + +Serial speed must be the same as the serial configuration in the BIOS settings. +Default value: 115200bps, 8bit, non-parity.If you have different serial speed. + +Set ironic_console_serial_speed in ``/etc/kolla/globals.yml``: + +:: + + ironic_console_serial_speed: 9600n8 + +.. _web_console_documentation: https://docs.openstack.org/ironic/latest/admin/console.html#node-web-console + +Post-deployment configuration +============================= +Configuration based off upstream documentation_. + +Again, remember that enabling Ironic reconfigures nova compute (driver and +scheduler) as well as changes neutron network settings. Further neutron setup +is required as outlined below. + +Create the flat network to launch the instances: +:: + + neutron net-create --tenant-id $TENANT_ID sharednet1 --shared \ + --provider:network_type flat --provider:physical_network physnet1 + + neutron subnet-create sharednet1 $NETWORK_CIDR --name $SUBNET_NAME \ + --ip-version=4 --gateway=$GATEWAY_IP --allocation-pool \ + start=$START_IP,end=$END_IP --enable-dhcp + +And then the above ID is used to set cleaning_network in the neutron +section of ironic.conf. + +.. _documentation: https://docs.openstack.org/ironic/latest/install/index.html diff --git a/doc/source/reference/kollanet.png b/doc/source/reference/kollanet.png new file mode 100644 index 000000000..cfb0c6014 Binary files /dev/null and b/doc/source/reference/kollanet.png differ diff --git a/doc/source/reference/kuryr-guide.rst b/doc/source/reference/kuryr-guide.rst new file mode 100644 index 000000000..eb47ef87a --- /dev/null +++ b/doc/source/reference/kuryr-guide.rst @@ -0,0 +1,63 @@ +Kuryr in Kolla +============== + +"Kuryr is a Docker network plugin that uses Neutron to provide networking +services to Docker containers. It provides containerized images for the common +Neutron plugins" [1]. Kuryr requires at least Keystone and neutron. Kolla makes +kuryr deployment faster and accessible. + +Requirements +------------ + +* A minimum of 3 hosts for a vanilla deploy + +Preparation and Deployment +-------------------------- + +To allow Docker daemon connect to the etcd, add the following in the +docker.service file. + +:: + + ExecStart= -H tcp://172.16.1.13:2375 -H unix:///var/run/docker.sock --cluster-store=etcd://172.16.1.13:2379 --cluster-advertise=172.16.1.13:2375 + +The IP address is host running the etcd service. ```2375``` is port that +allows Docker daemon to be accessed remotely. ```2379``` is the etcd listening +port. + +By default etcd and kuryr are disabled in the ``group_vars/all.yml``. +In order to enable them, you need to edit the file globals.yml and set the +following variables + +:: + + enable_etcd: "yes" + enable_kuryr: "yes" + +Deploy the OpenStack cloud and kuryr network plugin + +:: + + kolla-ansible deploy + +Create a Virtual Network +-------------------------------- + +:: + + docker network create -d kuryr --ipam-driver=kuryr --subnet=10.1.0.0/24 --gateway=10.1.0.1 docker-net1 + +To list the created network: + +:: + + docker network ls + +The created network is also available from OpenStack CLI: + +:: + + openstack network list + + +[1] https://github.com/openstack/kuryr diff --git a/doc/source/reference/manila-guide.rst b/doc/source/reference/manila-guide.rst new file mode 100644 index 000000000..d72a3b30c --- /dev/null +++ b/doc/source/reference/manila-guide.rst @@ -0,0 +1,357 @@ +.. _manila-guide: + +=============== +Manila in Kolla +=============== + +Overview +======== +Currently, Kolla can deploy following manila services: + +* manila-api +* manila-scheduler +* manila-share + +The OpenStack Shared File Systems service (Manila) provides file storage to a +virtual machine. The Shared File Systems service provides an infrastructure +for managing and provisioning of file shares. The service also enables +management of share types as well as share snapshots if a driver supports +them. + +Important +========= + +For simplicity, this guide describes configuring the Shared File Systems +service to use the ``generic`` back end with the driver handles share +server mode (DHSS) enabled that uses Compute (nova), Networking (neutron) +and Block storage (cinder) services. +Networking service configuration requires the capability of networks being +attached to a public router in order to create shared networks. + +Before you proceed, ensure that Compute, Networking and Block storage +services are properly working. + +Preparation and Deployment +========================== + +Cinder and Ceph are required, enable it in ``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_cinder: "yes" + enable_ceph: "yes" + +Enable Manila and generic back end in ``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_manila: "yes" + enable_manila_backend_generic: "yes" + +By default Manila uses instance flavor id 100 for its file systems. For Manila +to work, either create a new nova flavor with id 100 (use *nova flavor-create*) +or change *service_instance_flavor_id* to use one of the default nova flavor +ids. +Ex: *service_instance_flavor_id = 2* to use nova default flavor ``m1.small``. + +Create or modify the file ``/etc/kolla/config/manila-share.conf`` and add the +contents: + +.. code-block:: console + + [generic] + service_instance_flavor_id = 2 + +Verify Operation +================ + +Verify operation of the Shared File Systems service. List service components +to verify successful launch of each process: + +.. code-block:: console + + # manila service-list + +------------------+----------------+------+---------+-------+----------------------------+-----------------+ + | Binary | Host | Zone | Status | State | Updated_at | Disabled Reason | + +------------------+----------------+------+---------+-------+----------------------------+-----------------+ + | manila-scheduler | controller | nova | enabled | up | 2014-10-18T01:30:54.000000 | None | + | manila-share | share1@generic | nova | enabled | up | 2014-10-18T01:30:57.000000 | None | + +------------------+----------------+------+---------+-------+----------------------------+-----------------+ + +Launch an Instance +================== + +Before being able to create a share, the manila with the generic driver and the +DHSS mode enabled requires the definition of at least an image, a network and a +share-network for being used to create a share server. For that back end +configuration, the share server is an instance where NFS/CIFS shares are +served. + +Determine the configuration of the share server +=============================================== + +Create a default share type before running manila-share service: + +.. code-block:: console + + # manila type-create default_share_type True + +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ + | ID | Name | Visibility | is_default | required_extra_specs | optional_extra_specs | + +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ + | 8a35da28-0f74-490d-afff-23664ecd4f01 | default_share_type | public | - | driver_handles_share_servers : True | snapshot_support : True | + +--------------------------------------+--------------------+------------+------------+-------------------------------------+-------------------------+ + +Create a manila share server image to the Image service: + +.. code-block:: console + + # wget http://tarballs.openstack.org/manila-image-elements/images/manila-service-image-master.qcow2 + # glance image-create --name "manila-service-image" \ + --file manila-service-image-master.qcow2 \ + --disk-format qcow2 --container-format bare \ + --visibility public --progress + [=============================>] 100% + +------------------+--------------------------------------+ + | Property | Value | + +------------------+--------------------------------------+ + | checksum | 48a08e746cf0986e2bc32040a9183445 | + | container_format | bare | + | created_at | 2016-01-26T19:52:24Z | + | disk_format | qcow2 | + | id | 1fc7f29e-8fe6-44ef-9c3c-15217e83997c | + | min_disk | 0 | + | min_ram | 0 | + | name | manila-service-image | + | owner | e2c965830ecc4162a002bf16ddc91ab7 | + | protected | False | + | size | 306577408 | + | status | active | + | tags | [] | + | updated_at | 2016-01-26T19:52:28Z | + | virtual_size | None | + | visibility | public | + +------------------+--------------------------------------+ + +List available networks to get id and subnets of the private network: + +.. code-block:: console + + +--------------------------------------+---------+----------------------------------------------------+ + | id | name | subnets | + +--------------------------------------+---------+----------------------------------------------------+ + | 0e62efcd-8cee-46c7-b163-d8df05c3c5ad | public | 5cc70da8-4ee7-4565-be53-b9c011fca011 10.3.31.0/24 | + | 7c6f9b37-76b4-463e-98d8-27e5686ed083 | private | 3482f524-8bff-4871-80d4-5774c2730728 172.16.1.0/24 | + +--------------------------------------+---------+----------------------------------------------------+ + +Create a shared network + +.. code-block:: console + + # manila share-network-create --name demo-share-network1 \ + --neutron-net-id PRIVATE_NETWORK_ID \ + --neutron-subnet-id PRIVATE_NETWORK_SUBNET_ID + +-------------------+--------------------------------------+ + | Property | Value | + +-------------------+--------------------------------------+ + | name | demo-share-network1 | + | segmentation_id | None | + | created_at | 2016-01-26T20:03:41.877838 | + | neutron_subnet_id | 3482f524-8bff-4871-80d4-5774c2730728 | + | updated_at | None | + | network_type | None | + | neutron_net_id | 7c6f9b37-76b4-463e-98d8-27e5686ed083 | + | ip_version | None | + | nova_net_id | None | + | cidr | None | + | project_id | e2c965830ecc4162a002bf16ddc91ab7 | + | id | 58b2f0e6-5509-4830-af9c-97f525a31b14 | + | description | None | + +-------------------+--------------------------------------+ + +Create a flavor (**Required** if you not defined *manila_instance_flavor_id* in +``/etc/kolla/config/manila-share.conf`` file) + +.. code-block:: console + + # nova flavor-create manila-service-flavor 100 128 0 1 + +Create a share +============== + +Create a NFS share using the share network: + +.. code-block:: console + + # manila create NFS 1 --name demo-share1 --share-network demo-share-network1 + +-----------------------------+--------------------------------------+ + | Property | Value | + +-----------------------------+--------------------------------------+ + | status | None | + | share_type_name | None | + | description | None | + | availability_zone | None | + | share_network_id | None | + | export_locations | [] | + | host | None | + | snapshot_id | None | + | is_public | False | + | task_state | None | + | snapshot_support | True | + | id | 016ca18f-bdd5-48e1-88c0-782e4c1aa28c | + | size | 1 | + | name | demo-share1 | + | share_type | None | + | created_at | 2016-01-26T20:08:50.502877 | + | export_location | None | + | share_proto | NFS | + | consistency_group_id | None | + | source_cgsnapshot_member_id | None | + | project_id | 48e8c35b2ac6495d86d4be61658975e7 | + | metadata | {} | + +-----------------------------+--------------------------------------+ + +After some time, the share status should change from ``creating`` +to ``available``: + +.. code-block:: console + + # manila list + +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ + | ID | Name | Size | Share Proto | Status | Is Public | Share Type Name | Host | Availability Zone | + +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ + | e1e06b14-ba17-48d4-9e0b-ca4d59823166 | demo-share1 | 1 | NFS | available | False | default_share_type | share1@generic#GENERIC | nova | + +--------------------------------------+-------------+------+-------------+-----------+-----------+--------------------------------------+-----------------------------+-------------------+ + +Configure user access to the new share before attempting to mount it via the +network: + +.. code-block:: console + + # manila access-allow demo-share1 ip INSTANCE_PRIVATE_NETWORK_IP + +Mount the share from an instance +================================ + +Get export location from share + +.. code-block:: console + + # manila show demo-share1 + +-----------------------------+----------------------------------------------------------------------+ + | Property | Value | + +-----------------------------+----------------------------------------------------------------------+ + | status | available | + | share_type_name | default_share_type | + | description | None | + | availability_zone | nova | + | share_network_id | fa07a8c3-598d-47b5-8ae2-120248ec837f | + | export_locations | | + | | path = 10.254.0.3:/shares/share-422dc546-8f37-472b-ac3c-d23fe410d1b6 | + | | preferred = False | + | | is_admin_only = False | + | | id = 5894734d-8d9a-49e4-b53e-7154c9ce0882 | + | | share_instance_id = 422dc546-8f37-472b-ac3c-d23fe410d1b6 | + | share_server_id | 4782feef-61c8-4ffb-8d95-69fbcc380a52 | + | host | share1@generic#GENERIC | + | access_rules_status | active | + | snapshot_id | None | + | is_public | False | + | task_state | None | + | snapshot_support | True | + | id | e1e06b14-ba17-48d4-9e0b-ca4d59823166 | + | size | 1 | + | name | demo-share1 | + | share_type | 6e1e803f-1c37-4660-a65a-c1f2b54b6e17 | + | has_replicas | False | + | replication_type | None | + | created_at | 2016-03-15T18:59:12.000000 | + | share_proto | NFS | + | consistency_group_id | None | + | source_cgsnapshot_member_id | None | + | project_id | 9dc02df0f2494286ba0252b3c81c01d0 | + | metadata | {} | + +-----------------------------+----------------------------------------------------------------------+ + + +Create a folder where the mount will be placed: + +.. code-block:: console + + # mkdir ~/test_folder + +Mount the NFS share in the instance using the export location of the share: + +.. code-block:: console + + # mount -v 10.254.0.3:/shares/share-422dc546-8f37-472b-ac3c-d23fe410d1b6 ~/test_folder + +Share Migration +=============== + +As administrator, you can migrate a share with its data from one location to +another in a manner that is transparent to users and workloads. You can use +manila client commands to complete a share migration. + +For share migration, is needed modify ``manila.conf`` and set a ip in the same +provider network for ``data_node_access_ip``. + +Modify the file ``/etc/kolla/config/manila.conf`` and add the contents: + +.. code-block:: console + + [DEFAULT] + data_node_access_ip = 10.10.10.199 + + +.. note:: + + Share migration requires have more than one back end configured. + `Configure multiple back ends + `__. + +Use the manila migration command, as shown in the following example: + +.. code-block:: console + + manila migration-start --preserve-metadata True|False \ + --writable True|False --force_host_assisted_migration True|False \ + --new_share_type share_type --new_share_network share_network \ + shareID destinationHost + +- ``--force-host-copy``: Forces the generic host-based migration mechanism and + bypasses any driver optimizations. +- ``destinationHost``: Is in this format ``host#pool`` which includes + destination host and pool. +- ``--writable`` and ``--preserve-metadata``: Are only for driver assisted. +- ``--new_share_network``: Only if driver supports shared network. +- ``--new_share_type``: Choose share type compatible with destinationHost. + +Checking share migration progress +--------------------------------- + +Use the ``manila migration-get-progress shareID`` command to check progress. + +.. code-block:: console + + manila migration-get-progress demo-share1 + +----------------+-----------------------+ + | Property | Value | + +----------------+-----------------------+ + | task_state | data_copying_starting | + | total_progress | 0 | + +----------------+-----------------------+ + + manila migration-get-progress demo-share1 + +----------------+-------------------------+ + | Property | Value | + +----------------+-------------------------+ + | task_state | data_copying_completing | + | total_progress | 100 | + +----------------+-------------------------+ + +Use the ``manila migration-complete shareID`` command to complete share +migration process + +For more information about how to manage shares, see the +`OpenStack User Guide +`__. diff --git a/doc/source/reference/manila-hnas-guide.rst b/doc/source/reference/manila-hnas-guide.rst new file mode 100644 index 000000000..258c7e5b8 --- /dev/null +++ b/doc/source/reference/manila-hnas-guide.rst @@ -0,0 +1,330 @@ +.. _manila-hnas-guide: + +======================================================== +Hitachi NAS Platform File Services Driver for OpenStack +======================================================== + +Overview +======== +The Hitachi NAS Platform File Services Driver for OpenStack +provides NFS Shared File Systems to OpenStack. + + +Requirements +------------ +- Hitachi NAS Platform Models 3080, 3090, 4040, 4060, 4080, and 4100. + +- HNAS/SMU software version is 12.2 or higher. + +- HNAS configuration and management utilities to create a storage pool (span) + and an EVS. + + - GUI (SMU). + + - SSC CLI. + + +Supported shared file systems and operations +-------------------------------------------- +The driver supports CIFS and NFS shares. + +The following operations are supported: + +- Create a share. + +- Delete a share. + +- Allow share access. + +- Deny share access. + +- Create a snapshot. + +- Delete a snapshot. + +- Create a share from a snapshot. + +- Extend a share. + +- Shrink a share. + +- Manage a share. + +- Unmanage a share. + + +Preparation and Deployment +========================== + +.. note:: + + The manila-share node only requires the HNAS EVS data interface if you + plan to use share migration. + +.. important :: + + It is mandatory that HNAS management interface is reachable from the + Shared File System node through the admin network, while the selected + EVS data interface is reachable from OpenStack Cloud, such as through + Neutron flat networking. + + +Configuration on Kolla deployment +--------------------------------- + +Enable Shared File Systems service and HNAS driver in +``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_manila: "yes" + enable_manila_backend_hnas: "yes" + +Configure the OpenStack networking so it can reach HNAS Management +interface and HNAS EVS Data interface. + +To configure two physical networks, physnet1 and physnet2, with +ports eth1 and eth2 associated respectively: + +In ``/etc/kolla/globals.yml`` set: + +.. code-block:: console + + neutron_bridge_name: "br-ex,br-ex2" + neutron_external_interface: "eth1,eth2" + +.. note:: + + eth1: Neutron external interface. + eth2: HNAS EVS data interface. + + +HNAS back end configuration +--------------------------- + +In ``/etc/kolla/globals.yml`` uncomment and set: + +.. code-block:: console + + hnas_ip: "172.24.44.15" + hnas_user: "supervisor" + hnas_password: "supervisor" + hnas_evs_id: "1" + hnas_evs_ip: "10.0.1.20" + hnas_file_system_name: "FS-Manila" + + +Configuration on HNAS +--------------------- + +Create the data HNAS network in Kolla OpenStack: + +List the available tenants: + +.. code-block:: console + + $ openstack project list + +Create a network to the given tenant (service), providing the tenant ID, +a name for the network, the name of the physical network over which the +virtual network is implemented, and the type of the physical mechanism by +which the virtual network is implemented: + +.. code-block:: console + + $ neutron net-create --tenant-id hnas_network \ + --provider:physical_network=physnet2 --provider:network_type=flat + +*Optional* - List available networks: + +.. code-block:: console + + $ neutron net-list + +Create a subnet to the same tenant (service), the gateway IP of this subnet, +a name for the subnet, the network ID created before, and the CIDR of +subnet: + +.. code-block:: console + + $ neutron subnet-create --tenant-id --gateway \ + --name hnas_subnet + +*Optional* - List available subnets: + +.. code-block:: console + + $ neutron subnet-list + +Add the subnet interface to a router, providing the router ID and subnet +ID created before: + +.. code-block:: console + + $ neutron router-interface-add + +Create a file system on HNAS. See the `Hitachi HNAS reference `_. + +.. important :: + + Make sure that the filesystem is not created as a replication target. + Refer official HNAS administration guide. + +Prepare the HNAS EVS network. + +Create a route in HNAS to the tenant network: + +.. code-block:: console + + $ console-context --evs route-net-add --gateway \ + + +.. important :: + + Make sure multi-tenancy is enabled and routes are configured per EVS. + +.. code-block:: console + + $ console-context --evs 3 route-net-add --gateway 192.168.1.1 \ + 10.0.0.0/24 + + +Create a share +============== + +Create a default share type before running manila-share service: + +.. code-block:: console + + $ manila type-create default_share_hitachi False + + +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ + | ID | Name | visibility | is_default | required_extra_specs | optional_extra_specs | + +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ + | 3e54c8a2-1e50-455e-89a0-96bb52876c35 | default_share_hitachi | public | - | driver_handles_share_servers : False | snapshot_support : True | + +--------------------------------------+-----------------------+------------+------------+--------------------------------------+-------------------------+ + +Create a NFS share using the HNAS back end: + +.. code-block:: console + + manila create NFS 1 \ + --name mysharehnas \ + --description "My Manila share" \ + --share-type default_share_hitachi + +Verify Operation + +.. code-block:: console + + $ manila list + + +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ + | ID | Name | Size | Share Proto | Status | Is Public | Share Type Name | Host | Availability Zone | + +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ + | 721c0a6d-eea6-41af-8c10-72cd98985203 | mysharehnas | 1 | NFS | available | False | default_share_hitachi | control@hnas1#HNAS1 | nova | + +--------------------------------------+----------------+------+-------------+-----------+-----------+-----------------------+-------------------------+-------------------+ + +.. code-block:: console + + $ manila show mysharehnas + + +-----------------------------+-----------------------------------------------------------------+ + | Property | Value | + +-----------------------------+-----------------------------------------------------------------+ + | status | available | + | share_type_name | default_share_hitachi | + | description | My Manila share | + | availability_zone | nova | + | share_network_id | None | + | export_locations | | + | | path = 172.24.53.1:/shares/45ed6670-688b-4cf0-bfe7-34956648fb84 | + | | preferred = False | + | | is_admin_only = False | + | | id = e81e716f-f1bd-47b2-8a56-2c2f9e33a98e | + | | share_instance_id = 45ed6670-688b-4cf0-bfe7-34956648fb84 | + | share_server_id | None | + | host | control@hnas1#HNAS1 | + | access_rules_status | active | + | snapshot_id | None | + | is_public | False | + | task_state | None | + | snapshot_support | True | + | id | 721c0a6d-eea6-41af-8c10-72cd98985203 | + | size | 1 | + | user_id | ba7f6d543713488786b4b8cb093e7873 | + | name | mysharehnas | + | share_type | 3e54c8a2-1e50-455e-89a0-96bb52876c35 | + | has_replicas | False | + | replication_type | None | + | created_at | 2016-10-14T14:50:47.000000 | + | share_proto | NFS | + | consistency_group_id | None | + | source_cgsnapshot_member_id | None | + | project_id | c3810d8bcc3346d0bdc8100b09abbbf1 | + | metadata | {} | + +-----------------------------+-----------------------------------------------------------------+ + +Configure multiple back ends +============================ + +An administrator can configure an instance of Manila to provision shares from +one or more back ends. Each back end leverages an instance of a vendor-specific +implementation of the Manila driver API. + +The name of the back end is declared as a configuration option +share_backend_name within a particular configuration stanza that contains the +related configuration options for that back end. + +So, in the case of an multiple back ends deployment, it is necessary to change +the default share backends before deployment. + +Modify the file ``/etc/kolla/config/manila.conf`` and add the contents: + +.. code-block:: console + + [DEFAULT] + enabled_share_backends = generic,hnas1,hnas2 + +Modify the file ``/etc/kolla/config/manila-share.conf`` and add the contents: + +.. code-block:: console + + [generic] + share_driver = manila.share.drivers.generic.GenericShareDriver + interface_driver = manila.network.linux.interface.OVSInterfaceDriver + driver_handles_share_servers = True + service_instance_password = manila + service_instance_user = manila + service_image_name = manila-service-image + share_backend_name = GENERIC + + [hnas1] + share_backend_name = HNAS1 + share_driver = manila.share.drivers.hitachi.hnas.driver.HitachiHNASDriver + driver_handles_share_servers = False + hitachi_hnas_ip = + hitachi_hnas_user = + hitachi_hnas_password = + hitachi_hnas_evs_id = + hitachi_hnas_evs_ip = + hitachi_hnas_file_system_name = FS-Manila1 + + [hnas2] + share_backend_name = HNAS2 + share_driver = manila.share.drivers.hitachi.hnas.driver.HitachiHNASDriver + driver_handles_share_servers = False + hitachi_hnas_ip = + hitachi_hnas_user = + hitachi_hnas_password = + hitachi_hnas_evs_id = + hitachi_hnas_evs_ip = + hitachi_hnas_file_system_name = FS-Manila2 + +For more information about how to manage shares, see the +`OpenStack User Guide +`__. + +For more information about how HNAS driver works, see +`Hitachi NAS Platform File Services Driver for OpenStack +`__. diff --git a/doc/source/reference/networking-guide.rst b/doc/source/reference/networking-guide.rst new file mode 100644 index 000000000..04f29f3d4 --- /dev/null +++ b/doc/source/reference/networking-guide.rst @@ -0,0 +1,350 @@ +.. _networking-guide: + +========================== +Enabling Provider Networks +========================== +Provider networks allow to connect compute instances directly to physical +networks avoiding tunnels. This is necessary for example for some performance +critical applications. Only administrators of OpenStack can create such +networks. For provider networks compute hosts must have external bridge +created and configured by Ansible tasks like it is already done for tenant +DVR mode networking. Normal tenant non-DVR networking does not need external +bridge on compute hosts and therefore operators don't need additional +dedicated network interface. + +To enable provider networks modify the configuration +file ``/etc/kolla/globals.yml``: + +:: + + enable_neutron_provider_networks: "yes" + +=========================== +Enabling Neutron Extensions +=========================== + +Overview +======== +Kolla deploys Neutron by default as OpenStack networking component. This guide +describes configuring and running Neutron extensions like LBaaS, +Networking-SFC, QoS, etc. + +Networking-SFC +============== + +Preparation and deployment +-------------------------- + +Modify the configuration file ``/etc/kolla/globals.yml`` and change +the following: + +:: + + enable_neutron_sfc: "yes" + +Networking-SFC is an additional Neutron plugin. For SFC to work, this plugin +has to be installed in ``neutron-server`` container as well. Modify the +configuration file ``/etc/kolla/kolla-build.conf`` and add the following +contents: + +:: + + [neutron-server-plugin-networking-sfc] + type = git + location = https://github.com/openstack/networking-sfc.git + reference = mitaka + +Verification +------------ + +Verify the build and deploy operation of Networking-SFC container. Successful +deployment will bring up an SFC container in the list of running containers. +Run the following command to login into the ``neutron-server`` container: + +:: + + docker exec -it neutron_server bash + +Neutron should provide the following CLI extensions. + +:: + + #neutron help|grep port + + port-chain-create [port_chain] Create a Port Chain. + port-chain-delete [port_chain] Delete a given Port Chain. + port-chain-list [port_chain] List Port Chains that belong + to a given tenant. + port-chain-show [port_chain] Show information of a + given Port Chain. + port-chain-update [port_chain] Update Port Chain's + information. + port-pair-create [port_pair] Create a Port Pair. + port-pair-delete [port_pair] Delete a given Port Pair. + port-pair-group-create [port_pair_group] Create a Port Pair + Group. + port-pair-group-delete [port_pair_group] Delete a given + Port Pair Group. + port-pair-group-list [port_pair_group] List Port Pair Groups + that belongs to a given tenant. + port-pair-group-show [port_pair_group] Show information of a + given Port Pair Group. + port-pair-group-update [port_pair_group] Update Port Pair + Group's information. + port-pair-list [port_pair] List Port Pairs that belongs + to a given tenant. + port-pair-show [port_pair] Show information of a given + Port Pair. + port-pair-update [port_pair] Update Port Pair's + information. + +For setting up a testbed environment and creating a port chain, please refer +to the following link: + + https://wiki.openstack.org/wiki/Neutron/ServiceInsertionAndChaining + +For the source code, please refer to the following link: + + https://github.com/openstack/networking-sfc + + +Neutron VPNaaS (VPN-as-a-Service) +================================= + +Preparation and deployment +-------------------------- + +Modify the configuration file ``/etc/kolla/globals.yml`` and change +the following: + +:: + + enable_neutron_vpnaas: "yes" + +Verification +------------ + +VPNaaS is a complex subject, hence this document provides directions for a +simple smoke test to verify the service is up and running. + +On the network node(s), the ``neutron_vpnaas_agent`` should be up (image naming +and versioning may differ depending on deploy configuration): + +:: + + docker ps --filter name=neutron_vpnaas_agent + CONTAINER ID IMAGE + COMMAND CREATED STATUS PORTS + NAMES + 97d25657d55e + operator:5000/kolla/oraclelinux-source-neutron-vpnaas-agent:4.0.0 + "kolla_start" 44 minutes ago Up 44 minutes + neutron_vpnaas_agent + +Kolla-Ansible includes a small script that can be used in tandem with +``tools/init-runonce`` to verify the VPN using two routers and two Nova VMs: + +:: + + tools/init-runonce + tools/init-vpn + +Verify both VPN services are active: + +:: + + neutron vpn-service-list + +--------------------------------------+----------+--------------------------------------+--------+ + | id | name | router_id | status | + +--------------------------------------+----------+--------------------------------------+--------+ + | ad941ec4-5f3d-4a30-aae2-1ab3f4347eb1 | vpn_west | 051f7ce3-4301-43cc-bfbd-7ffd59af539e | ACTIVE | + | edce15db-696f-46d8-9bad-03d087f1f682 | vpn_east | 058842e0-1d01-4230-af8d-0ba6d0da8b1f | ACTIVE | + +--------------------------------------+----------+--------------------------------------+--------+ + +Two VMs can now be booted, one on vpn_east, the other on vpn_west, and +encrypted ping packets observed being sent from one to the other. + +For more information on this and VPNaaS in Neutron refer to the VPNaaS area on +the OpenStack wiki: + + https://wiki.openstack.org/wiki/Neutron/VPNaaS/HowToInstall + https://wiki.openstack.org/wiki/Neutron/VPNaaS + +Networking-ODL +============== + +Preparation and deployment +-------------------------- + +Modify the configuration file ``/etc/kolla/globals.yml`` and enable +the following: + +:: + + enable_opendaylight: "yes" + +Networking-ODL is an additional Neutron plugin that allows the OpenDaylight +SDN Controller to utilize its networking virtualization features. +For OpenDaylight to work, the Networking-ODL plugin has to be installed in +the ``neutron-server`` container. In this case, one could use the +neutron-server-opendaylight container and the opendaylight container by +pulling from Kolla dockerhub or by building them locally. + +OpenDaylight globals.yml configurable options with their defaults include: +:: + + opendaylight_release: "0.6.1-Carbon" + opendaylight_mechanism_driver: "opendaylight_v2" + opendaylight_l3_service_plugin: "odl-router_v2" + opendaylight_acl_impl: "learn" + enable_opendaylight_qos: "no" + enable_opendaylight_l3: "yes" + enable_opendaylight_legacy_netvirt_conntrack: "no" + opendaylight_port_binding_type: "pseudo-agentdb-binding" + opendaylight_features: "odl-mdsal-apidocs,odl-netvirt-openstack" + opendaylight_allowed_network_types: '"flat", "vlan", "vxlan"' + +Clustered OpenDaylight Deploy +----------------------------- +High availability clustered OpenDaylight requires modifying the inventory file +and placing three or more hosts in the OpenDaylight or Networking groups. +Note: The OpenDaylight role will allow deploy of one or three plus hosts for +OpenDaylight/Networking role. + +Verification +------------ + +Verify the build and deploy operation of Networking-ODL containers. Successful +deployment will bring up an Opendaylight container in the list of running +containers on network/opendaylight node. + +For the source code, please refer to the following link: + + https://github.com/openstack/networking-odl + + +OVS with DPDK +============= + +Introduction +------------ + +Open vSwitch (ovs) is an open source software virtual switch developed +and distributed via openvswitch.org. +The Data Plane Development Kit (dpdk) is a collection of userspace +libraries and tools that facilitate the development of high-performance +userspace networking applications. + +As of the ovs 2.2 release, the ovs netdev datapath has supported integration +with dpdk for accelerated userspace networking. As of the pike release +of kolla support for deploying ovs with dpdk (ovs-dpdk) has been added +to kolla ansible. The ovs-dpdk role introduced in the pike release has been +tested on centos 7 and ubuntu 16.04 hosts, however, ubuntu is recommended due +to conflicts with the cgroup configuration created by the default systemd +version shipped with centos 7. + +Prerequisites +------------- + +DPDK is a high-performance userspace networking library, as such it has +several requirements to function correctly that are not required when +deploying ovs without dpdk. + +To function efficiently one of the mechanisms dpdk uses to accelerate +memory access is the utilisation of kernel hugepages. The use of hugepage +memory minimises the chance of a translation lookaside buffer(TLB) miss when +translating virtual to physical memory as it increases the total amount of +addressable memory that can be cached via the TLB. Hugepage memory pages are +unswappable contiguous blocks of memory of typically 2MiB or 1GiB in size, +that can be used to facilitate efficient sharing of memory between guests and +a vSwitch or DMA mapping between physical nics and the userspace ovs datapath. + +To deploy ovs-dpdk on a platform a proportion of system memory should +be allocated hugepages. While it is possible to allocate hugepages at runtime +it is advised to allocate them via the kernel command line instead to prevent +memory fragmentation. This can be achieved by adding the following to the grub +config and regenerating your grub file. + +:: + + default_hugepagesz=2M hugepagesz=2M hugepages=25000 + + +As dpdk is a userspace networking library it requires userspace compatible +drivers to be able to control the physical interfaces on the platform. +dpdk technically support 3 kernel drivers igb_uio,uio_pci_generic and vfio_pci. +While it is technically possible to use all 3 only uio_pci_generic and vfio_pci +are recommended for use with kolla. igb_uio is BSD licenced and distributed +as part of the dpdk library. While it has some advantages over uio_pci_generic +loading the igb_uio module will taint the kernel and possibly invalidate +distro support. To successfully deploy ovs-dpdk, vfio_pci or uio_pci_generic +kernel module must be present on the platform. Most distros include vfio_pci +or uio_pci_generic as part of the default kernel though on some distros you +may need to install kernel-modules-extra or the distro equivalent prior to +running kolla-ansible deploy. + +Install +------- + +To enable ovs-dpdk add the following to /etc/kolla/globals.yml + +:: + + ovs_datapath: "netdev" + enable_ovs_dpdk: yes + enable_openvswitch: yes + tunnel_interface: "dpdk_bridge" + neutron_bridge_name: "dpdk_bridge" + +Unlike standard Open vSwitch deployments, the interface specified by +neutron_external_interface should have an ip address assigned. +The ip address assigned to neutron_external_interface will be moved to +the "dpdk_bridge" as part of deploy action. +When using ovs-dpdk the tunnel_interface must be an ovs bridge with a physical +interfaces attached for tunnelled traffic to be accelerated by dpdk. +Note that due to a limitation in ansible variable names which excluded +the use of - in a variable name it is not possible to use the default +br-ex name for the neutron_bridge_name or tunnel_interface. + +At present, the tunnel interface ip is configured using network manager on +on ubuntu and systemd on centos family operating systems. systemd is used +to work around a limitation of the centos network manager implementation which +does not consider the creation of an ovs bridge to be a hotplug event. In +the future, a new config option will be introduced to allow systemd to be used +on all host distros for those who do not wish to enable the network manager +service on ubuntu. + +To manage ovs-dpdk the neutron ovs agent must be configured to use +the netdev datapath_type in the ml2.conf. At present this is not automated +and must be set via kolla's external config support. To set the datapath_type +create a file with the following content at +/etc/kolla/config/neutron/ml2_conf.ini + +:: + + [ovs] + datapath_type = netdev + + +In the future, the requirement to use the external config will be removed by +automatically computing the value of ovs_datapath based on the value of +enable_ovs_dpdk and then using the ovs_datapath variable to template out this +setting in the ml2_conf.ini automatically. + +Limitations +----------- + +Reconfiguration from kernel ovs to ovs dpdk is currently not supported. +Changing ovs datapaths on a deployed node requires neutron config changes +and libvirt xml changes for all running instances including a hard reboot +of the vm. + +When upgrading ovs-dpdk it should be noted that this will always involve +a dataplane outage. Unlike kernel OVS the dataplane for ovs-dpdk executes in +the ovs-vswitchd process. This means the lifetime of the dpdk dataplane is +tied to the lifetime of the ovsdpdk_vswitchd container. As such it is +recommended to always evacuate all vm workloads from a node running ovs-dpdk +prior to upgrading. + +On ubuntu network manager is required for tunnel networking. +This requirement will be removed in the future. diff --git a/doc/source/reference/nova-fake-driver.rst b/doc/source/reference/nova-fake-driver.rst new file mode 100644 index 000000000..dd1557710 --- /dev/null +++ b/doc/source/reference/nova-fake-driver.rst @@ -0,0 +1,37 @@ +.. nova-fake-driver: + +================ +Nova Fake Driver +================ + +One common question from OpenStack operators is that "how does the control +plane (e.g., database, messaging queue, nova-scheduler ) scales?". To answer +this question, operators setup Rally to drive workload to the OpenStack cloud. +However, without a large number of nova-compute nodes, it becomes difficult to +exercise the control performance. + +Given the built-in feature of Docker container, Kolla enables standing up many +of nova-compute nodes with nova fake driver on a single host. For example, +we can create 100 nova-compute containers on a real host to simulate the +100-hypervisor workload to the nova-conductor and the messaging queue. + +Use nova-fake driver +==================== + +Nova fake driver can not work with all-in-one deployment. This is because the +fake neutron-openvswitch-agent for the fake nova-compute container conflicts +with neutron-openvswitch-agent on the compute nodes. Therefore, in the +inventory the network node must be different than the compute node. + +By default, Kolla uses libvirt driver on the compute node. To use nova-fake +driver, edit the following parameters in ``ansible/group_vars`` or in the +command line options. + +:: + + enable_nova_fake: "yes" + num_nova_fake_per_node: 5 + +Each compute node will run 5 nova-compute containers and 5 +neutron-plugin-agent containers. When booting instance, there will be no real +instances created. But *nova list* shows the fake instances. diff --git a/doc/source/reference/osprofiler-guide.rst b/doc/source/reference/osprofiler-guide.rst new file mode 100644 index 000000000..b94b65571 --- /dev/null +++ b/doc/source/reference/osprofiler-guide.rst @@ -0,0 +1,57 @@ +.. _osprofiler-guide: + +=================== +OSprofiler in Kolla +=================== + +Overview +======== +OSProfiler provides a tiny but powerful library that is used by most +(soon to be all) OpenStack projects and their corresponding python clients +as well as the Openstack client. +It provides functionality to generate 1 trace per request, that goes +through all involved services. This trace can then be extracted and used +to build a tree of calls which can be quite handy for a variety of reasons +(for example in isolating cross-project performance issues). + +Configuration on Kolla deployment +--------------------------------- + +Enable OSprofiler in ``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_osprofiler: "yes" + enable_elasticsearch: "yes" + +Verify operation +---------------- + +Retrieve ``osprofiler_secret`` key present at ``/etc/kolla/passwords.yml``. + +Profiler UUIDs can be created executing OpenStack clients (Nova, Glance, +Cinder, Heat, Keystone) with ``--profile`` option or using the official +Openstack client with ``--os-profile``. In example to get the OSprofiler trace +UUID for ``openstack server create``. + +.. code-block:: console + + $ openstack --os-profile \ + server create \ + --image cirros \ + --flavor m1.tiny \ + --key-name mykey \ + --nic net-id=${NETWORK_ID} \ + demo + + +The previous command will output the command to retrieve OSprofiler trace. + +.. code-block:: console + + $ osprofiler trace show --html --connection-string \ + elasticsearch://:9200 + +For more information about how OSprofiler works, see +`OSProfiler – Cross-project profiling library +`__. diff --git a/doc/source/reference/skydive-guide.rst b/doc/source/reference/skydive-guide.rst new file mode 100644 index 000000000..4e4f201f7 --- /dev/null +++ b/doc/source/reference/skydive-guide.rst @@ -0,0 +1,37 @@ +.. _skydive-guide: + +================ +Skydive in Kolla +================ + +Overview +======== +Skydive is an open source real-time network topology and protocols analyzer. +It aims to provide a comprehensive way of understanding what is happening in +the network infrastructure. +Skydive agents collect topology information and flows and forward them to a +central agent for further analysis. +All the information is stored in an Elasticsearch database. + +Configuration on Kolla deployment +--------------------------------- + +Enable Skydive in ``/etc/kolla/globals.yml`` + +.. code-block:: console + + enable_skydive: "yes" + enable_elasticsearch: "yes" + +Verify operation +---------------- + +After successful deployment, Skydive can be accessed using a browser on +``:8085``. + +The default username is ``admin``, the password can be located under +```` in ``/etc/kolla/passwords.yml``. + +For more information about how Skydive works, see +`Skydive – An open source real-time network topology and protocols analyzer +`__. diff --git a/doc/source/reference/swift-guide.rst b/doc/source/reference/swift-guide.rst new file mode 100644 index 000000000..f4339cc72 --- /dev/null +++ b/doc/source/reference/swift-guide.rst @@ -0,0 +1,192 @@ +.. _swift-guide: + +============== +Swift in Kolla +============== + +Overview +======== +Kolla can deploy a full working Swift setup in either a **all-in-one** or +**multinode** setup. + +Disks with a partition table (recommended) +========================================== + +Swift requires block devices to be available for storage. To prepare a disk +for use as a Swift storage device, a special partition name and filesystem +label need to be added. + +The following should be done on each storage node, the example is shown +for three disks: + +:: + + # + index=0 + for d in sdc sdd sde; do + parted /dev/${d} -s -- mklabel gpt mkpart KOLLA_SWIFT_DATA 1 -1 + sudo mkfs.xfs -f -L d${index} /dev/${d}1 + (( index++ )) + done + +For evaluation, loopback devices can be used in lieu of real disks: + +:: + + index=0 + for d in sdc sdd sde; do + free_device=$(losetup -f) + fallocate -l 1G /tmp/$d + losetup $free_device /tmp/$d + parted $free_device -s -- mklabel gpt mkpart KOLLA_SWIFT_DATA 1 -1 + sudo mkfs.xfs -f -L d${index} ${free_device}p1 + (( index++ )) + done + +Disks without a partition table +=============================== + +Kolla also supports unpartitioned disk (filesystem on ``/dev/sdc`` instead of +``/dev/sdc1``) detection purely based on filesystem label. This is generally +not a recommended practice but can be helpful for Kolla to take over Swift +deployment already using disk like this. + +Given hard disks with labels swd1, swd2, swd3, use the following settings in +``ansible/roles/swift/defaults/main.yml``. + +:: + + swift_devices_match_mode: "prefix" + swift_devices_name: "swd" + +Rings +===== + +Before running Swift we need to generate **rings**, which are binary compressed +files that at a high level let the various Swift services know where data is in +the cluster. We hope to automate this process in a future release. + +The following example commands should be run from the ``operator`` node to +generate rings for a demo setup. The commands work with **disks with partition +table** example listed above. Please modify accordingly if your setup is +different. + +:: + + STORAGE_NODES=(192.168.0.2 192.168.0.3 192.168.0.4) + KOLLA_SWIFT_BASE_IMAGE="kolla/oraclelinux-source-swift-base:4.0.0" + + mkdir -p /etc/kolla/config/swift + + # Object ring + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/object.builder create 10 3 1 + + for node in ${STORAGE_NODES[@]}; do + for i in {0..2}; do + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/object.builder add r1z1-${node}:6000/d${i} 1; + done + done + + # Account ring + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/account.builder create 10 3 1 + + for node in ${STORAGE_NODES[@]}; do + for i in {0..2}; do + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/account.builder add r1z1-${node}:6001/d${i} 1; + done + done + + # Container ring + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/container.builder create 10 3 1 + + for node in ${STORAGE_NODES[@]}; do + for i in {0..2}; do + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/container.builder add r1z1-${node}:6002/d${i} 1; + done + done + + for ring in object account container; do + docker run \ + --rm \ + -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ + $KOLLA_SWIFT_BASE_IMAGE \ + swift-ring-builder \ + /etc/kolla/config/swift/${ring}.builder rebalance; + done + +For more info, see +https://docs.openstack.org/project-install-guide/object-storage/ocata/initial-rings.html + +Deploying +========= +Enable Swift in ``/etc/kolla/globals.yml``: + +:: + + enable_swift : "yes" + +Once the rings are in place, deploying Swift is the same as any other Kolla +Ansible service: + +:: + + kolla-ansible deploy -i + +Validation +========== +A very basic smoke test: + +:: + + $ swift stat + Account: AUTH_4c19d363b9cf432a80e34f06b1fa5749 + Containers: 1 + Objects: 0 + Bytes: 0 + Containers in policy "policy-0": 1 + Objects in policy "policy-0": 0 + Bytes in policy "policy-0": 0 + X-Account-Project-Domain-Id: default + X-Timestamp: 1440168098.28319 + X-Trans-Id: txf5a62b7d7fc541f087703-0055d73be7 + Content-Type: text/plain; charset=utf-8 + Accept-Ranges: bytes + + $ swift upload mycontainer README.rst + README.md + + $ swift list + mycontainer + + $ swift download mycontainer README.md + README.md [auth 0.248s, headers 0.939s, total 0.939s, 0.006 MB/s] diff --git a/doc/source/reference/tacker-guide.rst b/doc/source/reference/tacker-guide.rst new file mode 100644 index 000000000..72b341d4a --- /dev/null +++ b/doc/source/reference/tacker-guide.rst @@ -0,0 +1,168 @@ +Tacker in Kolla +=============== + +"Tacker is an OpenStack service for NFV Orchestration with +a general purpose VNF Manager to deploy and operate +Virtual Network Functions (VNFs) and Network Services +on an NFV Platform. +It is based on ETSI MANO Architectural Framework." [1]. + +Overview +-------- + +As of the Pike release, tacker requires the following services +to be enabled to operate correctly. + +* Core compute stack (nova, neutron, glance, etc) +* Heat +* Mistral + Redis +* Barbican (Required only for multinode) + +Optionally tacker supports the following services and features. + +* Aodh +* Ceilometer +* Networking-sfc +* Opendaylight + +Compatibility +------------- + +Tacker is supported by the following distros and install_types. + +* Centos, Redhat and Oraclelinux. + + * Source and binary images. + +* Debian and Ubuntu. + + * Only source images. + +Preparation and Deployment +-------------------------- + +By default tacker and required services are disabled in +the ``group_vars/all.yml`` file. +In order to enable them, you need to edit the file +``/etc/kolla/globals.yml`` and set the following variables: + +.. note:: + + Heat is enabled by default, ensure it is not disabled. + +:: + + enable_tacker: "yes" + enable_barbican: "yes" + enable_mistral: "yes" + enable_redis: "yes" + +.. warning:: + + Barbican is required in multinode deployments to share VIM fernet_keys. + If not enabled, only one tacker-server host will have the keys on it + and any request made to a different tacker-server will fail with a + similar error as ``No such file or directory /etc/tacker/vim/fernet_keys`` + +Deploy tacker and related services. + +:: + + $ kolla-ansible deploy + +Verify +------ + +Generate the credentials file. + +:: + + $ kolla-ansible post-deploy + +Source credentials file. + +:: + + $ . /etc/kolla/admin-openrc.sh + +Create base neutron networks and glance images. + +:: + + $ sh tools/init-runonce + +.. note:: + + ``init-runonce`` file is located in ``$PYTHON_PATH/kolla-ansible`` + folder in kolla-ansible installation from pip. + +In kolla-ansible git repository a `tacker demo `_ +is present in ``kolla-ansible/contrib/demos/tacker/`` that will +create a very basic VNF from a cirros image in ``demo-net`` network. + +Install python-tackerclient. + +.. note:: + + Barbican, heat and mistral python clients are in tacker's + requirements and will be installed as dependency. + +:: + + $ pip install python-tackerclient + +Execute ``deploy-tacker-demo`` script to initialize the VNF creation. + +:: + + $ sh deploy-tacker-demo + +Tacker demo script will create sample VNF Descriptor (VNFD) file, +then register a default VIM, create a tacker VNFD and finally +deploy a VNF from the previously created VNFD. + + +After a few minutes, the tacker VNF is ACTIVE with a cirros instance +running in nova and with its corresponding heat stack CREATION_COMPLETE. + +Verify tacker VNF status is ACTIVE. + +:: + + $ tacker vnf-list + +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ + | id | name | mgmt_url | status | vim_id | vnfd_id | + +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ + | c52fcf99-101d-427b-8a2d-c9ef54af8b1d | kolla-sample-vnf | {"VDU1": "10.0.0.10"} | ACTIVE | eb3aa497-192c-4557-a9d7-1dff6874a8e6 | 27e8ea98-f1ff-4a40-a45c-e829e53b3c41 | + +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ + +Verify nova instance status is ACTIVE. + +:: + + $ openstack server list + +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ + | ID | Name | Status | Networks | Image | Flavor | + +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ + | d2d59eeb-8526-4826-8f1b-c50b571395e2 | ta-cf99-101d-427b-8a2d-c9ef54af8b1d-VDU1-fchiv6saay7p | ACTIVE | demo-net=10.0.0.10 | cirros | tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-c52fcf99-101d-427b-8a2d-c9ef54af8b1d-VDU1_flavor-yl4bzskwxdkn | + +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ + +Verify Heat stack status is CREATE_COMPLETE. + +:: + + $ openstack stack list + +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ + | ID | Stack Name | Project | Stack Status | Creation Time | Updated Time | + +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ + | 289a6686-70f6-4db7-aa10-ed169fe547a6 | tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-c52fcf99-101d-427b-8a2d-c9ef54af8b1d | 1243948e59054aab83dbf2803e109b3f | CREATE_COMPLETE | 2017-08-23T09:49:50Z | None | + +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ + +After the correct functionality of tacker is verified, tacker demo +can be cleaned up executing ``cleanup-tacker`` script. + +:: + + $ sh cleanup-tacker + +[1] https://docs.openstack.org/tacker/latest/ diff --git a/doc/source/reference/vmware-guide.rst b/doc/source/reference/vmware-guide.rst new file mode 100644 index 000000000..1b4ab108b --- /dev/null +++ b/doc/source/reference/vmware-guide.rst @@ -0,0 +1,251 @@ +.. _vmware-guide: + +==================== +VMware in Kolla +==================== + +Overview +======== +Kolla can deploy the Nova and Neutron Service(s) for VMware vSphere. +Depending on the network architecture (NsxV or DVS) you choose, Kolla deploys +the following OpenStack services for VMware vSphere: + +For VMware NsxV: + +* nova-compute +* neutron-server + +For VMware DVS: + +* nova-compute +* neutron-server +* neutron-dhcp-agent +* neutron-metadata-agent + +Kolla can deploy the Glance and Cinder services using VMware datastore as their +backend. Ceilometer metering for vSphere is also supported. + +Because the `vmware-nsx `__ drivers for +neutron use completely different architecture than other types of +virtualization, vmware-nsx drivers cannot coexist with other type +of virtualization in one region. In neutron vmware-nsx drivers, +neutron-server acts like an agent to translate OpenStack actions +into what vSphere/NSX Manager API can understand. Neutron does +not directly takes control of the Open vSwitch inside the VMware +environment but through the API exposed by vSphere/NSX Manager. + +For VMware DVS, the Neutron DHCP agent does not attaches to Open vSwitch inside +VMware environment, but attach to the Open vSwitch bridge called ``br-dvs`` on +the OpenStack side and replies to/receives DHCP packets through VLAN. Similar +to what the DHCP agent does, Neutron metadata agent attaches to ``br-dvs`` +bridge and works through VLAN. + +.. note:: + + VMware NSX-DVS plugin does not support tenant networks, so all VMs should + attach to Provider VLAN/Flat networks. + +VMware NSX-V +============ + +Preparation +----------- + +You should have a working NSX-V environment, this part is out of scope +of Kolla. +For more information, please see `VMware NSX-V documentation `__. + +.. note:: + + In addition, it is important to modify the firewall rule of vSphere to make + sure that VNC is accessible from outside VMware environment. + + On every VMware host, edit /etc/vmware/firewall/vnc.xml as below: + +.. code-block:: console + + + + + VNC + + inbound + tcp + dst + + 5900 + 5999 + + + + outbound + tcp + dst + + 0 + 65535 + + + true + false + + + +Then refresh the firewall config by: + +.. code-block:: console + + esxcli network firewall refresh + +Verify that the firewall config is applied: + +.. code-block:: console + + esxcli network firewall ruleset list + +Deployment +---------- + +Enable VMware nova-compute plugin and NSX-V neutron-server plugin in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + nova_compute_virt_type: "vmware" + neutron_plugin_agent: "vmware_nsxv" + +.. note:: + + VMware NSX-V also supports Neutron FWaaS, LBaaS and VPNaaS services, you can enable + them by setting these options in globals.yml: + + * enable_neutron_vpnaas: "yes" + * enable_neutron_lbaas: "yes" + * enable_neutron_fwaas: "yes" + +If you want to set VMware datastore as cinder backend, enable it in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_cinder: "yes" + cinder_backend_vmwarevc_vmdk: "yes" + vmware_datastore_name: "TestDatastore" + +If you want to set VMware datastore as glance backend, enable it in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + glance_backend_vmware: "yes" + vmware_vcenter_name: "TestDatacenter" + vmware_datastore_name: "TestDatastore" + +VMware options are required in ``/etc/kolla/globals.yml``, these options should +be configured correctly according to your NSX-V environment. + +Options for nova-compute and ceilometer: + +.. code-block:: console + + vmware_vcenter_host_ip: "127.0.0.1" + vmware_vcenter_host_username: "admin" + vmware_vcenter_host_password: "admin" + vmware_vcenter_cluster_name: "cluster-1" + vmware_vcenter_insecure: "True" + vmware_vcenter_datastore_regex: ".*" + +Options for Neutron NSX-V support: + +.. code-block:: console + + vmware_nsxv_user: "nsx_manager_user" + vmware_nsxv_password: "nsx_manager_password" + vmware_nsxv_manager_uri: "https://127.0.0.1" + vmware_nsxv_cluster_moid: "TestCluster" + vmware_nsxv_datacenter_moid: "TestDataCeter" + vmware_nsxv_resource_pool_id: "TestRSGroup" + vmware_nsxv_datastore_id: "TestDataStore" + vmware_nsxv_external_network: "TestDVSPort-Ext" + vmware_nsxv_vdn_scope_id: "TestVDNScope" + vmware_nsxv_dvs_id: "TestDVS" + vmware_nsxv_backup_edge_pool: "service:compact:1:2" + vmware_nsxv_spoofguard_enabled: "false" + vmware_nsxv_metadata_initializer: "false" + vmware_nsxv_edge_ha: "false" + + +.. note:: + + If you want to set secure connections to VMware, set ``vmware_vcenter_insecure`` + to false. + Secure connections to vCenter requires a CA file, copy the vCenter CA file to + ``/etc/kolla/config/vmware_ca``. + + +Then you should start kolla-ansible deployment normally as KVM/QEMU deployment. + + +VMware NSX-DVS +============== + +Preparation +----------- + +Before deployment, you should have a working VMware vSphere environment. +Create a cluster and a vSphere Distributed Switch with all the host in the +cluster attached to it. + +For more information, please see `Setting Up Networking with vSphere Distributed Switches `__. + +Deployment +---------- + +Enable VMware nova-compute plugin and NSX-V neutron-server plugin in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + nova_compute_virt_type: "vmware" + neutron_plugin_agent: "vmware_dvs" + +If you want to set VMware datastore as Cinder backend, enable it in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + enable_cinder: "yes" + cinder_backend_vmwarevc_vmdk: "yes" + vmware_datastore_name: "TestDatastore" + +If you want to set VMware datastore as Glance backend, enable it in +``/etc/kolla/globals.yml``: + +.. code-block:: console + + glance_backend_vmware: "yes" + vmware_vcenter_name: "TestDatacenter" + vmware_datastore_name: "TestDatastore" + +VMware options are required in ``/etc/kolla/globals.yml``, these options should +be configured correctly according to the vSphere environment you installed +before. All option for nova, cinder, glance are the same as VMware-NSX, except +the following options. + +Options for Neutron NSX-DVS support: + +.. code-block:: console + + vmware_dvs_host_ip: "192.168.1.1" + vmware_dvs_host_port: "443" + vmware_dvs_host_username: "admin" + vmware_dvs_host_password: "password" + vmware_dvs_dvs_name: "VDS-1" + vmware_dvs_dhcp_override_mac: "" + +Then you should start kolla-ansible deployment normally as KVM/QEMU deployment. + +For more information on OpenStack vSphere, see +`VMware vSphere +`__, +`VMware-NSX package `_. diff --git a/doc/source/reference/zun-guide.rst b/doc/source/reference/zun-guide.rst new file mode 100644 index 000000000..647d95933 --- /dev/null +++ b/doc/source/reference/zun-guide.rst @@ -0,0 +1,113 @@ +Zun in Kolla +============ + +"Zun is an OpenStack Container service. It aims to provide an +OpenStack API for provisioning and managing containerized +workload on OpenStack." [1]. + +Preparation and Deployment +-------------------------- + +Zun requires kuryr and etcd services, for more information about how to +configure kuryr refer to `Kuryr Guide `_. + +To allow Zun Compute connect to the Docker Daemon, add the following in the +``docker.service`` file on each zun-compute node. + +:: + + ExecStart= -H tcp://:2375 -H unix:///var/run/docker.sock --cluster-store=etcd://:2379 --cluster-advertise=:2375 + +.. note:: + + ``DOCKER_SERVICE_IP`` is zun-compute host IP address. ``2375`` is port that + allows Docker daemon to be accessed remotely. + +By default zun is disabled in the ``group_vars/all.yml``. +In order to enable it, you need to edit the file globals.yml and set the +following variables: + +:: + + enable_zun: "yes" + enable_kuryr: "yes" + enable_etcd: "yes" + +Deploy the OpenStack cloud and zun. + +:: + + $ kolla-ansible deploy + +Verify +------ + +Generate the credentials file. + +:: + + $ kolla-ansible post-deploy + +Source credentials file. + +:: + + $ . /etc/kolla/admin-openrc.sh + +Download and create a glance container image. + +:: + + $ docker pull cirros + $ docker save cirros | openstack image create cirros --public \ + --container-format docker --disk-format raw + +Create zun container. + +:: + + $ zun create --name test --net network=demo-net cirros ping -c4 8.8.8.8 + +.. note:: + + Kuryr does not support networks with DHCP enabled, disable DHCP in the + subnet used for zun containers. + + :: + + openstack subnet set --no-dhcp + +Verify container is created. + +:: + + $ zun list + +--------------------------------------+------+---------------+---------+------------+------------+-------+ + | uuid | name | image | status | task_state | addresses | ports | + +--------------------------------------+------+---------------+---------+------------+------------+-------+ + | 3719a73e-5f86-47e1-bc5f-f4074fc749f2 | test | cirros | Created | None | 172.17.0.3 | [] | + +--------------------------------------+------+---------------+---------+------------+------------+-------+ + +Start container. + +:: + + $ zun start test + Request to start container test has been accepted. + +Verify container. + +:: + + $ zun logs test + PING 8.8.8.8 (8.8.8.8): 56 data bytes + 64 bytes from 8.8.8.8: seq=0 ttl=45 time=96.396 ms + 64 bytes from 8.8.8.8: seq=1 ttl=45 time=96.504 ms + 64 bytes from 8.8.8.8: seq=2 ttl=45 time=96.721 ms + 64 bytes from 8.8.8.8: seq=3 ttl=45 time=95.884 ms + + --- 8.8.8.8 ping statistics --- + 4 packets transmitted, 4 packets received, 0% packet loss + round-trip min/avg/max = 95.884/96.376/96.721 ms + +[1] https://github.com/openstack/zun diff --git a/doc/source/user/advanced-configuration.rst b/doc/source/user/advanced-configuration.rst new file mode 100644 index 000000000..0b97bff6b --- /dev/null +++ b/doc/source/user/advanced-configuration.rst @@ -0,0 +1,231 @@ +.. _advanced-configuration: + +====================== +Advanced Configuration +====================== + +Endpoint Network Configuration +============================== + +When an OpenStack cloud is deployed, the REST API of each service is presented +as a series of endpoints. These endpoints are the admin URL, the internal +URL, and the external URL. + +Kolla offers two options for assigning these endpoints to network addresses: + - Combined - Where all three endpoints share the same IP address + - Separate - Where the external URL is assigned to an IP address that is + different than the IP address shared by the internal and admin URLs + +The configuration parameters related to these options are: + - kolla_internal_vip_address + - network_interface + - kolla_external_vip_address + - kolla_external_vip_interface + +For the combined option, set the two variables below, while allowing the +other two to accept their default values. In this configuration all REST +API requests, internal and external, will flow over the same network. :: + + kolla_internal_vip_address: "10.10.10.254" + network_interface: "eth0" + +For the separate option, set these four variables. In this configuration +the internal and external REST API requests can flow over separate +networks. :: + + kolla_internal_vip_address: "10.10.10.254" + network_interface: "eth0" + kolla_external_vip_address: "10.10.20.254" + kolla_external_vip_interface: "eth1" + +Fully Qualified Domain Name Configuration +========================================= + +When addressing a server on the internet, it is more common to use +a name, like www.example.net, instead of an address like 10.10.10.254. +If you prefer to use names to address the endpoints in your kolla +deployment use the variables: + + - kolla_internal_fqdn + - kolla_external_fqdn + +:: + + kolla_internal_fqdn: inside.mykolla.example.net + kolla_external_fqdn: mykolla.example.net + +Provisions must be taken outside of kolla for these names to map to the +configured IP addresses. Using a DNS server or the /etc/hosts file are +two ways to create this mapping. + +RabbitMQ Hostname Resolution +============================ + +RabbitMQ doesn't work with IP address, hence the IP address of api_interface +should be resolvable by hostnames to make sure that all RabbitMQ Cluster hosts +can resolve each others hostname beforehand. + +TLS Configuration +================= + +An additional endpoint configuration option is to enable or disable +TLS protection for the external VIP. TLS allows a client to authenticate +the OpenStack service endpoint and allows for encryption of the requests +and responses. + +.. note:: The kolla_internal_vip_address and kolla_external_vip_address must + be different to enable TLS on the external network. + +The configuration variables that control TLS networking are: + + - kolla_enable_tls_external + - kolla_external_fqdn_cert + +The default for TLS is disabled; to enable TLS networking: + +:: + + kolla_enable_tls_external: "yes" + kolla_external_fqdn_cert: "{{ node_config_directory }}/certificates/mycert.pem" + + +.. note:: TLS authentication is based on certificates that have been + signed by trusted Certificate Authorities. Examples of commercial + CAs are Comodo, Symantec, GoDaddy, and GlobalSign. Letsencrypt.org + is a CA that will provide trusted certificates at no charge. Many + company's IT departments will provide certificates within that + company's domain. If using a trusted CA is not possible for your + situation, you can use OpenSSL to create your own or see the section + company's domain. If using a trusted CA is not possible for your + situation, you can use `OpenSSL`_ to create your own or see the section + below about kolla generated self-signed certificates. + +Two certificate files are required to use TLS securely with authentication. +These two files will be provided by your Certificate Authority. These +two files are the server certificate with private key and the CA certificate +with any intermediate certificates. The server certificate needs to be +installed with the kolla deployment and is configured with the +``kolla_external_fqdn_cert`` parameter. If the server certificate provided +is not already trusted by the client, then the CA certificate file will +need to be distributed to the client. + +When using TLS to connect to a public endpoint, an OpenStack client will +have settings similar to this: + +:: + + export OS_PROJECT_DOMAIN_ID=default + export OS_USER_DOMAIN_ID=default + export OS_PROJECT_NAME=demo + export OS_USERNAME=demo + export OS_PASSWORD=demo-password + export OS_AUTH_URL=https://mykolla.example.net:5000 + # os_cacert is optional for trusted certificates + export OS_CACERT=/etc/pki/mykolla-cacert.crt + export OS_IDENTITY_API_VERSION=3 + +.. _OpenSSL: https://www.openssl.org/ + +Self-Signed Certificates +======================== + +.. note:: Self-signed certificates should never be used in production. + +It is not always practical to get a certificate signed by a well-known +trust CA, for example a development or internal test kolla deployment. In +these cases it can be useful to have a self-signed certificate to use. + +For convenience, the ``kolla-ansible`` command will generate the necessary +certificate files based on the information in the ``globals.yml`` +configuration file: + + :: + + kolla-ansible certificates + +The files haproxy.pem and haproxy-ca.pem will be generated and stored +in the ``/etc/kolla/certificates/`` directory. + +.. _service-config: + +OpenStack Service Configuration in Kolla +======================================== + +.. note:: As of now kolla only supports config overrides for ini based configs. + +An operator can change the location where custom config files are read from by +editing ``/etc/kolla/globals.yml`` and adding the following line. + +:: + + # The directory to merge custom config files the kolla's config files + node_custom_config: "/etc/kolla/config" + +Kolla allows the operator to override configuration of services. Kolla will +look for a file in ``/etc/kolla/config/<< service name >>/<< config file >>``. +This can be done per-project, per-service or per-service-on-specified-host. +For example to override scheduler_max_attempts in nova scheduler, the operator +needs to create ``/etc/kolla/config/nova/nova-scheduler.conf`` with content: + +:: + + [DEFAULT] + scheduler_max_attempts = 100 + +If the operator wants to configure compute node ram allocation ratio +on host myhost, the operator needs to create file +``/etc/kolla/config/nova/myhost/nova.conf`` with content: + +:: + + [DEFAULT] + ram_allocation_ratio = 5.0 + +The operator can make these changes after services were already deployed by +using following command: + +:: + + kolla-ansible reconfigure + +IP Address Constrained Environments +=================================== + +If a development environment doesn't have a free IP address available for VIP +configuration, the host's IP address may be used here by disabling HAProxy by +adding: + +:: + + enable_haproxy: "no" + +Note this method is not recommended and generally not tested by the +Kolla community, but included since sometimes a free IP is not available +in a testing environment. + +External Elasticsearch/Kibana environment +========================================= + +It is possible to use an external Elasticsearch/Kibana environment. To do this +first disable the deployment of the central logging. + +:: + + enable_central_logging: "no" + +Now you can use the parameter ``elasticsearch_address`` to configure the +address of the external Elasticsearch environment. + +Non-default port +========================== + +It is sometimes required to use a different than default port +for service(s) in Kolla. It is possible with setting _port +in ``globals.yml`` file. +For example: +:: + + database_port: 3307 + +As _port value is saved in different services' configuration so +it's advised to make above change before deploying. diff --git a/doc/source/user/deployment-philosophy.rst b/doc/source/user/deployment-philosophy.rst new file mode 100644 index 000000000..959148e4c --- /dev/null +++ b/doc/source/user/deployment-philosophy.rst @@ -0,0 +1,76 @@ +.. _deployment-philosophy: + +============================= +Kolla's Deployment Philosophy +============================= + +Overview +======== + +Kolla has an objective to replace the inflexible, painful, resource-intensive +deployment process of OpenStack with a flexible, painless, inexpensive +deployment process. Often to deploy OpenStack at the 100+ nodes scale, small +businesses may require building a team of OpenStack professionals to +maintain and manage the OpenStack deployment. Finding people experienced in +OpenStack deployment is very difficult and expensive, resulting in a big +barrier for OpenStack adoption. Kolla seeks to remedy this set of problems by +simplifying the deployment process while enabling flexible deployment models. + +Kolla is a highly opinionated deployment tool out of the box. This permits +Kolla to be deployable with the simple configuration of three key/value pairs. +As an operator's experience with OpenStack grows and the desire to customize +OpenStack services increases, Kolla offers full capability to override every +OpenStack service configuration option in the deployment. + +Why not Template Customization? +=============================== + +The Kolla upstream community does not want to place key/value pairs in the +Ansible playbook configuration options that are not essential to obtaining +a functional deployment. If the Kolla upstream starts down the path of +templating configuration options, the Ansible configuration could conceivably +grow to hundreds of configuration key/value pairs which is unmanageable. +Further, as new versions of Kolla are released, there would be independent +customization available for different versions creating an unsupportable and +difficult to document environment. Finally, adding key/value pairs for +configuration options creates a situation in which development and release +cycles are required in order to successfully add new customizations. +Essentially templating in configuration options is not a scalable solution +and would result in an inability of the project to execute its mission. + +Kolla's Solution to Customization +================================= + +Rather than deal with the customization madness of templating configuration +options in Kolla's Ansible playbooks, Kolla eliminates all the inefficiencies +of existing deployment tools through a simple, tidy design: custom +configuration sections. + +During deployment of an OpenStack service, a basic set of default configuration +options are merged with and overridden by custom ini configuration sections. +Kolla deployment customization is that simple! This does create a situation +in which the Operator must reference the upstream documentation if a +customization is desired in the OpenStack deployment. Fortunately the +configuration options documentation is extremely mature and well-formulated. + +As an example, consider running Kolla in a virtual machine. In order to +launch virtual machines from Nova in a virtual environment, it is necessary +to use the QEMU hypervisor, rather than the KVM hypervisor. To achieve this +result, simply `mkdir -p /etc/kolla/config` and modify the file +`/etc/kolla/config/nova.conf` with the contents:: + + [libvirt] + virt_type=qemu + +After this change Kolla will use an emulated hypervisor with lower performance. +Kolla could have templated this commonly modified configuration option. If +Kolla starts down this path, the Kolla project could end with hundreds of +config options all of which would have to be subjectively evaluated for +inclusion or exclusion in the source tree. + +Kolla's approach yields a solution which enables complete customization without +any upstream maintenance burden. Operators don't have to rely on a subjective +approval process for configuration options nor rely on a +development/test/release cycle to obtain a desired customization. Instead +operators have ultimate freedom to make desired deployment choices immediately +without the approval of a third party. diff --git a/doc/source/user/index.rst b/doc/source/user/index.rst new file mode 100644 index 000000000..786a54610 --- /dev/null +++ b/doc/source/user/index.rst @@ -0,0 +1,16 @@ +User Guides +=========== + +.. toctree:: + :maxdepth: 1 + + deployment-philosophy + production-architecture-guide + quickstart + multinode + multi-regions + advanced-configuration + operating-kolla + security + kolla-for-openstack-development + troubleshooting diff --git a/doc/source/user/kolla-for-openstack-development.rst b/doc/source/user/kolla-for-openstack-development.rst new file mode 100644 index 000000000..af2d1f9f1 --- /dev/null +++ b/doc/source/user/kolla-for-openstack-development.rst @@ -0,0 +1,76 @@ +===================================== +Using Kolla For OpenStack Development +===================================== + +Kolla-ansible can be used to deploy containers in a way suitable for doing +development on OpenStack services. + +.. note:: + + This functionality is new in the Pike release. + +Heat was the first service to be supported, and so the following will use +submitting a patch to Heat using Kolla as an example. + +Only source containers are supported. + +.. WARNING:: + + Kolla dev mode is intended for OpenStack hacking/development only. Do not + use this in production! + +Enabling Kolla "dev mode" +------------------------- + +To enable dev mode for all supported services, set in +``/etc/kolla/globals.yml``: + +:: + + kolla_dev_mode: true + +To enable it just for heat, set: + +:: + + heat_dev_mode: true + +Usage +----- + +When enabled, the source repo for the service in question will be cloned under +``/opt/stack/`` on the target node(s). This will be bind mounted into the +container's virtualenv under the location expected by the service on startup. + +After making code changes, simply restart the container to pick them up: + +:: + + docker restart heat_api + +Debugging +--------- + +``remote_pdb`` can be used to perform debugging with Kolla containers. First, +make sure it is installed in the container in question: + +:: + + docker exec -it -u root heat_api pip install remote_pdb + +Then, set your breakpoint as follows: + +:: + + from remote_pdb import RemotePdb + RemotePdb('127.0.0.1', 4444).set_trace() + +Once you run the code(restart the container), pdb can be accessed using +``socat``: + +:: + + socat readline tcp:127.0.0.1:4444 + +For more information on remote_pdb, see +https://pypi.python.org/pypi/remote-pdb. diff --git a/doc/source/user/multi-regions.rst b/doc/source/user/multi-regions.rst new file mode 100644 index 000000000..045f657f6 --- /dev/null +++ b/doc/source/user/multi-regions.rst @@ -0,0 +1,144 @@ +.. _multi-regions: + +====================================== +Multiple Regions Deployment with Kolla +====================================== + +This section describes how to perform a basic multiple regions deployment +with Kolla. A basic multiple regions deployment consists of separate +OpenStack installation in two or more regions (RegionOne, RegionTwo, ...) +with a shared Keystone and Horizon. The rest of this documentation assumes +Keystone and Horizon are deployed in RegionOne, and other regions have +access to the admin endpoint (i.e., ``kolla_internal_fqdn``) of RegionOne. +It also assumes that the operator knows the name of all OpenStack regions +in advance, and considers as many Kolla deployments as there are regions. + +There are specifications of multiple regions deployment at: +``__ +and +``__. + +Deployment of the first region with Keystone and Horizon +======================================================== + +Deployment of the first region results in a typical Kolla deployment +whenever, it is an *all-in-one* or *multinode* deployment (see +:doc:`quickstart`). It only requires slight modifications in the +``/etc/kolla/globals.yml`` configuration file. First of all, ensure that +Keystone and Horizon are enabled: + +:: + + enable_keystone: "yes" + enable_horizon: "yes" + +Then, change the value of ``multiple_regions_names`` to add names of other +regions. In this example, we consider two regions. The current one, +formerly knows as RegionOne, that is hided behind +``openstack_region_name`` variable, and the RegionTwo: + +:: + + openstack_region_name: "RegionOne" + multiple_regions_names: + - "{{ openstack_region_name }}" + - "RegionTwo" + +.. note:: Kolla uses these variables to create necessary endpoints into + Keystone so that services of other regions can access it. Kolla + also updates the Horizon ``local_settings`` to support multiple + regions. + +Finally, note the value of ``kolla_internal_fqdn`` and run +``kolla-ansible``. The ``kolla_internal_fqdn`` value will be used by other +regions to contact Keystone. For the sake of this example, we assume the +value of ``kolla_internal_fqdn`` is ``10.10.10.254``. + +Deployment of other regions +=========================== + +Deployment of other regions follows an usual Kolla deployment except that +OpenStack services connect to the RegionOne's Keystone. This implies to +update the ``/etc/kolla/globals.yml`` configuration file to tell Kolla how +to reach Keystone. In the following, ``kolla_internal_fqdn_r1`` refers to +the value of ``kolla_internal_fqdn`` in RegionOne: + +:: + + kolla_internal_fqdn_r1: 10.10.10.254 + + keystone_admin_url: "{{ admin_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_admin_port }}" + keystone_internal_url: "{{ internal_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_public_port }}" + + openstack_auth: + auth_url: "{{ admin_protocol }}://{{ kolla_internal_fqdn_r1 }}:{{ keystone_admin_port }}" + username: "admin" + password: "{{ keystone_admin_password }}" + project_name: "admin" + +Configuration files of cinder,nova,neutron,glance... have to be updated to +contact RegionOne's Keystone. Fortunately, Kolla offers to override all +configuration files at the same time thanks to the +``node_custom_config`` variable (see :ref:`service-config`). This +implies to create a ``global.conf`` file with the following content: + +:: + + [keystone_authtoken] + auth_uri = {{ keystone_internal_url }} + auth_url = {{ keystone_admin_url }} + +The Placement API section inside the nova configuration file also has +to be updated to contact RegionOne's Keystone. So create, in the same +directory, a ``nova.conf`` file with below content: + +:: + + [placement] + auth_url = {{ keystone_admin_url }} + +The Heat section inside the configuration file also +has to be updated to contact RegionOne's Keystone. So create, in the same +directory, a ``heat.conf`` file with below content: + +:: + [trustee] + auth_uri = {{ keystone_internal_url }} + auth_url = {{ keystone_internal_url }} + + [ec2authtoken] + auth_uri = {{ keystone_internal_url }} + + [clients_keystone] + auth_uri = {{ keystone_internal_url }} + +The Ceilometer section inside the configuration file also +has to be updated to contact RegionOne's Keystone. So create, in the same +directory, a ``ceilometer.conf`` file with below content: + +:: + [service_credentials] + auth_url = {{ keystone_internal_url }} + +And link the directory that contains these files into the +``/etc/kolla/globals.yml``: + +:: + + node_custom_config: path/to/the/directory/of/global&nova_conf/ + +Also, change the name of the current region. For instance, RegionTwo: + +:: + + openstack_region_name: "RegionTwo" + +Finally, disable the deployment of Keystone and Horizon that are +unnecessary in this region and run ``kolla-ansible``: + +:: + + enable_keystone: "no" + enable_horizon: "no" + +The configuration is the same for any other region. diff --git a/doc/source/user/multinode.rst b/doc/source/user/multinode.rst new file mode 100644 index 000000000..75c671fd7 --- /dev/null +++ b/doc/source/user/multinode.rst @@ -0,0 +1,210 @@ +.. _multinode: + +============================= +Multinode Deployment of Kolla +============================= + +.. _deploy_a_registry: + +Deploy a registry +================= + +A Docker registry is a locally hosted registry that replaces the need to pull +from the Docker Hub to get images. Kolla can function with or without a local +registry, however for a multinode deployment some type of registry is +mandatory. Only one registry must be deployed, although HA features exist for +registry services. + +The Docker registry prior to version 2.3 has extremely bad performance because +all container data is pushed for every image rather than taking advantage of +Docker layering to optimize push operations. For more information reference +`pokey registry `__. + +Edit the ``/etc/kolla/globals.yml`` and add the following where 192.168.1.100 +is the IP address of the machine and 5000 is the port where the registry is +currently running: + +:: + + docker_registry = 192.168.1.100:5000 + +The Kolla community recommends using registry 2.3 or later. To deploy registry +with version 2.3 or later, do the following: + +:: + + cd kolla + tools/start-registry + +The Docker registry can be configured as a pull through cache to proxy the +official Kolla images hosted in Docker Hub. In order to configure the local +registry as a pull through cache, in the host machine set the environment +variable ``REGISTRY_PROXY_REMOTEURL`` to the URL for the repository on +Docker Hub. + +:: + + export REGISTRY_PROXY_REMOTEURL=https://registry-1.docker.io + +.. note:: + + Pushing to a registry configured as a pull-through cache is unsupported. + For more information, Reference the `Docker Documentation + `__. + +.. _configure_docker_all_nodes: + +Configure Docker on all nodes +============================= + +.. note:: As the subtitle for this section implies, these steps should be + applied to all nodes, not just the deployment node. + +After starting the registry, it is necessary to instruct Docker that it will +be communicating with an insecure registry. To enable insecure registry +communication on CentOS, modify the ``/etc/sysconfig/docker`` file to contain +the following where 192.168.1.100 is the IP address of the machine where the +registry is currently running: + +:: + + # CentOS + INSECURE_REGISTRY="--insecure-registry 192.168.1.100:5000" + +For Ubuntu, check whether its using upstart or systemd. + +:: + + # stat /proc/1/exe + File: '/proc/1/exe' -> '/lib/systemd/systemd' + +Edit ``/etc/default/docker`` and add: + +:: + + # Ubuntu + DOCKER_OPTS="--insecure-registry 192.168.1.100:5000" + +If Ubuntu is using systemd, additional settings needs to be configured. +Copy Docker's systemd unit file to ``/etc/systemd/system/`` directory: + +:: + + cp /lib/systemd/system/docker.service /etc/systemd/system/docker.service + +Next, modify ``/etc/systemd/system/docker.service``, add ``environmentFile`` +variable and add ``$DOCKER_OPTS`` to the end of ExecStart in ``[Service]`` +section: + +:: + + # CentOS + [Service] + MountFlags=shared + EnvironmentFile=/etc/sysconfig/docker + ExecStart= + ExecStart=/usr/bin/docker daemon $INSECURE_REGISTRY + + # Ubuntu + [Service] + MountFlags=shared + EnvironmentFile=-/etc/default/docker + ExecStart= + ExecStart=/usr/bin/docker daemon -H fd:// $DOCKER_OPTS + +Restart Docker by executing the following commands: + +:: + + # CentOS or Ubuntu with systemd + systemctl daemon-reload + systemctl restart docker + + # Ubuntu with upstart or sysvinit + sudo service docker restart + +.. _edit-inventory: + +Edit the Inventory File +======================= + +The ansible inventory file contains all the information needed to determine +what services will land on which hosts. Edit the inventory file in the +Kolla-Ansible directory ``ansible/inventory/multinode``. If Kolla-Ansible +was installed with pip, it can be found in ``/usr/share/kolla-ansible``. + +Add the IP addresses or hostnames to a group and the services associated with +that group will land on that host. IP addresses or hostnames must be added to +the groups control, network, compute, monitoring and storage. Also, define +additional behavioral inventory parameters such as ``ansible_ssh_user``, +``ansible_become`` and ``ansible_private_key_file/ansible_ssh_pass`` which +controls how ansible interacts with remote hosts. + +.. note:: + + Ansible uses SSH to connect the deployment host and target hosts. For more + information about SSH authentication please reference + `Ansible documentation `__. + +:: + + # These initial groups are the only groups required to be modified. The + # additional groups are for more control of the environment. + [control] + # These hostname must be resolvable from your deployment host + control01 ansible_ssh_user= ansible_become=True ansible_private_key_file= + 192.168.122.24 ansible_ssh_user= ansible_become=True ansible_private_key_file= + +.. note:: + + Additional inventory parameters might be required according to your + environment setup. Reference `Ansible Documentation + `__ for more + information. + + +For more advanced roles, the operator can edit which services will be +associated in with each group. Keep in mind that some services have to be +grouped together and changing these around can break your deployment: + +:: + + [kibana:children] + control + + [elasticsearch:children] + control + + [haproxy:children] + network + +Deploying Kolla +=============== + +.. note:: + + If there are multiple keepalived clusters running within the same layer 2 + network, edit the file ``/etc/kolla/globals.yml`` and specify a + ``keepalived_virtual_router_id``. The ``keepalived_virtual_router_id`` should + be unique and belong to the range 0 to 255. + +.. note:: + + If glance is configured to use ``file`` as backend, only one ``glance_api`` + container will be started. ``File`` is enabled by default when no other + backend is specified in globals.yml + +First, check that the deployment targets are in a state where Kolla may deploy +to them: + +:: + + kolla-ansible prechecks -i + +Run the deployment: + +:: + + kolla-ansible deploy -i + +.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/source/user/operating-kolla.rst b/doc/source/user/operating-kolla.rst new file mode 100644 index 000000000..6d08b4206 --- /dev/null +++ b/doc/source/user/operating-kolla.rst @@ -0,0 +1,129 @@ +.. _operating-kolla: + +=============== +Operating Kolla +=============== + +Upgrading +========= +Kolla's strategy for upgrades is to never make a mess and to follow consistent +patterns during deployment such that upgrades from one environment to the next +are simple to automate. + +Kolla implements a one command operation for upgrading an existing deployment +consisting of a set of containers and configuration data to a new deployment. + +Kolla uses the ``x.y.z`` semver nomenclature for naming versions. Kolla's +Liberty version is ``1.0.0`` and the Mitaka version is ``2.0.0``. The Kolla +community commits to release z-stream updates every 45 days that resolve +defects in the stable version in use and publish those images to the Docker Hub +registry. To prevent confusion, the Kolla community recommends using an alpha +identifier ``x.y.z.a`` where ``a`` represents any customization done on the +part of the operator. For example, if an operator intends to modify one of the +Docker files or the repos from the originals and build custom images for the +Liberty version, the operator should start with version 1.0.0.0 and increase +alpha for each release. Alpha tag usage is at discretion of the operator. The +alpha identifier could be a number as recommended or a string of the operator's +choosing. + +If the alpha identifier is not used, Kolla will deploy or upgrade using the +version number information contained in the release. To customize the +version number uncomment openstack_version in globals.yml and specify +the version number desired. + +For example, to deploy a custom built Liberty version built with the +``kolla-build --tag 1.0.0.0`` operation, change globals.yml:: + + openstack_version: 1.0.0.0 + +Then run the command to deploy:: + + kolla-ansible deploy + +If using Liberty and a custom alpha number of 0, and upgrading to 1, change +globals.yml:: + + openstack_version: 1.0.0.1 + +Then run the command to upgrade:: + + kolla-ansible upgrade + +.. note:: Varying degrees of success have been reported with upgrading + the libvirt container with a running virtual machine in it. The libvirt + upgrade still needs a bit more validation, but the Kolla community feels + confident this mechanism can be used with the correct Docker graph driver. + +.. note:: The Kolla community recommends the btrfs or aufs graph drivers for + storing data as sometimes the LVM graph driver loses track of its reference + counting and results in an unremovable container. + +.. note:: Because of system technical limitations, upgrade of a libvirt + container when using software emulation (``virt_type = qemu`` in nova.conf), + does not work at all. This is acceptable because KVM is the recommended + virtualization driver to use with Nova. + + +Tips and Tricks +=============== +Kolla ships with several utilities intended to facilitate ease of operation. + +``tools/cleanup-containers`` is used to remove deployed containers from the +system. This can be useful when you want to do a new clean deployment. It will +preserve the registry and the locally built images in the registry, but will +remove all running Kolla containers from the local Docker daemon. It also +removes the named volumes. + +``tools/cleanup-host`` is used to remove remnants of network changes +triggered on the Docker host when the neutron-agents containers are launched. +This can be useful when you want to do a new clean deployment, particularly one +changing the network topology. + +``tools/cleanup-images --all`` is used to remove all Docker images built by +Kolla from the local Docker cache. + +``kolla-ansible -i INVENTORY deploy`` is used to deploy and start all Kolla +containers.. + +``kolla-ansible -i INVENTORY destroy`` is used to clean up containers and +volumes in the cluster. + +``kolla-ansible -i INVENTORY mariadb_recovery`` is used to recover a +completely stopped mariadb cluster. + +``kolla-ansible -i INVENTORY prechecks`` is used to check if all requirements +are meet before deploy for each of the OpenStack services. + +``kolla-ansible -i INVENTORY post-deploy`` is used to do post deploy on deploy +node to get the admin openrc file. + +``kolla-ansible -i INVENTORY pull`` is used to pull all images for containers. + +``kolla-ansible -i INVENTORY reconfigure`` is used to reconfigure OpenStack +service. + +``kolla-ansible -i INVENTORY upgrade`` is used to upgrades existing OpenStack +Environment. + +``kolla-ansible -i INVENTORY check`` is used to do post-deployment smoke +tests. + +.. note:: + In order to do smoke tests, requires ``kolla_enable_sanity_checks=yes``. + +``kolla-mergepwd --old OLD_PASSWDS --new NEW_PASSWDS --final FINAL_PASSWDS`` +is used to merge passwords from old installation with newly generated +passwords during upgrade of Kolla release. The workflow is: + +- Save old passwords from ``/etc/kolla/passwords.yml`` into + ``passwords.yml.old`` +- Generate new passwords via ``kolla-genpwd`` as ``passwords.yml.new`` +- Merge ``passwords.yml.old`` and ``passwords.yml.new`` into + ``/etc/kolla/passwords.yml`` + +For example:: + + mv /etc/kolla/passwords.yml passwords.yml.old + cp kolla-ansible/etc/kolla/passwords.yml passwords.yml.new + kolla-genpwd -p passwords.yml.new + kolla-mergepwd --old passwords.yml.old --new passwords.yml.new --final /etc/kolla/passwords.yml diff --git a/doc/source/user/production-architecture-guide.rst b/doc/source/user/production-architecture-guide.rst new file mode 100644 index 000000000..afeef30c7 --- /dev/null +++ b/doc/source/user/production-architecture-guide.rst @@ -0,0 +1,120 @@ +.. architecture-guide: + +============================= +Production architecture guide +============================= + +This guide will help with configuring Kolla to suit production needs. It is +meant to answer some questions regarding basic configuration options that Kolla +requires. This document also contains other useful pointers. + +Node types and services running on them +======================================= + +A basic Kolla inventory consists of several types of nodes, known in Ansible as +``groups``. + +* Control - Cloud controller nodes which host control services + like APIs and databases. This group should have odd number of nodes for + quorum. + +* Network - Network nodes host Neutron agents along with + haproxy / keepalived. These nodes will have a floating ip defined in + ``kolla_internal_vip_address``. + +* Compute - Compute nodes for compute services. This is where guest VMs + live. + +* Storage - Storage nodes, for cinder-volume, LVM or ceph-osd. + +* Monitoring - Monitor nodes which host monitoring services. + +Network configuration +===================== + +.. _interface-configuration: + +Interface configuration +*********************** + +In Kolla operators should configure following network interfaces: + +* ``network_interface`` - While it is not used on its own, this provides the + required default for other interfaces below. + +* ``api_interface`` - This interface is used for the management network. The + management network is the network OpenStack services uses to communicate to + each other and the databases. There are known security risks here, so it's + recommended to make this network internal, not accessible from outside. + Defaults to ``network_interface``. + +* ``kolla_external_vip_interface`` - This interface is public-facing one. It's + used when you want HAProxy public endpoints to be exposed in different + network than internal ones. It is mandatory to set this option when + ``kolla_enable_tls_external`` is set to yes. Defaults to + ``network_interface``. + +* ``storage_interface`` - This is the interface that is used by virtual + machines to communicate to Ceph. This can be heavily utilized so it's + recommended to put this network on 10Gig networking. Defaults to + ``network_interface``. + +* ``cluster_interface`` - This is another interface used by Ceph. It's used for + data replication. It can be heavily utilized also and if it becomes a + bottleneck it can affect data consistency and performance of whole cluster. + Defaults to ``network_interface``. + +* ``tunnel_interface`` - This interface is used by Neutron for vm-to-vm traffic + over tunneled networks (like VxLan). Defaults to ``network_interface``. + +* ``neutron_external_interface`` - This interface is required by Neutron. + Neutron will put br-ex on it. It will be used for flat networking as well as + tagged vlan networks. Has to be set separately. + +* ``dns_interface`` - This interface is required by Designate and Bind9. + Is used by public facing DNS requests and queries to bind9 and designate + mDNS services. Defaults to ``network_interface``. + +* ``bifrost_network_interface`` - This interface is required by Bifrost. + Is used to provision bare metal cloud hosts, require L2 connectivity + with the bare metal cloud hosts in order to provide DHCP leases with + PXE boot options. Defaults to ``network_interface``. + +.. WARNING:: + + Ansible facts does not recognize interface names containing dashes, + in example ``br-ex`` or ``bond-0`` cannot be used because ansible will read + them as ``br_ex`` and ``bond_0`` respectively. + +Docker configuration +==================== + +Because Docker is core dependency of Kolla, proper configuration of Docker can +change the experience of Kolla significantly. Following section will highlight +several Docker configuration details relevant to Kolla operators. + +Storage driver +************** + +In certain distributions Docker storage driver defaults to devicemapper, which +can heavily hit performance of builds and deploys. We suggest to use btrfs or +aufs as driver. More details on which storage driver to use in +`Docker documentation `_. + +Volumes +******* + +Kolla puts nearly all of persistent data in Docker volumes. These volumes are +created in Docker working directory, which defaults to + +:: + + /var/lib/docker + +We recommend to ensure that this directory has enough space and is placed on +fast disk as it will affect performance of builds, deploys as well as database +commits and rabbitmq. + +This becomes especially relevant when ``enable_central_logging`` and +``openstack_logging_debug`` are both set to true, as fully loaded 130 node +cluster produced 30-50GB of logs daily. diff --git a/doc/source/user/quickstart.rst b/doc/source/user/quickstart.rst new file mode 100644 index 000000000..ab52bc58b --- /dev/null +++ b/doc/source/user/quickstart.rst @@ -0,0 +1,693 @@ +.. quickstart: + +=========== +Quick Start +=========== + +This guide provides step by step instructions to deploy OpenStack using Kolla +and Kolla-Ansible on bare metal servers or virtual machines. + +Host machine requirements +========================= + +The host machine must satisfy the following minimum requirements: + +- 2 network interfaces +- 8GB main memory +- 40GB disk space + +.. note:: + + Root access to the deployment host machine is required. + +Recommended environment +======================= + +This guide recommends using a bare metal server or a virtual machine. Follow +the instructions in this document to get started with deploying OpenStack on +bare metal or a virtual machine with Kolla. + +If developing Kolla on a system that provides VirtualBox or Libvirt in addition +to Vagrant, use the Vagrant virtual environment documented in +`Development Environment with Vagrant `_. + +Prerequisites +============= + +Verify the state of network interfaces. If using a VM spawned on +OpenStack as the host machine, the state of the second interface will be DOWN +on booting the VM. + +:: + + ip addr show + +Bring up the second network interface if it is down. + +:: + + ip link set ens4 up + +Verify if the second interface has an IP address. + +:: + + ip addr show + +Install dependencies +==================== + +Kolla builds images which are used by Kolla-Ansible to deploy OpenStack. The +deployment is tested on CentOS, Oracle Linux and Ubuntu as both container OS +platforms and bare metal deployment targets. + +.. note:: Install is *very* sensitive about version of components. Please + review carefully because default Operating System repos are likely out of + date. + +Dependencies for the stable/mitaka branch are: + +===================== =========== =========== ========================= +Component Min Version Max Version Comment +===================== =========== =========== ========================= +Ansible 1.9.4 <2.0.0 On deployment host +Docker 1.10.0 none On target nodes +Docker Python 1.6.0 none On target nodes +Python Jinja2 2.6.0 none On deployment host +===================== =========== =========== ========================= + +Dependencies for the stable/newton are: + +===================== =========== =========== ========================= +Component Min Version Max Version Comment +===================== =========== =========== ========================= +Ansible 2.0.0 none On deployment host +Docker 1.10.0 none On target nodes +Docker Python 1.6.0 none On target nodes +Python Jinja2 2.8.0 none On deployment host +===================== =========== =========== ========================= + +Dependencies for the stable/ocata branch are: + +===================== =========== =========== ========================= +Component Min Version Max Version Comment +===================== =========== =========== ========================= +Ansible 2.0.0 none On deployment host +Docker 1.10.0 none On target nodes +Docker Python 1.8.1 none On target nodes +Python Jinja2 2.8.0 none On deployment host +===================== =========== =========== ========================= + +Dependencies since pike (including master branch) are: + +===================== =========== =========== ========================= +Component Min Version Max Version Comment +===================== =========== =========== ========================= +Ansible 2.2.0 none On deployment host +Docker 1.10.0 none On target nodes +Docker Python 2.0.0 none On target nodes +Python Jinja2 2.8.0 none On deployment host +===================== =========== =========== ========================= + +Make sure the ``pip`` package manager is installed and upgraded to the latest +before proceeding: + +:: + + #CentOS + yum install epel-release + yum install python-pip + pip install -U pip + + #Ubuntu + apt-get update + apt-get install python-pip + pip install -U pip + +Install dependencies needed to build the code with ``pip`` package manager. + +:: + + #CentOS + yum install python-devel libffi-devel gcc openssl-devel libselinux-python + + #Ubuntu + apt-get install python-dev libffi-dev gcc libssl-dev python-selinux + +Kolla deploys OpenStack using `Ansible `__. Install +Ansible from distribution packaging if the distro packaging has recommended +version available. + +Some implemented distro versions of Ansible are too old to use distro +packaging. Currently, CentOS and RHEL package Ansible >2.0 which is suitable +for use with Kolla. Note that you will need to enable access to the EPEL +repository to install via yum -- to do so, take a look at Fedora's EPEL `docs +`__ and `FAQ +`__. + +On CentOS or RHEL systems, this can be done using: + +:: + + yum install ansible + +Many DEB based systems do not meet Kolla's Ansible version requirements. It is +recommended to use pip to install Ansible >2.0. Finally Ansible >2.0 may be +installed using: + +:: + + pip install -U ansible + +.. note:: It is recommended to use virtualenv to install non-system packages. + +If DEB based systems include a version of Ansible that meets Kolla's version +requirements it can be installed by: + +:: + + apt-get install ansible + +.. WARNING:: + + Kolla uses PBR in its implementation. PBR provides version information + to Kolla about the package in use. This information is later used when + building images to specify the Docker tag used in the image built. When + installing the Kolla package via pip, PBR will always use the PBR version + information. When obtaining a copy of the software via git, PBR will use + the git version information, but **ONLY** if Kolla has not been pip + installed via the pip package manager. This is why there is an operator + workflow and a developer workflow. + +The following dependencies can be installed by bootstraping the host machine +as described in the `Automatic host bootstrap`_ section. For manual +installation, follow the instructions below: + +Since Docker is required to build images as well as be present on all deployed +targets, the Kolla community recommends installing the official Docker, Inc. +packaged version of Docker for maximum stability and compatibility with the +following command: + +:: + + curl -sSL https://get.docker.io | bash + +This command will install the most recent stable version of Docker, but please +note that Kolla releases are not in sync with Docker in any way, so some things +could stop working with new version. The latest release of Kolla is tested to +work with docker-engine>=1.10.0,!=1.13.0. To check your Docker version run this +command: + +:: + + docker --version + +When running with systemd, setup docker-engine with the appropriate information +in the Docker daemon to launch with. This means setting up the following +information in the ``docker.service`` file. If you do not set the MountFlags +option correctly then ``kolla-ansible`` will fail to deploy the +``neutron-dhcp-agent`` container and throws APIError/HTTPError. After adding +the drop-in unit file as follows, reload and restart the Docker service: + +:: + + # Create the drop-in unit directory for docker.service + mkdir -p /etc/systemd/system/docker.service.d + + # Create the drop-in unit file + tee /etc/systemd/system/docker.service.d/kolla.conf <<-'EOF' + [Service] + MountFlags=shared + EOF + +Restart Docker by executing the following commands: + +:: + + # Run these commands to reload the daemon + systemctl daemon-reload + systemctl restart docker + +On the target hosts you also need to install the latest version of the Docker +python libraries with pip: + +:: + + pip install -U docker + + +OpenStack, RabbitMQ, and Ceph require all hosts to have matching times to +ensure proper message delivery. In the case of Ceph, it will complain if the +hosts differ by more than 0.05 seconds. Some OpenStack services have timers as +low as 2 seconds by default. For these reasons it is highly recommended to +setup an NTP service of some kind. While ``ntpd`` will achieve more accurate +time for the deployment if the NTP servers are running in the local deployment +environment, `chrony `_ is more accurate when +syncing the time across a WAN connection. When running Ceph it is recommended +to setup ``ntpd`` to sync time locally due to the tight time constraints. + +To install, start, and enable ntp on CentOS execute the following: + +:: + + # CentOS 7 + yum install ntp + systemctl enable ntpd.service + systemctl start ntpd.service + +To install and start on Debian based systems execute the following: + +:: + + apt-get install ntp + +Libvirt is started by default on many operating systems. Please disable +``libvirt`` on any machines that will be deployment targets. Only one copy of +libvirt may be running at a time. + +:: + + # CentOS 7 + systemctl stop libvirtd.service + systemctl disable libvirtd.service + + # Ubuntu + service libvirt-bin stop + update-rc.d libvirt-bin disable + +On Ubuntu, apparmor will sometimes prevent libvirt from working. + +:: + + /usr/sbin/libvirtd: error while loading shared libraries: + libvirt-admin.so.0: cannot open shared object file: Permission denied + +If you are seeing the libvirt container fail with the error above, disable the +libvirt profile. + +:: + + sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.libvirtd + + +.. note:: + + On Ubuntu 16.04, please uninstall lxd and lxc packages. (An issue exists + with cgroup mounts, mounts exponentially increasing when restarting + container). + +Additional steps for upstart and other non-systemd distros +========================================================== + +For other non-systemd distros, run the following. + +:: + + mount --make-shared /run + mount --make-shared /var/lib/nova/mnt + +If /var/lib/nova/mnt is not present, do the workaround below. + +:: + + mkdir -p /var/lib/nova/mnt /var/lib/nova/mnt1 + mount --bind /var/lib/nova/mnt1 /var/lib/nova/mnt + mount --make-shared /var/lib/nova/mnt + +For mounting /run and /var/lib/nova/mnt as shared upon startup, edit +/etc/rc.local to add the following. + +:: + + mount --make-shared /run + mount --make-shared /var/lib/nova/mnt + +.. note:: + + If CentOS/Fedora/OracleLinux container images are built on an Ubuntu host, + the back-end storage driver must not be AUFS (see the known issues in + `Building Container Images`_). + +Install Kolla for deployment or evaluation +========================================== + +Install kolla-ansible and its dependencies using pip. + +:: + + pip install kolla-ansible + +Copy the configuration files globals.yml and passwords.yml to /etc directory. + +:: + + #CentOS + cp -r /usr/share/kolla-ansible/etc_examples/kolla /etc/kolla/ + + #Ubuntu + cp -r /usr/local/share/kolla-ansible/etc_examples/kolla /etc/kolla/ + +The inventory files (all-in-one and multinode) are located in +/usr/local/share/kolla-ansible/ansible/inventory. Copy the configuration files +to the current directory. + +:: + + #CentOS + cp /usr/share/kolla-ansible/ansible/inventory/* . + + #Ubuntu + cp /usr/local/share/kolla-ansible/ansible/inventory/* . + +Install Kolla for development +============================= + +Clone the Kolla and Kolla-Ansible repositories from git. + +:: + + git clone https://github.com/openstack/kolla + git clone https://github.com/openstack/kolla-ansible + +Kolla-ansible holds configuration files (globals.yml and passwords.yml) in +etc/kolla. Copy the configuration files to /etc directory. + +:: + + cp -r kolla-ansible/etc/kolla /etc/kolla/ + +Kolla-ansible holds the inventory files (all-in-one and multinode) in +ansible/inventory. Copy the configuration files to the current directory. + +:: + + cp kolla-ansible/ansible/inventory/* . + +Local Registry +============== + +A local registry is recommended but not required for an ``all-in-one`` +installation when developing for master. Since no master images are available +on docker hub, the docker cache may be used for all-in-one deployments. When +deploying multinode, a registry is strongly recommended to serve as a single +source of images. Reference the +`Multinode Deployment of Kolla `_ +for more information on using a local Docker registry. +Otherwise, the Docker Hub Image Registry contains all +images from each of Kolla’s major releases. The latest release tag is 3.0.2 for +Newton. + +Automatic host bootstrap +======================== + +Edit the ``/etc/kolla/globals.yml`` file to configure interfaces. + +:: + + network_interface: "ens3" + neutron_external_interface: "ens4" + +Generate passwords. This will populate all empty fields in the +``/etc/kolla/passwords.yml`` file using randomly generated values to secure the +deployment. Optionally, the passwords may be populated in the file by hand. + +:: + + kolla-genpwd + +To quickly prepare hosts, playbook bootstrap-servers can be used. This is an +Ansible playbook which works on Ubuntu 16.04 and CentOS 7 hosts to +install and prepare the cluster for OpenStack installation. + +:: + + kolla-ansible -i <> bootstrap-servers + +Build container images +====================== + +When running with systemd, edit the file +``/etc/systemd/system/docker.service.d/kolla.conf`` +to include the MTU size to be used for Docker containers. + +:: + + [Service] + MountFlags=shared + ExecStart= + ExecStart=/usr/bin/docker daemon \ + -H fd:// \ + --mtu 1400 + +.. note:: + + Depend of your Docker version and distro, ExecStart command may be different which may cause + Docker start failures. The default ExecStart command for your system can be obtained from + ``/usr/lib/systemd/system/docker.service``. + +.. note:: + + The MTU size should be less than or equal to the MTU size allowed on the + network interfaces of the host machine. If the MTU size allowed on the + network interfaces of the host machine is 1500 then this step can be + skipped. This step is relevant for building containers. Actual openstack + services won't be affected. + +.. note:: + + Verify that the MountFlags parameter is configured as shared. If you do not + set the MountFlags option correctly then kolla-ansible will fail to deploy the + neutron-dhcp-agent container and throws APIError/HTTPError. + +Restart Docker and ensure that Docker is running. + +:: + + systemctl daemon-reload + systemctl restart docker + +The Kolla community builds and pushes tested images for each tagged release of +Kolla. Pull required images with appropriate tags in target nodes. + +:: + + kolla-ansible pull -i /path/to/all-in-one + +View the images. + +:: + + docker images + +Developers running from master are required to build container images as the +Docker Hub does not contain built images for the master branch. Reference the +`Building Container Images`_ for more advanced build configuration. + +To build images using default parameters run: + +:: + + kolla-build + +By default kolla-build will build all containers using CentOS as the base image +and binary installation as base installation method. To change this behavior, +please use the following parameters with kolla-build: + +:: + + --base [ubuntu|centos|oraclelinux] + --type [binary|source] + +.. note:: + + --base and --type can be added to the above kolla-build command if + different distributions or types are desired. + +It is also possible to build individual container images. As an example, if the +glance images failed to build, all glance related images can be rebuilt as +follows: + +:: + + kolla-build glance + +In order to see all available parameters, run: + +:: + + kolla-build -h + +View the images. + +:: + + docker images + +.. WARNING:: + + Mixing of OpenStack releases with Kolla releases (example, updating + kolla-build.conf to build Mitaka Keystone to be deployed with Newton Kolla) is + not recommended and will likely cause issues. + +Deploy Kolla +============ + +Kolla-Ansible is used to deploy containers by using images built by Kolla. +There are two methods of deployment: *all-in-one* and *multinode*. The +*all-in-one* deployment is similar to `devstack +`__ deploy which installs all +OpenStack services on a single host. In the *multinode* deployment, OpenStack +services can be run on specific hosts. This documentation describes deploying +an *all-in-one* setup. To setup *multinode* see the +`Multinode Deployment of Kolla `_. + +.. note:: + + For *multinode* deployment of kolla, check if all the hostnames are + resolvable. RabbitMQ can't work with IP addresses, so we need to make + sure that all RabbitMQ cluster hosts can resolve each other's hostnames. + +Each method is represented as an Ansible inventory file. More information on +the Ansible inventory file can be found in the Ansible `inventory introduction +`_. + +All variables for the environment can be specified in the files: +``/etc/kolla/globals.yml`` and ``/etc/kolla/passwords.yml``. + +Generate passwords for ``/etc/kolla/passwords.yml`` using the provided +``kolla-genpwd`` tool. The tool will populate all empty fields in the +``/etc/kolla/passwords.yml`` file using randomly generated values to secure the +deployment. Optionally, the passwords may be populate in the file by hand. + +:: + + kolla-genpwd + +Start by editing ``/etc/kolla/globals.yml``. Check and edit, if needed, these +parameters: ``kolla_base_distro``, ``kolla_install_type``. The default for +``kolla_base_distro`` is ``centos`` and for ``kolla_install_type`` is +``binary``. If you want to use ubuntu with source type, then you should make +sure globals.yml has the following entries: + +:: + + kolla_base_distro: "ubuntu" + kolla_install_type: "source" + +Please specify an unused IP address in the network to act as a VIP for +``kolla_internal_vip_address``. The VIP will be used with keepalived and added +to the ``api_interface`` as specified in the ``globals.yml`` + +:: + + kolla_internal_vip_address: “192.168.137.79” + +.. note:: + + The kolla_internal_vip_address must be unique and should belong to the same + network to which the first network interface belongs to. + +.. note:: + + The kolla_base_distro and kolla_install_type should be same as base and + install_type used in kolla-build command line. + +The ``network_interface`` variable is the interface to which Kolla binds API +services. For example, when starting Mariadb, it will bind to the IP on the +interface list in the ``network_interface`` variable. + +:: + + network_interface: "ens3" + +The ``neutron_external_interface`` variable is the interface that will be used +for the external bridge in Neutron. Without this bridge the deployment instance +traffic will be unable to access the rest of the Internet. + +:: + + neutron_external_interface: "ens4" + +In case of deployment using the **nested** environment (eg. Using Virtualbox +VM’s, KVM VM’s), verify if your compute node supports hardware acceleration for +virtual machines by executing the following command in the *compute node*. + +:: + + egrep -c '(vmx|svm)' /proc/cpuinfo + +If this command returns a value of **zero**, your compute node does not support +hardware acceleration and you **must** configure libvirt to use **QEMU** +instead of KVM. Create a file /etc/kolla/config/nova/nova-compute.conf and add +the content shown below. + +:: + + mkdir -p /etc/kolla/config/nova + cat << EOF > /etc/kolla/config/nova/nova-compute.conf + [libvirt] + virt_type = qemu + cpu_mode = none + EOF + +For *all-in-one* deployments, the following commands can be run. These will +setup all of the containers on the localhost. These commands will be +wrapped in the kolla-script in the future. + +.. note:: Even for all-in-one installs it is possible to use the Docker + registry for deployment, although not strictly required. + +First, validate that the deployment targets are in a state where Kolla may +deploy to them. Provide the correct path to inventory file in the following +commands. + +:: + + kolla-ansible prechecks -i /path/to/all-in-one + +Deploy OpenStack. + +:: + + kolla-ansible deploy -i /path/to/all-in-one + +List the running containers. + +:: + + docker ps -a + +Generate the ``admin-openrc.sh`` file. The file will be created in +``/etc/kolla/`` directory. + +:: + + kolla-ansible post-deploy + +To test your deployment, run the following commands to initialize the network +with a glance image and neutron networks. + +:: + + . /etc/kolla/admin-openrc.sh + + #centOS + cd /usr/share/kolla-ansible + ./init-runonce + + #ubuntu + cd /usr/local/share/kolla-ansible + ./init-runonce + +.. note:: + + Different hardware results in variance with deployment times. + +After successful deployment of OpenStack, the Horizon dashboard will be +available by entering IP address or hostname from ``kolla_external_fqdn``, or +``kolla_internal_fqdn``. If these variables were not set during deploy they +default to ``kolla_internal_vip_address``. + +.. _Docker Hub Image Registry: https://hub.docker.com/u/kolla/ +.. _launchpad bug: https://bugs.launchpad.net/kolla/+filebug +.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/source/user/security.rst b/doc/source/user/security.rst new file mode 100644 index 000000000..f14dabaeb --- /dev/null +++ b/doc/source/user/security.rst @@ -0,0 +1,56 @@ +.. _security: + +============== +Kolla Security +============== + +Non Root containers +=================== +The OpenStack services, with a few exceptions, run as non root inside of +Kolla's containers. Kolla uses the Docker provided USER flag to set the +appropriate user for each service. + +SELinux +======= +The state of SELinux in Kolla is a work in progress. The short answer is you +must disable it until selinux polices are written for the Docker containers. + +To understand why Kolla needs to set certain selinux policies for services that +you wouldn't expect to need them (rabbitmq, mariadb, glance, etc.) we must take +a step back and talk about Docker. + +Docker has not had the concept of persistent containerized data until recently. +This means when a container is run the data it creates is destroyed when the +container goes away, which is obviously no good in the case of upgrades. + +It was suggested data containers could solve this issue by only holding data if +they were never recreated, leading to a scary state where you could lose access +to your data if the wrong command was executed. The real answer to this problem +came in Docker 1.9 with the introduction of named volumes. You could now +address volumes directly by name removing the need for so called **data +containers** all together. + +Another solution to the persistent data issue is to use a host bind mount which +involves making, for sake of example, host directory ``var/lib/mysql`` +available inside the container at ``var/lib/mysql``. This absolutely solves the +problem of persistent data, but it introduces another security issue, +permissions. With this host bind mount solution the data in ``var/lib/mysql`` +will be owned by the mysql user in the container. Unfortunately, that mysql +user in the container could have any UID/GID and thats who will own the data +outside the container introducing a potential security risk. Additionally, this +method dirties the host and requires host permissions to the directories to +bind mount. + +The solution Kolla chose is named volumes. + +Why does this matter in the case of selinux? Kolla does not run the process it +is launching as root in most cases. So glance-api is run as the glance user, +and mariadb is run as the mysql user, and so on. When mounting a named volume +in the location that the persistent data will be stored it will be owned by the +root user and group. The mysql user has no permissions to write to this folder +now. What Kolla does is allow a select few commands to be run with sudo as the +mysql user. This allows the mysql user to chown a specific, explicit directory +and store its data in a named volume without the security risk and other +downsides of host bind mounts. The downside to this is selinux blocks those +sudo commands and it will do so until we make explicit policies to allow those +operations. diff --git a/doc/source/user/troubleshooting.rst b/doc/source/user/troubleshooting.rst new file mode 100644 index 000000000..b7a120d3d --- /dev/null +++ b/doc/source/user/troubleshooting.rst @@ -0,0 +1,97 @@ +.. troubleshooting: + +===================== +Troubleshooting Guide +===================== + +Failures +======== + +If Kolla fails, often it is caused by a CTRL-C during the deployment +process or a problem in the ``globals.yml`` configuration. + +To correct the problem where Operators have a misconfigured environment, the +Kolla community has added a precheck feature which ensures the deployment +targets are in a state where Kolla may deploy to them. To run the prechecks, +execute: + +:: + + kolla-ansible prechecks + +If a failure during deployment occurs it nearly always occurs during evaluation +of the software. Once the Operator learns the few configuration options +required, it is highly unlikely they will experience a failure in deployment. + +Deployment may be run as many times as desired, but if a failure in a +bootstrap task occurs, a further deploy action will not correct the problem. +In this scenario, Kolla's behavior is undefined. + +The fastest way during to recover from a deployment failure is to +remove the failed deployment: + +:: + + kolla-ansible destroy -i <> + +Any time the tags of a release change, it is possible that the container +implementation from older versions won't match the Ansible playbooks in a new +version. If running multinode from a registry, each node's Docker image cache +must be refreshed with the latest images before a new deployment can occur. To +refresh the docker cache from the local Docker registry: + +:: + + kolla-ansible pull + +Debugging Kolla +=============== + +The status of containers after deployment can be determined on the deployment +targets by executing: + +:: + + docker ps -a + +If any of the containers exited, this indicates a bug in the container. Please +seek help by filing a `launchpad bug`_ or contacting the developers via IRC. + +The logs can be examined by executing: + +:: + + docker exec -it fluentd bash + +The logs from all services in all containers may be read from +``/var/log/kolla/SERVICE_NAME`` + +If the stdout logs are needed, please run: + +:: + + docker logs + +Note that most of the containers don't log to stdout so the above command will +provide no information. + +To learn more about Docker command line operation please refer to `Docker +documentation `__. + +When ``enable_central_logging`` is enabled, to view the logs in a web browser +using Kibana, go to: + +:: + + http://: + or http://: + +and authenticate using ```` and ````. + +The values ````, ```` +```` and ```` can be found in +``/kolla/ansible/group_vars/all.yml`` or if the default +values are overridden, in ``/etc/kolla/globals.yml``. The value of +```` can be found in ``/etc/kolla/passwords.yml``. + +.. _launchpad bug: https://bugs.launchpad.net/kolla-ansible/+filebug diff --git a/doc/swift-guide.rst b/doc/swift-guide.rst deleted file mode 100644 index f4339cc72..000000000 --- a/doc/swift-guide.rst +++ /dev/null @@ -1,192 +0,0 @@ -.. _swift-guide: - -============== -Swift in Kolla -============== - -Overview -======== -Kolla can deploy a full working Swift setup in either a **all-in-one** or -**multinode** setup. - -Disks with a partition table (recommended) -========================================== - -Swift requires block devices to be available for storage. To prepare a disk -for use as a Swift storage device, a special partition name and filesystem -label need to be added. - -The following should be done on each storage node, the example is shown -for three disks: - -:: - - # - index=0 - for d in sdc sdd sde; do - parted /dev/${d} -s -- mklabel gpt mkpart KOLLA_SWIFT_DATA 1 -1 - sudo mkfs.xfs -f -L d${index} /dev/${d}1 - (( index++ )) - done - -For evaluation, loopback devices can be used in lieu of real disks: - -:: - - index=0 - for d in sdc sdd sde; do - free_device=$(losetup -f) - fallocate -l 1G /tmp/$d - losetup $free_device /tmp/$d - parted $free_device -s -- mklabel gpt mkpart KOLLA_SWIFT_DATA 1 -1 - sudo mkfs.xfs -f -L d${index} ${free_device}p1 - (( index++ )) - done - -Disks without a partition table -=============================== - -Kolla also supports unpartitioned disk (filesystem on ``/dev/sdc`` instead of -``/dev/sdc1``) detection purely based on filesystem label. This is generally -not a recommended practice but can be helpful for Kolla to take over Swift -deployment already using disk like this. - -Given hard disks with labels swd1, swd2, swd3, use the following settings in -``ansible/roles/swift/defaults/main.yml``. - -:: - - swift_devices_match_mode: "prefix" - swift_devices_name: "swd" - -Rings -===== - -Before running Swift we need to generate **rings**, which are binary compressed -files that at a high level let the various Swift services know where data is in -the cluster. We hope to automate this process in a future release. - -The following example commands should be run from the ``operator`` node to -generate rings for a demo setup. The commands work with **disks with partition -table** example listed above. Please modify accordingly if your setup is -different. - -:: - - STORAGE_NODES=(192.168.0.2 192.168.0.3 192.168.0.4) - KOLLA_SWIFT_BASE_IMAGE="kolla/oraclelinux-source-swift-base:4.0.0" - - mkdir -p /etc/kolla/config/swift - - # Object ring - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/object.builder create 10 3 1 - - for node in ${STORAGE_NODES[@]}; do - for i in {0..2}; do - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/object.builder add r1z1-${node}:6000/d${i} 1; - done - done - - # Account ring - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/account.builder create 10 3 1 - - for node in ${STORAGE_NODES[@]}; do - for i in {0..2}; do - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/account.builder add r1z1-${node}:6001/d${i} 1; - done - done - - # Container ring - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/container.builder create 10 3 1 - - for node in ${STORAGE_NODES[@]}; do - for i in {0..2}; do - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/container.builder add r1z1-${node}:6002/d${i} 1; - done - done - - for ring in object account container; do - docker run \ - --rm \ - -v /etc/kolla/config/swift/:/etc/kolla/config/swift/ \ - $KOLLA_SWIFT_BASE_IMAGE \ - swift-ring-builder \ - /etc/kolla/config/swift/${ring}.builder rebalance; - done - -For more info, see -https://docs.openstack.org/project-install-guide/object-storage/ocata/initial-rings.html - -Deploying -========= -Enable Swift in ``/etc/kolla/globals.yml``: - -:: - - enable_swift : "yes" - -Once the rings are in place, deploying Swift is the same as any other Kolla -Ansible service: - -:: - - kolla-ansible deploy -i - -Validation -========== -A very basic smoke test: - -:: - - $ swift stat - Account: AUTH_4c19d363b9cf432a80e34f06b1fa5749 - Containers: 1 - Objects: 0 - Bytes: 0 - Containers in policy "policy-0": 1 - Objects in policy "policy-0": 0 - Bytes in policy "policy-0": 0 - X-Account-Project-Domain-Id: default - X-Timestamp: 1440168098.28319 - X-Trans-Id: txf5a62b7d7fc541f087703-0055d73be7 - Content-Type: text/plain; charset=utf-8 - Accept-Ranges: bytes - - $ swift upload mycontainer README.rst - README.md - - $ swift list - mycontainer - - $ swift download mycontainer README.md - README.md [auth 0.248s, headers 0.939s, total 0.939s, 0.006 MB/s] diff --git a/doc/tacker-guide.rst b/doc/tacker-guide.rst deleted file mode 100644 index 72b341d4a..000000000 --- a/doc/tacker-guide.rst +++ /dev/null @@ -1,168 +0,0 @@ -Tacker in Kolla -=============== - -"Tacker is an OpenStack service for NFV Orchestration with -a general purpose VNF Manager to deploy and operate -Virtual Network Functions (VNFs) and Network Services -on an NFV Platform. -It is based on ETSI MANO Architectural Framework." [1]. - -Overview --------- - -As of the Pike release, tacker requires the following services -to be enabled to operate correctly. - -* Core compute stack (nova, neutron, glance, etc) -* Heat -* Mistral + Redis -* Barbican (Required only for multinode) - -Optionally tacker supports the following services and features. - -* Aodh -* Ceilometer -* Networking-sfc -* Opendaylight - -Compatibility -------------- - -Tacker is supported by the following distros and install_types. - -* Centos, Redhat and Oraclelinux. - - * Source and binary images. - -* Debian and Ubuntu. - - * Only source images. - -Preparation and Deployment --------------------------- - -By default tacker and required services are disabled in -the ``group_vars/all.yml`` file. -In order to enable them, you need to edit the file -``/etc/kolla/globals.yml`` and set the following variables: - -.. note:: - - Heat is enabled by default, ensure it is not disabled. - -:: - - enable_tacker: "yes" - enable_barbican: "yes" - enable_mistral: "yes" - enable_redis: "yes" - -.. warning:: - - Barbican is required in multinode deployments to share VIM fernet_keys. - If not enabled, only one tacker-server host will have the keys on it - and any request made to a different tacker-server will fail with a - similar error as ``No such file or directory /etc/tacker/vim/fernet_keys`` - -Deploy tacker and related services. - -:: - - $ kolla-ansible deploy - -Verify ------- - -Generate the credentials file. - -:: - - $ kolla-ansible post-deploy - -Source credentials file. - -:: - - $ . /etc/kolla/admin-openrc.sh - -Create base neutron networks and glance images. - -:: - - $ sh tools/init-runonce - -.. note:: - - ``init-runonce`` file is located in ``$PYTHON_PATH/kolla-ansible`` - folder in kolla-ansible installation from pip. - -In kolla-ansible git repository a `tacker demo `_ -is present in ``kolla-ansible/contrib/demos/tacker/`` that will -create a very basic VNF from a cirros image in ``demo-net`` network. - -Install python-tackerclient. - -.. note:: - - Barbican, heat and mistral python clients are in tacker's - requirements and will be installed as dependency. - -:: - - $ pip install python-tackerclient - -Execute ``deploy-tacker-demo`` script to initialize the VNF creation. - -:: - - $ sh deploy-tacker-demo - -Tacker demo script will create sample VNF Descriptor (VNFD) file, -then register a default VIM, create a tacker VNFD and finally -deploy a VNF from the previously created VNFD. - - -After a few minutes, the tacker VNF is ACTIVE with a cirros instance -running in nova and with its corresponding heat stack CREATION_COMPLETE. - -Verify tacker VNF status is ACTIVE. - -:: - - $ tacker vnf-list - +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ - | id | name | mgmt_url | status | vim_id | vnfd_id | - +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ - | c52fcf99-101d-427b-8a2d-c9ef54af8b1d | kolla-sample-vnf | {"VDU1": "10.0.0.10"} | ACTIVE | eb3aa497-192c-4557-a9d7-1dff6874a8e6 | 27e8ea98-f1ff-4a40-a45c-e829e53b3c41 | - +--------------------------------------+------------------+-----------------------+--------+--------------------------------------+--------------------------------------+ - -Verify nova instance status is ACTIVE. - -:: - - $ openstack server list - +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ - | ID | Name | Status | Networks | Image | Flavor | - +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ - | d2d59eeb-8526-4826-8f1b-c50b571395e2 | ta-cf99-101d-427b-8a2d-c9ef54af8b1d-VDU1-fchiv6saay7p | ACTIVE | demo-net=10.0.0.10 | cirros | tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-c52fcf99-101d-427b-8a2d-c9ef54af8b1d-VDU1_flavor-yl4bzskwxdkn | - +--------------------------------------+-------------------------------------------------------+--------+--------------------+--------+-----------------------------------------------------------------------------------------------------------------------+ - -Verify Heat stack status is CREATE_COMPLETE. - -:: - - $ openstack stack list - +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ - | ID | Stack Name | Project | Stack Status | Creation Time | Updated Time | - +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ - | 289a6686-70f6-4db7-aa10-ed169fe547a6 | tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-c52fcf99-101d-427b-8a2d-c9ef54af8b1d | 1243948e59054aab83dbf2803e109b3f | CREATE_COMPLETE | 2017-08-23T09:49:50Z | None | - +--------------------------------------+----------------------------------------------------------------------------------------------+----------------------------------+-----------------+----------------------+--------------+ - -After the correct functionality of tacker is verified, tacker demo -can be cleaned up executing ``cleanup-tacker`` script. - -:: - - $ sh cleanup-tacker - -[1] https://docs.openstack.org/tacker/latest/ diff --git a/doc/troubleshooting.rst b/doc/troubleshooting.rst deleted file mode 100644 index b7a120d3d..000000000 --- a/doc/troubleshooting.rst +++ /dev/null @@ -1,97 +0,0 @@ -.. troubleshooting: - -===================== -Troubleshooting Guide -===================== - -Failures -======== - -If Kolla fails, often it is caused by a CTRL-C during the deployment -process or a problem in the ``globals.yml`` configuration. - -To correct the problem where Operators have a misconfigured environment, the -Kolla community has added a precheck feature which ensures the deployment -targets are in a state where Kolla may deploy to them. To run the prechecks, -execute: - -:: - - kolla-ansible prechecks - -If a failure during deployment occurs it nearly always occurs during evaluation -of the software. Once the Operator learns the few configuration options -required, it is highly unlikely they will experience a failure in deployment. - -Deployment may be run as many times as desired, but if a failure in a -bootstrap task occurs, a further deploy action will not correct the problem. -In this scenario, Kolla's behavior is undefined. - -The fastest way during to recover from a deployment failure is to -remove the failed deployment: - -:: - - kolla-ansible destroy -i <> - -Any time the tags of a release change, it is possible that the container -implementation from older versions won't match the Ansible playbooks in a new -version. If running multinode from a registry, each node's Docker image cache -must be refreshed with the latest images before a new deployment can occur. To -refresh the docker cache from the local Docker registry: - -:: - - kolla-ansible pull - -Debugging Kolla -=============== - -The status of containers after deployment can be determined on the deployment -targets by executing: - -:: - - docker ps -a - -If any of the containers exited, this indicates a bug in the container. Please -seek help by filing a `launchpad bug`_ or contacting the developers via IRC. - -The logs can be examined by executing: - -:: - - docker exec -it fluentd bash - -The logs from all services in all containers may be read from -``/var/log/kolla/SERVICE_NAME`` - -If the stdout logs are needed, please run: - -:: - - docker logs - -Note that most of the containers don't log to stdout so the above command will -provide no information. - -To learn more about Docker command line operation please refer to `Docker -documentation `__. - -When ``enable_central_logging`` is enabled, to view the logs in a web browser -using Kibana, go to: - -:: - - http://: - or http://: - -and authenticate using ```` and ````. - -The values ````, ```` -```` and ```` can be found in -``/kolla/ansible/group_vars/all.yml`` or if the default -values are overridden, in ``/etc/kolla/globals.yml``. The value of -```` can be found in ``/etc/kolla/passwords.yml``. - -.. _launchpad bug: https://bugs.launchpad.net/kolla-ansible/+filebug diff --git a/doc/vagrant-dev-env.rst b/doc/vagrant-dev-env.rst deleted file mode 100644 index 9c9a0c075..000000000 --- a/doc/vagrant-dev-env.rst +++ /dev/null @@ -1,190 +0,0 @@ -.. vagrant-dev-env: - -==================================== -Development Environment with Vagrant -==================================== - -This guide describes how to use `Vagrant `__ to assist in -developing for Kolla. - -Vagrant is a tool to assist in scripted creation of virtual machines. Vagrant -takes care of setting up CentOS-based VMs for Kolla development, each with -proper hardware like memory amount and number of network interfaces. - -Getting Started -=============== - -The Vagrant script implements **all-in-one** or **multi-node** deployments. -**all-in-one** is the default. - -In the case of **multi-node** deployment, the Vagrant setup builds a cluster -with the following nodes by default: - -* 3 control nodes -* 1 compute node -* 1 storage node (Note: ceph requires at least 3 storage nodes) -* 1 network node -* 1 operator node - -The cluster node count can be changed by editing the Vagrantfile. - -Kolla runs from the operator node to deploy OpenStack. - -All nodes are connected with each other on the secondary NIC. The primary NIC -is behind a NAT interface for connecting with the Internet. The third NIC is -connected without IP configuration to a public bridge interface. This may be -used for Neutron/Nova to connect to instances. - -Start by downloading and installing the Vagrant package for the distro of -choice. Various downloads can be found at the `Vagrant downloads -`__. - -Install required dependencies as follows: - -On CentOS:: - - sudo yum install ruby-devel libvirt-devel zlib-devel libpng-devel gcc \ - qemu-kvm qemu-img libvirt libvirt-python libvirt-client virt-install \ - bridge-utils - -On Ubuntu 16.04 or later:: - - sudo apt-get install vagrant ruby-dev ruby-libvirt python-libvirt libvirt-dev nfs-kernel-server zlib1g-dev libpng12-dev gcc git - -.. note:: Many distros ship outdated versions of Vagrant by default. When in - doubt, always install the latest from the downloads page above. - -Next install the hostmanager plugin so all hosts are recorded in ``/etc/hosts`` -(inside each vm):: - - vagrant plugin install vagrant-hostmanager - -If you are going to use VirtualBox, then install vagrant-vbguest:: - - vagrant plugin install vagrant-vbguest - -Vagrant supports a wide range of virtualization technologies. If VirtualBox is -used, the vbguest plugin will be required to install the VirtualBox Guest -Additions in the virtual machine:: - - vagrant plugin install vagrant-vbguest - -This documentation focuses on libvirt specifics. To install vagrant-libvirt -plugin:: - - vagrant plugin install --plugin-version ">= 0.0.31" vagrant-libvirt - -Some Linux distributions offer vagrant-libvirt packages, but the version they -provide tends to be too old to run Kolla. A version of >= 0.0.31 is required. - -To use libvirt from Vagrant with a low privileges user without being asked for -a password, add the user to the libvirt group:: - - sudo gpasswd -a ${USER} libvirt - newgrp libvirt - -Setup NFS to permit file sharing between host and VMs. Contrary to the rsync -method, NFS allows both way synchronization and offers much better performance -than VirtualBox shared folders. On CentOS:: - - # Add the virtual interfaces to the internal zone - sudo firewall-cmd --zone=internal --add-interface=virbr0 - sudo firewall-cmd --zone=internal --add-interface=virbr1 - # Enable nfs, rpc-bind and mountd services for firewalld - sudo firewall-cmd --permanent --zone=internal --add-service=nfs - sudo firewall-cmd --permanent --zone=internal --add-service=rpc-bind - sudo firewall-cmd --permanent --zone=internal --add-service=mountd - sudo firewall-cmd --permanent --zone=internal --add-port=2049/udp - sudo firewall-cmd --permanent --add-port=2049/tcp - sudo firewall-cmd --permanent --add-port=111/udp - sudo firewall-cmd --permanent --add-port=111/tcp - sudo firewall-cmd --reload - # Start required services for NFS - sudo systemctl restart firewalld - sudo systemctl start nfs-server - sudo systemctl start rpcbind.service - -Ensure your system has libvirt and associated software installed and setup -correctly. On CentOS:: - - sudo systemctl start libvirtd - sudo systemctl enable libvirtd - -Find a location in the system's home directory and checkout Kolla repos:: - - git clone https://git.openstack.org/openstack/kolla-ansible - git clone https://git.openstack.org/openstack/kolla - -Both repos must share the same parent directory so the bootstrap code can -locate them. - -Developers can now tweak the Vagrantfile or bring up the default **all-in-one** -CentOS 7-based environment:: - - cd kolla-ansible/contrib/dev/vagrant && vagrant up - -The command ``vagrant status`` provides a quick overview of the VMs composing -the environment. - -Vagrant Up -========== - -Once Vagrant has completed deploying all nodes, the next step is to launch -Kolla. First, connect with the **operator** node:: - - vagrant ssh operator - -To speed things up, there is a local registry running on the operator. All -nodes are configured so they can use this insecure repo to pull from, and use -it as a mirror. Ansible may use this registry to pull images from. - -All nodes have a local folder shared between the group and the hypervisor, and -a folder shared between **all** nodes and the hypervisor. This mapping is lost -after reboots, so make sure to use the command ``vagrant reload `` when -reboots are required. Having this shared folder provides a method to supply -a different Docker binary to the cluster. The shared folder is also used to -store the docker-registry files, so they are save from destructive operations -like ``vagrant destroy``. - -Building images ---------------- - -Once logged on the **operator** VM call the ``kolla-build`` utility:: - - kolla-build - -``kolla-build`` accept arguments as documented in `Building Container Images`_. -It builds Docker images and pushes them to the local registry if the **push** -option is enabled (in Vagrant this is the default behaviour). - -Deploying OpenStack with Kolla ------------------------------- - -Deploy **all-in-one** with:: - - sudo kolla-ansible deploy - -Deploy multinode -On Centos 7:: - - sudo kolla-ansible deploy -i /usr/share/kolla-ansible/ansible/inventory/multinode - -On Ubuntu 16.04 or later:: - - sudo kolla-ansible deploy -i /usr/local/share/kolla-ansible/ansible/inventory/multinode - -Validate OpenStack is operational:: - - kolla-ansible post-deploy - . /etc/kolla/admin-openrc.sh - openstack user list - -Or navigate to http://172.28.128.254/ with a web browser. - -Further Reading -=============== - -All Vagrant documentation can be found at -`docs.vagrantup.com `__. - -.. _Building Container Images: https://docs.openstack.org/kolla/latest/image-building.html diff --git a/doc/vmware-guide.rst b/doc/vmware-guide.rst deleted file mode 100644 index 1b4ab108b..000000000 --- a/doc/vmware-guide.rst +++ /dev/null @@ -1,251 +0,0 @@ -.. _vmware-guide: - -==================== -VMware in Kolla -==================== - -Overview -======== -Kolla can deploy the Nova and Neutron Service(s) for VMware vSphere. -Depending on the network architecture (NsxV or DVS) you choose, Kolla deploys -the following OpenStack services for VMware vSphere: - -For VMware NsxV: - -* nova-compute -* neutron-server - -For VMware DVS: - -* nova-compute -* neutron-server -* neutron-dhcp-agent -* neutron-metadata-agent - -Kolla can deploy the Glance and Cinder services using VMware datastore as their -backend. Ceilometer metering for vSphere is also supported. - -Because the `vmware-nsx `__ drivers for -neutron use completely different architecture than other types of -virtualization, vmware-nsx drivers cannot coexist with other type -of virtualization in one region. In neutron vmware-nsx drivers, -neutron-server acts like an agent to translate OpenStack actions -into what vSphere/NSX Manager API can understand. Neutron does -not directly takes control of the Open vSwitch inside the VMware -environment but through the API exposed by vSphere/NSX Manager. - -For VMware DVS, the Neutron DHCP agent does not attaches to Open vSwitch inside -VMware environment, but attach to the Open vSwitch bridge called ``br-dvs`` on -the OpenStack side and replies to/receives DHCP packets through VLAN. Similar -to what the DHCP agent does, Neutron metadata agent attaches to ``br-dvs`` -bridge and works through VLAN. - -.. note:: - - VMware NSX-DVS plugin does not support tenant networks, so all VMs should - attach to Provider VLAN/Flat networks. - -VMware NSX-V -============ - -Preparation ------------ - -You should have a working NSX-V environment, this part is out of scope -of Kolla. -For more information, please see `VMware NSX-V documentation `__. - -.. note:: - - In addition, it is important to modify the firewall rule of vSphere to make - sure that VNC is accessible from outside VMware environment. - - On every VMware host, edit /etc/vmware/firewall/vnc.xml as below: - -.. code-block:: console - - - - - VNC - - inbound - tcp - dst - - 5900 - 5999 - - - - outbound - tcp - dst - - 0 - 65535 - - - true - false - - - -Then refresh the firewall config by: - -.. code-block:: console - - esxcli network firewall refresh - -Verify that the firewall config is applied: - -.. code-block:: console - - esxcli network firewall ruleset list - -Deployment ----------- - -Enable VMware nova-compute plugin and NSX-V neutron-server plugin in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - nova_compute_virt_type: "vmware" - neutron_plugin_agent: "vmware_nsxv" - -.. note:: - - VMware NSX-V also supports Neutron FWaaS, LBaaS and VPNaaS services, you can enable - them by setting these options in globals.yml: - - * enable_neutron_vpnaas: "yes" - * enable_neutron_lbaas: "yes" - * enable_neutron_fwaas: "yes" - -If you want to set VMware datastore as cinder backend, enable it in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_cinder: "yes" - cinder_backend_vmwarevc_vmdk: "yes" - vmware_datastore_name: "TestDatastore" - -If you want to set VMware datastore as glance backend, enable it in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - glance_backend_vmware: "yes" - vmware_vcenter_name: "TestDatacenter" - vmware_datastore_name: "TestDatastore" - -VMware options are required in ``/etc/kolla/globals.yml``, these options should -be configured correctly according to your NSX-V environment. - -Options for nova-compute and ceilometer: - -.. code-block:: console - - vmware_vcenter_host_ip: "127.0.0.1" - vmware_vcenter_host_username: "admin" - vmware_vcenter_host_password: "admin" - vmware_vcenter_cluster_name: "cluster-1" - vmware_vcenter_insecure: "True" - vmware_vcenter_datastore_regex: ".*" - -Options for Neutron NSX-V support: - -.. code-block:: console - - vmware_nsxv_user: "nsx_manager_user" - vmware_nsxv_password: "nsx_manager_password" - vmware_nsxv_manager_uri: "https://127.0.0.1" - vmware_nsxv_cluster_moid: "TestCluster" - vmware_nsxv_datacenter_moid: "TestDataCeter" - vmware_nsxv_resource_pool_id: "TestRSGroup" - vmware_nsxv_datastore_id: "TestDataStore" - vmware_nsxv_external_network: "TestDVSPort-Ext" - vmware_nsxv_vdn_scope_id: "TestVDNScope" - vmware_nsxv_dvs_id: "TestDVS" - vmware_nsxv_backup_edge_pool: "service:compact:1:2" - vmware_nsxv_spoofguard_enabled: "false" - vmware_nsxv_metadata_initializer: "false" - vmware_nsxv_edge_ha: "false" - - -.. note:: - - If you want to set secure connections to VMware, set ``vmware_vcenter_insecure`` - to false. - Secure connections to vCenter requires a CA file, copy the vCenter CA file to - ``/etc/kolla/config/vmware_ca``. - - -Then you should start kolla-ansible deployment normally as KVM/QEMU deployment. - - -VMware NSX-DVS -============== - -Preparation ------------ - -Before deployment, you should have a working VMware vSphere environment. -Create a cluster and a vSphere Distributed Switch with all the host in the -cluster attached to it. - -For more information, please see `Setting Up Networking with vSphere Distributed Switches `__. - -Deployment ----------- - -Enable VMware nova-compute plugin and NSX-V neutron-server plugin in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - nova_compute_virt_type: "vmware" - neutron_plugin_agent: "vmware_dvs" - -If you want to set VMware datastore as Cinder backend, enable it in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - enable_cinder: "yes" - cinder_backend_vmwarevc_vmdk: "yes" - vmware_datastore_name: "TestDatastore" - -If you want to set VMware datastore as Glance backend, enable it in -``/etc/kolla/globals.yml``: - -.. code-block:: console - - glance_backend_vmware: "yes" - vmware_vcenter_name: "TestDatacenter" - vmware_datastore_name: "TestDatastore" - -VMware options are required in ``/etc/kolla/globals.yml``, these options should -be configured correctly according to the vSphere environment you installed -before. All option for nova, cinder, glance are the same as VMware-NSX, except -the following options. - -Options for Neutron NSX-DVS support: - -.. code-block:: console - - vmware_dvs_host_ip: "192.168.1.1" - vmware_dvs_host_port: "443" - vmware_dvs_host_username: "admin" - vmware_dvs_host_password: "password" - vmware_dvs_dvs_name: "VDS-1" - vmware_dvs_dhcp_override_mac: "" - -Then you should start kolla-ansible deployment normally as KVM/QEMU deployment. - -For more information on OpenStack vSphere, see -`VMware vSphere -`__, -`VMware-NSX package `_. diff --git a/doc/zun-guide.rst b/doc/zun-guide.rst deleted file mode 100644 index 647d95933..000000000 --- a/doc/zun-guide.rst +++ /dev/null @@ -1,113 +0,0 @@ -Zun in Kolla -============ - -"Zun is an OpenStack Container service. It aims to provide an -OpenStack API for provisioning and managing containerized -workload on OpenStack." [1]. - -Preparation and Deployment --------------------------- - -Zun requires kuryr and etcd services, for more information about how to -configure kuryr refer to `Kuryr Guide `_. - -To allow Zun Compute connect to the Docker Daemon, add the following in the -``docker.service`` file on each zun-compute node. - -:: - - ExecStart= -H tcp://:2375 -H unix:///var/run/docker.sock --cluster-store=etcd://:2379 --cluster-advertise=:2375 - -.. note:: - - ``DOCKER_SERVICE_IP`` is zun-compute host IP address. ``2375`` is port that - allows Docker daemon to be accessed remotely. - -By default zun is disabled in the ``group_vars/all.yml``. -In order to enable it, you need to edit the file globals.yml and set the -following variables: - -:: - - enable_zun: "yes" - enable_kuryr: "yes" - enable_etcd: "yes" - -Deploy the OpenStack cloud and zun. - -:: - - $ kolla-ansible deploy - -Verify ------- - -Generate the credentials file. - -:: - - $ kolla-ansible post-deploy - -Source credentials file. - -:: - - $ . /etc/kolla/admin-openrc.sh - -Download and create a glance container image. - -:: - - $ docker pull cirros - $ docker save cirros | openstack image create cirros --public \ - --container-format docker --disk-format raw - -Create zun container. - -:: - - $ zun create --name test --net network=demo-net cirros ping -c4 8.8.8.8 - -.. note:: - - Kuryr does not support networks with DHCP enabled, disable DHCP in the - subnet used for zun containers. - - :: - - openstack subnet set --no-dhcp - -Verify container is created. - -:: - - $ zun list - +--------------------------------------+------+---------------+---------+------------+------------+-------+ - | uuid | name | image | status | task_state | addresses | ports | - +--------------------------------------+------+---------------+---------+------------+------------+-------+ - | 3719a73e-5f86-47e1-bc5f-f4074fc749f2 | test | cirros | Created | None | 172.17.0.3 | [] | - +--------------------------------------+------+---------------+---------+------------+------------+-------+ - -Start container. - -:: - - $ zun start test - Request to start container test has been accepted. - -Verify container. - -:: - - $ zun logs test - PING 8.8.8.8 (8.8.8.8): 56 data bytes - 64 bytes from 8.8.8.8: seq=0 ttl=45 time=96.396 ms - 64 bytes from 8.8.8.8: seq=1 ttl=45 time=96.504 ms - 64 bytes from 8.8.8.8: seq=2 ttl=45 time=96.721 ms - 64 bytes from 8.8.8.8: seq=3 ttl=45 time=95.884 ms - - --- 8.8.8.8 ping statistics --- - 4 packets transmitted, 4 packets received, 0% packet loss - round-trip min/avg/max = 95.884/96.376/96.721 ms - -[1] https://github.com/openstack/zun diff --git a/setup.cfg b/setup.cfg index fd08580ff..35ab12625 100644 --- a/setup.cfg +++ b/setup.cfg @@ -53,7 +53,7 @@ setup-hooks = [build_sphinx] all_files = 1 build-dir = doc/build -source-dir = doc +source-dir = doc/source warning-is-error = 1 [build_releasenotes] -- cgit v1.2.3