From bba3b6ab66cf28c3d68ad606ab8d84c3666213b6 Mon Sep 17 00:00:00 2001 From: Dmitriy Rabotyagov Date: Fri, 24 Dec 2021 17:06:28 +0200 Subject: [PATCH] [doc] Update infra node scaling documentation Closes-Bug: #1944046 Closes-Bug: #1944048 Depends-On: https://review.opendev.org/c/openstack/openstack-ansible-galera_server/+/822911 Change-Id: I78afbc0c8a9897d2e761ebde2fcf584ec1c0ac2c --- doc/source/admin/scale-environment.rst | 46 +++++++++++++++----------- 1 file changed, 27 insertions(+), 19 deletions(-) diff --git a/doc/source/admin/scale-environment.rst b/doc/source/admin/scale-environment.rst index 4a9f518d88..6621275147 100644 --- a/doc/source/admin/scale-environment.rst +++ b/doc/source/admin/scale-environment.rst @@ -24,42 +24,50 @@ needed in an environment, it is possible to create additional nodes. infra_hosts: [...] - NEW_infra: - ip: 10.17.136.32 - NEW_infra: - ip: 10.17.136.33 + infra: + ip: 10.17.136.32 #. Change to playbook folder on the deployment host. .. code:: console - # cd /opt/openstack-ansible/playbooks + # cd /opt/openstack-ansible -#. Update the inventory to add new hosts. Make sure new rsyslog - container names are updated. Send the updated results to ``dev/null``. +#. To prepare new hosts and deploy containers on them run ``setup-hosts.yml`` + playbook with the ``limit`` argument. .. code:: console - # /opt/openstack-ansible/inventory/dynamic_inventory.py > /dev/null + # openstack-ansible playbooks/setup-hosts.yml --limit localhost,infra,infra-host_containers + +#. Next we need to expand galera/rabbitmq clusters, which is done during + ``setup-infrastructure.yml``. So we will run this playbook without limits. + + .. warning:: + + Make sure that containers from new infra host *does not* appear in inventory + as first one for groups ``galera_all``, ``rabbitmq_all`` and ``repo_all``. + You can varify that with ad-hoc commands: + + .. code:: console + + # ansible -m debug -a "var=groups['galera_all'][0]" localhost + # ansible -m debug -a "var=groups['rabbitmq_all'][0]" localhost + # ansible -m debug -a "var=groups['repo_all'][0]" localhost -#. Create the ``/root/add_host.limit`` file, which contains all new node - host names and their containers. Add **localhost** to the list of - hosts to be able to access deployment host facts. .. code:: console - localhost - NEW_infra - NEW_infra - NEW_infra_containers - NEW_infra_containers + # openstack-ansible playbooks/setup-infrastructure.yml -e galera_force_bootstrap=true -#. Run the ``setup-everything.yml`` playbook with the - ``limit`` argument. +#. Once infrastructure playboks are done, it's turn of openstack services to be + deployed. Most of the services are fine to be ran with limits, but some, + like keystone, are not. So we run keystone playbook separately from all others: .. code:: console - # openstack-ansible setup-everything.yml --limit @/root/add_host.limit + # openstack-ansible playbooks/os-keystone-install.yml + # openstack-ansible playbooks/setup-openstack.yml --limit '!keystone_all',localhost,infra,infra-host_containers Test new infra nodes