Reconfigure a single service¶
Impact Restarts on drift
What kolla-ansible reconfigure -t <svc> does in 2025.1 for one API service, with keystone as the command example:
after the gather-facts and group_by plays, which run on all hosts, the loadbalancer play runs on the loadbalancer hosts
(it rewrites the service's frontend file, and, changed in 2025.1, restarts nothing) and the service play on the
service hosts (the service's containers that drifted restart). As in 2024.1, common is its own play, tagged common
only, so a service tag does not run it. The page also says what a narrow tag touches besides the service, and what
changes on the first 2025.1 run of a cloud deployed by 2024.1.
The scenario sections are written for the assumed deployment; the page uses the conventions of the command sections, the definition of drift and the notion of code guarantees and environment dependence.
Note
Key answers
- What restarts (§1.1): the service's containers that drifted, on every host
at once: changed in 2025.1, there is no loop-notify any more, and
reconfigurealways runs withkolla_serial=0. To go host by host, usedeploy -e kolla_serial=Nor--limit. - HAProxy (§3): changed in 2025.1, a service
tag rewrites the frontend file but never restarts HAProxy; the new frontend is applied by the next run with
-t haproxy(or no tag), backups first and the VIP holder last. - First 2025.1 run on a 2024.1 cloud: a service that
kolla-ansible upgradehas not reached drifts on every host: its image tag changes, and the reconfigure skips the role's upgrade tasks; the systemd unit text changed (F16); with Docker outside the Red Hat family the default ulimits changed. Upgrade it first. - Keep the frontend file untouched:
--skip-tags haproxy(§1.2).
Warning
R8: a changed services.d/<svc>*.cfg restarts HAProxy on every loadbalancer host
(backups together, then the VIP holder) at the next -t haproxy or untagged run, not during the -t <svc> run that
wrote it — see §1.2 and
§3.
1. Commands¶
1.1 Reconfigure a single service¶
kolla-ansible reconfigure -i multinode -t keystone
reconfigure sets kolla_action=reconfigure and kolla_serial=0 (kolla_ansible/cli/commands.py:128-140).
- Scope:
- loadbalancer play: keystone frontend only, on the loadbalancer hosts (
site.yml:105-120; keystone includesite.yml:203-207, inside a block that runs only whenenable_haproxyis set andkolla_actionisdeploy,reconfigure,upgradeorconfig,site.yml:325-327); the final loadbalancer check step is skipped under a service tag (site.yml:319-324); - keystone play (
site.yml:498-510): config, check-containers, bootstrap (db sync), a handler flush (restarts happen here), Fernet key distribution, Keystone registration, and identity-provider registration whenenable_keystone_federationis true (roles/keystone/tasks/deploy.yml:2-21;reconfigure.ymlonly importsdeploy.yml). New in 2025.1: the role has acheck.yml, used only by the newkolla-ansible checkcommand.commondoes not run: it is its own play, taggedcommononly (site.yml:88-103). Unlike glance, placement, cinder, heat and neutron, which register first (e.g.roles/glance/tasks/deploy.yml:2), keystone registers last.
- loadbalancer play: keystone frontend only, on the loadbalancer hosts (
- Restarts:
- not haproxy: changed in 2025.1 (§3);
- per container: changed in 2025.1, the shared check step (
roles/keystone/tasks/check-containers.yml:2-3,roles/service-check-containers/tasks/main.yml:4-41) notifies the restart handler of each keystone container that drifted, and only of those (keystone,keystone_sshandkeystone_fernet, all threeenabled: trueunconditionally,roles/keystone/defaults/main.yml:6, :36, :49). Hosts without drift do not restart. Drifted hosts restart in parallel: the keystone play readsserial: '{{ kolla_serial|default("0") }}'(site.yml:503), andreconfigurealways passeskolla_serial=0after the user's-e(kolla_ansible/cli/commands.py:20-22, :136; F19), so a change common to all hosts (globals,keystone.conf, a new image) restarts the changed keystone containers on all keystone hosts at once. To stage it, runkolla-ansible deploy -t keystone -e kolla_serial=1, which runs the same tasks, or split the hosts with--limit.
- One-shot: the
bootstrap_keystonedb sync container, once (run_once,roles/keystone/tasks/bootstrap_service.yml:34-52); the Fernet bootstrap container only when no host runskeystone_fernet(:53-76). Fernet keys are re-distributed (roles/keystone/tasks/deploy.yml:15). - Impact: if restarted, keystone restarts on all drifted hosts at once; NOT AVAILABLE whether authentication fails meanwhile, and for how long (Risk register R19).
1.2 Avoid touching HAProxy during a service run¶
kolla-ansible reconfigure -i multinode -t nova --skip-tags haproxy
--skip-tags haproxydrops the whole loadbalancer play, including the per-service frontend includes:haproxyis a play tag (site.yml:115-118), inherited by every task of the play (Tags §2.1).- Changed in 2025.1: a service tag no longer restarts HAProxy in any case (Tags
§2.2), so
--skip-tags haproxynow only keeps the frontend file as it is. Use it when frontends are not meant to change, so that a later-t haproxyrun does not pick up a frontend change you did not intend.
2. Execute a service-specific tag: implicit effects¶
Even with a narrow tag, the code guarantees that the run also touches:
| Implicit effect | Mechanism | Evidence |
|---|---|---|
| HAProxy frontend files of the service, on all loadbalancer hosts; no HAProxy restart (changed in 2025.1) | loadbalancer play includes <svc>/ under the same tag; that file imports loadbalancer-config with tags: always, which imports haproxy-config (and proxysql-config when enable_proxysql). With haproxy_single_external_frontend (default false), the service's block of external-frontend-map is also written. Changed in 2025.1: these tasks notify no handler; the restart comes from the loadbalancer check-containers step at the end of the play, which carries only the play tags |
site.yml:105-327, roles/, roles/, roles/, site.yml:319-324; fact sheet A §1.9; Tags §2.2–2.3 |
common on every host of the service play: still not in 2025.1 |
No role has a meta/ directory (no meta dependency on common); common is a separate play on the cron, fluentd, kolla-logs and kolla-toolbox groups with tags: common, so it runs only under -t common or a run without tags |
site.yml:88-103, roles/; Tags §2.1 |
| Keystone registration (services, endpoints, projects, users, roles of those users, grants) | register.yml imports service-ks-register from deploy.yml, which reconfigure.yml imports |
roles/, roles/ |
DB creation/grants and DB schema sync for most services, Neutron included (its bootstrap_neutron container has no when, Reconfigure Neutron §2) |
bootstrap.yml imported by deploy.yml |
CODE 14 one-shot container runs on a no-change redeploy of this service set (cell0 mapped; MariaDB, RabbitMQ and Fernet keys already bootstrapped): 8 DB-sync bootstraps (keystone, glance, placement, nova API, nova cell, neutron, cinder, heat) + map_cell0 + list_cells for cell0 (roles/) + 2× list_cells, counted from each role's bootstrap_service.yml (roles/, roles/, roles/, roles/, roles/, roles/; nova: Reconfigure Nova §1.1, Tags §3), + new in 2025.1, the two libvirt image checks of nova-cell, libvirt_version_check and nova_libvirt_script_check, on the first compute (roles/, run from roles/ when enable_nova_libvirt_container) |
| RabbitMQ user/vhost (nova-cell only) | service-rabbitmq, imported from nova-cell/ |
roles/, roles/ |
Global MariaDB variable toggle (-t glance) |
log_bin_trust_function_creators 1→0 around the glance DB sync, unless use_preconfigured_databases |
roles/; fact sheet C §1 |
Fernet key redistribution (-t keystone) |
distribute_fernet.yml |
roles/; fact sheet B §3.6 (re-run on reconfigure: §3.7) |
Actions on hosts outside --limit |
delegate_to to groups[...][0]: Neutron DB bootstrap on neutron-server[0], cell discovery on conductor[0], RabbitMQ user creation on the first host of the cell's RPC (and notify) group, the libvirt image checks on the first compute |
roles/, bootstrap_service.yml:20-21; roles/, wait_discover_computes.yml:43; roles/, roles/; roles/; Add a compute node §2 |
SIGHUP to every nova-scheduler (-t nova/nova-api) |
refresh play, on deploy and reconfigure |
nova.yml:152-172 |
What a service tag does not do: it never touches MariaDB, RabbitMQ or memcached containers (other plays), never
the HAProxy, keepalived or ProxySQL containers (changed in 2025.1), and never OVS (unless -t openvswitch), nor the
common containers (fluentd, kolla_toolbox, cron). Under -t haproxy or a no-tag run, the loadbalancer role's
containers (HAProxy, keepalived, ProxySQL when enabled and haproxy_ssh when enable_letsencrypt is set,
roles/loadbalancer/defaults/main.yml:29-36) are checked, and that check also covers every frontend file written by
earlier service runs.
CODE -t haproxy reconfigure on an unchanged cloud: the loadbalancer role on the 2 loadbalancer hosts
(site.yml:105-120, inventory/multinode:84-85); common does not run (its play is tagged common only,
site.yml:88-103). Changed in 2025.1: the play holds 38 frontend include_role tasks, not 39 (swift is gone).
All 38 are evaluated; 12 run (placement's, which has no when, and the 11 whose condition is true for this service
set: cinder, glance, heat, horizon, keystone, mariadb, memcached, neutron, nova, nova-cell, rabbitmq) and the other 26
are skipped by their when (site.yml:122-318; defaults in group_vars/all.yml); then the loadbalancer
check-containers step runs (site.yml:319-324). Restarts follow only a container that the check reports changed
(Tags §2.4); NOT AVAILABLE whether any does on an unchanged
cloud.
3. Sequence, impact, risks and verification of -t <svc> reconfigure¶
For an API service such as keystone, glance, cinder, heat or placement:
- The gather-facts and group_by plays run on all hosts (
tags: always,site.yml:2-75). - loadbalancer play, on the loadbalancer hosts: only the
<svc>include runs and rendersservices.d/<svc>*.cfg. The loadbalancer role's own tasks and the finalcheck-containersstep carry only the play tags (haproxy,keepalived,loadbalancer), not the<svc>tag, so they are skipped CODE (site.yml:115-120, :319-324; Tags §2.3). Changed in 2025.1: nothing in this run restarts HAProxy, even if the file changed; the next-t haproxy(or untagged) run finds the difference throughkolla_set_configs --check(services.d/is copied into the container,roles/loadbalancer/templates/haproxy/haproxy.json.j2:17-18) and restarts HAProxy on every loadbalancer host, staged CODE: the hosts are grouped by whether they hold the VIP (roles/loadbalancer/handlers/main.yml:9-34); HAProxy stops and starts on all backups together and the play waits forhaproxy_monitor_port(:54-68,:90-119); then it stops and starts on the VIP holder and waits again (:181-195,:226-254) (R8; HAProxy + Keepalived). Whether the VIP moves meanwhile is NOT AVAILABLE. - Service play, on the service hosts: Keystone registration (
run_once) → config → check-containers → DB/user creation and the DB-sync container on the first host → flush (e.g.roles/glance/tasks/deploy.yml:2-15; placement runs its clone step before config,roles/placement/tasks/deploy.yml:2-14). Every drifted container restarts, on all hosts at once (kolla_serial=0). Keystone is the exception in order: it registers last (§1.1).
First 2025.1 run on a cloud deployed by 2024.1 CODE:
- If
kolla-ansible upgradehas not reached the service, its image changes:openstack_releasedefaults to2025.1(group_vars/all.yml:795-797), the check compares the image (module_utils/kolla_container_worker.py:75), and the handler recreates the container on the 2025.1 image (module_utils/kolla_docker_worker.py:352-372), through the deploy path, without the role's upgrade tasks (e.g.roles/keystone/tasks/upgrade.yml:23-34). Upgrade it first. - Every container whose unit no 2025.1 run has recreated or restarted yet drifts:
compare_containeralso compares the systemd unit text (module_utils/kolla_container_worker.py:58-65,module_utils/kolla_systemd_worker.py:155-168), and the 2025.1 template addsPartOf=kolla.target(module_utils/kolla_systemd_worker.py:27; F16). Akolla-ansible upgradethat recreated the service's containers already wrote the new units. - With Docker on hosts outside the Red Hat family,
default_container_dimensionsnow carries anofileulimit (group_vars/all.yml:201-224), which containers created by 2024.1 lack, so they differ and are recreated (Repository architecture §6). So the first run on a service not yet upgraded restarts or recreates it on all its hosts at once. -
Whether the frontend files of the services render differently under 2025.1 is NOT AVAILABLE (not rendered here); the diff of the verification below shows it.
-
Interruption: the service API is unavailable while its drifted containers restart on all drifted hosts at once. A config drift goes through a systemd
RestartUnitof the container's unit, a container drift (image, volumes, dimensions) through a stop, remove and start (module_utils/kolla_docker_worker.py:352-374,:426-442,:450-470;module_utils/kolla_systemd_worker.py:107-126). Either way the stop is the unit'sExecStop=/usr/bin/<engine> stop <name> -t <graceful_timeout>(module_utils/kolla_systemd_worker.py:33), withdocker_graceful_timeout, 60 s by default, passed throughdocker_common_options(group_vars/all.yml:148, :160): up to 60 s between SIGTERM and SIGKILL, then the start. - VM impact: these services restart none of the containers that Tags
§3.1 traces to running VMs
CODE; any other effect on VMs is NOT AVAILABLE. In-flight glance or cinder transfers are SIGKILLed if still
running
docker_graceful_timeout(60 s by default) after SIGTERM (R24). Of the tags in Tags §3.1, the ones that can restart those containers arenova,nova-cell,neutron,openvswitch,ovn(withovn-controllerandovn-db),iscsiandbaremetal(run bybootstrap-serversthroughopenstack.kolla.baremetal,kolla-host.yml:3-14, notreconfigure; Docker restart, R14) CODE; what those restarts do to running VMs is NOT AVAILABLE. Running on computes is not the test:commonruns on every compute (inventory/multinode:49-54, :202-212) but restarts only fluentd, kolla_toolbox and cron.chronystill has no role or play. - Risks: R8 (HAProxy restart at the next
-t haproxyrun), R19 (Keystone), R20 (glance file backend), R23 (--limiton a large inventory), R24 (SIGKILL afterdocker_graceful_timeout). - Verification:
- before: copy
/etc/kolla/haproxy/services.d/<svc>*.cfgfrom a loadbalancer host, runkolla-ansible genconfig -i multinode -t <svc>, thendocker exec -u root <c> /usr/local/bin/kolla_set_configs --check; echo $?in each<svc>container (without-u rootit exits 2 in images that run as a service user, e.g. glance-api; Kolla images §3.4) and diff the frontend against the copy; genconfigand the frontend CODE:genconfigruns withkolla_action=config(kolla_ansible/cli/commands.py:113-125), for which the loadbalancer block also runs (site.yml:325-327) and writesservices.d/<svc>*.cfg(roles/haproxy-config/tasks/main.yml:2-21), while the loadbalancer check step is skipped (site.yml:319-324). In 2025.1 a-t <svc> reconfiguredoes not apply the frontend either, with or withoutgenconfigfirst: the new frontend reaches HAProxy only through a-t haproxy reconfigure(or a run without tags). The service containers are not affected: their check step does run;- after:
openstack endpoint list --service <name>is unchanged for each Keystone service the role registers (eachnamein<svc>_ks_services, e.g.cinder(typeblock-storage, new in 2025.1) andcinderv3for cinder (roles/cinder/defaults/main.yml:346-359),heatandheat-cfnfor heat (roles/heat/defaults/main.yml:224-236)), the API answers through the VIP, and the container start times show which hosts restarted (kolla_container_enginedefaults todocker,group_vars/all.yml:100; with Podman, usepodman).
- before: copy
Related¶
- Risk register — the risks this page names: R8 (HAProxy
restart), R19 (Keystone), R20 (glance file backend),
R23 (
--limiton a large inventory), R24 (SIGKILL afterdocker_graceful_timeout) and R14 (Docker restart bybootstrap-servers) - Technical findings — F16 (the changed systemd unit
template, a cause of drift on the first 2025.1 run) and F19 (
reconfigurecannot be batched) - Keystone — service card and where to look for the service of the §1.1 example
- HAProxy + Keepalived — service card and where to look for HAProxy, including the staged restart order and the loadbalancer play under a service tag
- Pre-execution checklist — the checks before every production run
- Predict and inspect a run —
genconfigand the exit codes ofkolla_set_configs --check, used in the verification of §3 - Tags §2 — the semantics behind the implicit effects: tag inheritance, handlers that ignore tags, the haproxy play, the end of loop-notify
- Command quick lookup by tag — hosts touched, possible restarts and one-shot containers per tag
- 2024.1 reconfigure a single service — the same page for 2024.1
To remember
Lumo: if you keep only 5 things from this page, keep these.
- Changed in 2025.1: a service tag no longer restarts HAProxy.
-t <svc>rewritesservices.d/<svc>*.cfg, but only a run with-t haproxy(or no tag) applies it, with a staged HAProxy restart. CODE - Changed in 2025.1: only the containers that drifted restart, not all the service's containers on the host; and
reconfigurealways runs every host at once (kolla_serial=0), so a change common to all hosts restarts the service on all its hosts together. CODE - A service that
kolla-ansible upgradehas not reached drifts on every host on its first 2025.1 reconfigure: its image tag changes (and the reconfigure skips the role's upgrade tasks), its systemd unit lacksPartOf=kolla.target(F16), and with Docker outside the Red Hat family its ulimits differ. Upgrade it first. - The service API is unavailable while its containers restart, with up to
docker_graceful_timeout(60 s by default) between SIGTERM and SIGKILL. - To stage a service change host by host, use
deploy -e kolla_serial=1or--limit:reconfigure -e kolla_serial=1is overridden. CODE
What would you do?
Lumo: a situation you could meet on a real platform, and three ways to react. Pick the one you would choose: I will tell you what this page says about it. Nothing is recorded.
Check yourself
Lumo: 3 quick questions to check the main ideas of this page. Choose an answer to see the explanation and the section that gives the evidence. Your score counts your first choices and stays in this browser only.
Lumo: ready for the next step? Take your time: you can come back to this page whenever you need it.
Lumo: nicely done! One more page on your journey.