Reconfigure Nova¶
Impact Restarts on drift
What kolla-ansible -t nova reconfigure does on the loadbalancer hosts, on the controllers and on every compute, with
the two narrower commands -t nova-api reconfigure (only the Nova control plane, no compute impact) and
-t nova-cell reconfigure (only the cell part: conductors, consoles, computes), and the batched form, which in 2025.1
is a deploy.
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
-t nova reconfigure(§2 to §6): every compute runs the tasks, all computes in one batch. Restarts happen only where drift is detected, and in 2025.1 only for the container that drifted: anova_computechange no longer restartsnova_libvirtandnova_ssh(§4). Whether running VMs survive anova_libvirtrestart is NOT AVAILABLE (§5).- Changed in 2025.1:
reconfigurecannot be batched. It always runs withkolla_serial=0; usedeploy -t nova -e kolla_serial=N(§1.4; F19). - First 2025.1 run after 2024.1: expect drift on every Nova container, computes included: the systemd unit text
changed (F16), the queue and catalog settings of
nova.confchanged (F17),nova_computegets acompute_idfile andnova_libvirta new command and new libvirt settings (§3). - New in 2025.1, every run needs the Nova API: each compute reads the hypervisor list through the first conductor,
in
genconfigtoo (F20). - Nova without touching computes:
-t nova-api reconfigure(§1.2).
Warning
R1: a change common to all computes restarts the drifted container on every compute in
the same handler step, since reconfigure cannot be batched — see
§4. For a change that touches
nova_libvirt, batch it with §1.4 or deploy-containers --limit.
1. Commands¶
1.1 Reconfigure Nova (control plane and computes)¶
kolla-ansible reconfigure -i multinode -t nova
- Scope:
- loadbalancer play: the nova and nova-cell frontend includes (
site.yml:252-265, inside a block that runs fordeploy,reconfigure,upgradeandconfigwhenenable_haproxyis set,site.yml:325-327). Changed in 2025.1: they writeservices.d/nova*.cfgbut HAProxy is not restarted under-t nova; the finalcheck-containersinclude of the loadbalancer play carries only its own play tags (F18); - the 10 nova plays (
nova.yml:29-302), the nova-cell play on every compute (nova.yml:125-147); commondoes not run under-t nova: it is its own play, taggedcommononly (site.yml:88-103).
- loadbalancer play: the nova and nova-cell frontend includes (
- One-shot: on
control01, the API DB sync,map_cell0,list_cellsfor cell0, the cell DB sync andlist_cells×2, plus RabbitMQ user/vhost, Keystone registration, SIGHUP ofnova_scheduleranddiscover_hostsCODE (when cell0 is mapped with an unchanged connection and the cell is unchanged:roles/nova/tasks/bootstrap.yml:53-56,roles/nova/tasks/map_cell0.yml:2-30,roles/nova-cell/tasks/bootstrap.yml:37-43,roles/nova-cell/tasks/create_cells.yml:2-4,roles/nova-cell/tasks/discover_computes.yml:4-18,roles/nova/tasks/deploy.yml:1). New in 2025.1: two one-shots from the newnova_libvirtimage on the first compute (libvirt_version_check,nova_libvirt_script_check,roles/nova-cell/tasks/version-check.yml:2-21,roles/nova-cell/tasks/version-check.yml:79-98), and a hypervisor list throughkolla_toolboxon the first conductor for every compute (roles/nova-cell/tasks/config.yml:59-73) CODE. - Restarts: only the containers whose check reports a change
(§3):
check-containers.ymlimportsservice-check-containers, which notifiesRestart <service> containerfor the changed items only (roles/nova-cell/tasks/check-containers.yml:2-3,roles/service-check-containers/tasks/main.yml:4-41; Tags §2.4) CODE. - Failures: seven of the ten plays set
max_fail_percentage(default 100, which never stops a play early); the cell DB bootstrap play and the two online-data-migration plays setany_errors_fatal: trueinstead (nova.yml:40-43,nova.yml:79,nova.yml:141-144,nova.yml:269-270,nova.yml:294-295) CODE. New in 2025.1: the libvirt version check fails the run when the newnova_libvirtimage carries an older libvirt than the running container, and the script check fails it when the image lackskolla_nova_libvirt_start(roles/nova-cell/tasks/version-check.yml:58-73,roles/nova-cell/tasks/version-check.yml:100-116).
1.2 Reconfigure only the Nova control plane (no compute impact)¶
kolla-ansible reconfigure -i multinode -t nova-api
- Scope: the
nova-api-tagged plays (API DB bootstrap, nova role, scheduler refresh, and the API reload and online-migration plays, which do nothing outsideupgrade) on controllers (nova.yml:29-65,nova.yml:103-122,nova.yml:152-172,nova.yml:180-201,nova.yml:231-277), plus the loadbalancer nova include (site.yml:252-258). The nova role now also managesnova_metadata, on the hosts that are in bothnova-metadataand one of the play's groups (roles/nova/defaults/main.yml:33-61,nova.yml:103-108). - Not touched: conductors and computes (
nova-cellplays,nova.yml:67-100,nova.yml:124-147).
1.3 Reconfigure only the cell part (conductors, consoles, computes)¶
kolla-ansible reconfigure -i multinode -t nova-cell
- Scope: the
nova-cell-tagged plays (cell DB bootstrap, nova-cell role, and the cell reload and online-migration plays, which do nothing outsideupgrade) (nova.yml:67-100,nova.yml:124-147,nova.yml:203-229,nova.yml:283-302), plus the loadbalancer nova-cell include for the console proxies (site.yml:259-265). The nova-cell play reaches every compute, as with-t nova, and runs the version checks and the hypervisor list.
1.4 A batched run: deploy with kolla_serial¶
kolla-ansible deploy -i multinode -t nova -e kolla_serial=10
- Why
deploy: new in 2025.1,reconfigureaddskolla_serial=0after your own-e(kolla_ansible/cli/commands.py:128-140), and the last value wins, soreconfigure -e kolla_serial=10still runs each play on all its hosts at once (F19). For the nova tags,deployruns the same tasks: both nova roles'reconfigure.ymlimportdeploy.yml, and the bootstrap and refresh plays act for both actions (roles/nova-cell/tasks/reconfigure.yml:2,nova.yml:53-55,nova.yml:89-91,nova.yml:170-172) (F5) CODE. - What batching repeats: the API DB sync and
map_cell0once per batch of the nova play when the controller groups are larger than the batch, the version checks and compute discovery once per batch of the nova-cell play (Write config first, apply in controlled batches §1.2; F10) CODE. - Stop on failures: set
nova_cell_max_fail_percentage(cell plays) orkolla_max_fail_percentagelower than 100 (nova.yml:141-144; Write config first, apply in controlled batches §1.3). - Alternative without bootstrap work:
genconfig, thendeploy-containers --limitper batch (Write config first, apply in controlled batches §2).
2. Execution sequence (kolla-ansible -t nova reconfigure)¶
sequenceDiagram
autonumber
participant HA as loadbalancer hosts
participant C1 as control01 (nova-api[0], conductor[0])
participant CT as all controllers
participant CP as all computes
Note over HA: loadbalancer play — nova + nova-cell includes only
HA->>HA: render services.d/nova*.cfg (no HAProxy restart under -t nova, F18)
Note over CT: Play 1 Bootstrap API DBs
C1->>C1: mysql_db/mysql_user (toolbox) · nova_api_bootstrap (db sync) · map_cell0 · list_cells (cell0)
Note over CT: Play 2 Bootstrap cell DBs (any_errors_fatal)
C1->>C1: cell DB/user · RabbitMQ vhost/user · nova_cell_bootstrap (cell db sync) · list_cells → update_cell if URLs changed
Note over CT: Play 3 nova role — register (keystone) · config · check · flush
CT->>CT: restart the changed api/metadata/scheduler/super-conductor containers (all controllers at once)
Note over CT,CP: Play 4 nova-cell — version checks · config-host · config · check · flush
CP->>CP: first compute: libvirt version and script one-shots (run_once)
CP->>C1: each compute: hypervisor list through kolla_toolbox (delegated) → compute_id
CT->>CT: restart the changed conductor/console containers (all controllers at once)
CP->>CP: restart the changed containers: nova_ssh → nova_libvirt (→ SASL user) → nova_compute (all computes at once)
CP->>C1: wait for compute registration · list_cells · discover_hosts (delegated)
Note over CT: Play 5 — kill -HUP nova_scheduler (always)
Note over CT,CP: Plays 6-10 — skipped (upgrade only)
Read from the 2025.1 code CODE: the loadbalancer includes render the frontends without notifying
(roles/nova/tasks/loadbalancer.yml:2-7, roles/haproxy-config/tasks/main.yml:2-21); play 1 (nova.yml:29-65;
roles/nova/tasks/bootstrap.yml:2-56, roles/nova/tasks/map_cell0.yml:2-67); play 2 (nova.yml:67-100;
roles/nova-cell/tasks/bootstrap.yml:2-43, roles/nova-cell/tasks/create_cells.yml:2-55); play 3
(nova.yml:103-122; roles/nova/tasks/deploy.yml:1-9); play 4 (nova.yml:125-147;
roles/nova-cell/tasks/deploy.yml:1-40, roles/nova-cell/tasks/version-check.yml:2-120,
roles/nova-cell/tasks/config.yml:53-110, roles/nova-cell/tasks/wait_discover_computes.yml:7-90,
roles/nova-cell/tasks/discover_computes.yml:4-23); play 5 (nova.yml:152-172;
roles/nova/tasks/refresh_scheduler_cell_cache.yml:4-12); plays 6 to 10 run their tasks only when kolla_action is
upgrade (nova.yml:199-201, :227-229, :251-253, :275-277, :300-302). reconfigure sets kolla_serial to
0, so each play takes all its hosts in one batch (kolla_ansible/cli/commands.py:136, nova.yml:140).
3. What changes, per type of change CODE¶
| Change | Files rewritten | Restarted on controllers | Restarted on every compute | Source |
|---|---|---|---|---|
| none | – | none unless a container check reports a change | none unless a container check reports a change | the config tasks of both roles no longer notify; service-check-containers notifies only the containers whose compare_container reported a change: a missing container, a differing compared parameter, a kolla_set_configs --check exit 1/137 or Docker client error, or a missing or different systemd unit file (roles/, module_utils/, module_utils/, module_utils/; Tags §3); NOT AVAILABLE whether every task reports unchanged on an unchanged cloud, and a config file that disappears from config.json makes the check report a change on every run (F21) |
| first 2025.1 run after 2024.1, no operator change (new in 2025.1) | nova.conf of every nova service (queue manager, transient quorum and stream options; catalog_info = block-storage::internalURL; on the API side www_authenticate_uri to the public URL); nova-compute/ and the new compute_id; nova-libvirt/ (new command), qemu.conf (stdio_handler = "logd"), libvirtd.conf (max_workers, max_client_requests); uWSGI files for nova_api; with Ceph, the libvirt secret XML |
every nova container (unit text, nova.conf); nova_metadata is created where the group exists |
nova_compute, nova_libvirt, nova_ssh, each through its own check | unit text: F16 (module_utils/, :155-168); queues: F17 (roles/, roles/); catalog: roles/, roles/; compute_id: F20 (roles/, roles/); libvirt: roles/, roles/, roles/; Nova deep dive §2.4. In an upgrade, the new images recreate the containers anyway |
/etc/ (global override) |
nova.conf of every nova service |
nova_api, nova_metadata, nova_scheduler, nova_super_conductor (with enable_cells), nova_conductor, the console proxies |
nova_compute (nova_libvirt and nova_ssh do not read nova.conf) |
both Copying over nova.conf loops merge {{ node_custom_config }}/ (roles/, roles/); which cell services get a nova.conf: nova_cell_services_require_nova_conf (roles/, roles/) |
/etc/ |
nova-compute/ only |
– | nova_compute only (2024.1: also nova_libvirt and nova_ssh, by loop-notify) | roles/, source at :129; Tags §2.4 |
/etc/ |
nova-compute/ of that host only |
– | nova_compute on that compute only | roles/; the nova role has a per-host nova.conf source but no per-host, per-service one (roles/) |
/etc/ |
nova-scheduler/ only |
nova_scheduler only (2024.1: also nova_api) | – | roles/; Tags §2.4 |
a libvirt setting (qemu.conf or libvirtd.conf override under /etc/) |
nova-libvirt/ or libvirtd.conf |
– | nova_libvirt (its kolla_set_configs --check reports the file) |
roles/; Nova deep dive §2.3 |
enable_barbican: yes (Barbican not even deployed) |
nova.conf everywhere (adds [barbican]). fluentd.conf and the cron logrotate config change too, but only when the common play runs (no tag or -t common), not under -t nova |
every nova container that reads nova.conf (fluentd and cron only at the next common run) |
nova_compute (same for fluentd and cron) | roles/, roles/; roles/, roles/, roles/; site.yml:88-103 |
same as the global nova.conf override, with deploy -e kolla_serial=1 |
same | one controller at a time | one compute at a time; API DB sync and map_cell0 repeated per batch (3×) |
nova.yml:39, :115, :140; roles/, roles/; Tags §2.5. With reconfigure, the value is overridden to 0 (F19) |
4. Are all compute nodes affected? Does nova-compute restart on every compute?¶
- Tasks: yes. The nova-cell play targets the whole
computegroup (nova.yml:125-147). Read from the 2025.1 task files, a no-change run makes 29 remote module invocations per compute and 36 on the first compute (default service set with Cinder LVM,kvm, Docker and a non-Ubuntu host); 2024.1 made 27 and 31. The additions are the container facts call of the version check, the hypervisor list (run on the first conductor) and thecompute_idcopy (Compute scaling §2). Its number of task results is NOT AVAILABLE. - Restarts: only where drift is detected, and only the drifted container. Most Nova-related changes are global
(Component dependencies §5, Nova deep dive
§2.3), so in
practice either no compute restarts it or all computes do, in the same handler step:
reconfigurecannot be batched (kolla_ansible/cli/commands.py:136,nova.yml:140; F19). Use §1.4 or--limitto spread it. - libvirt no longer goes with it. Changed in 2025.1 CODE: a
nova_computedrift restartsnova_computeonly;nova_libvirtrestarts when its own check reports a change (its files, its image, its container definition or unit), as at the first 2025.1 run (Tags §2.4). When several restart in the same flush, the handlers run in definition order:nova_ssh, thennova_libvirt, thennova_compute(roles/nova-cell/handlers/main.yml:70-158; ansible-core 2.18.20lib/ansible/executor/play_iterator.py:193-198,lib/ansible/executor/play_iterator.py:424-438). Withlibvirt_enable_sasl(defaulttrue,roles/nova-cell/defaults/main.yml:578), the libvirt handler also notifies a readiness check and the SASL user creation, defined before the nova-compute handler (roles/nova-cell/handlers/main.yml:90,roles/nova-cell/handlers/main.yml:108-133).
5. Running VMs, live migration, scheduling¶
| Effect | Guaranteed by code | Depends on environment |
|---|---|---|
nova-compute stop/start (stop with docker_graceful_timeout, 60 s by default, group_vars/) |
yes, when nova_compute drifts |
NOT AVAILABLE Whether VMs are unaffected, whether in-flight operations on that host fail or are left mid-task, and whether the service is reported down only if the restart exceeds service_down_time (Nova deep dive §5) |
| libvirtd stop/start | yes, when nova_libvirt drifts (no longer with every nova-compute drift) |
NOT AVAILABLE Whether VMs survive. CODE The container has pid_mode: host, cgroupns_mode: host, the host /run bind mount and /sys/fs/cgroup mounted rw (roles/, roles/, roles/), and the image's start scripts do nothing to QEMU, cgroups or /var/ (kolla docker/, docker/; Kolla images §5.1). New in 2025.1: virtlogd runs in the same container (roles/) and QEMU's console output goes through it (roles/); what happens to guest console logging across the restart is NOT AVAILABLE (Q22). The stop goes through the container's systemd unit kolla-<name>-container.service, whose ExecStop is /usr/; a restart of an unchanged container restarts that unit, a recreate stops it, removes the container and starts a new one (module_utils/, module_utils/, module_utils/, module_utils/). NOT AVAILABLE Whether live migrations in progress fail, and whether libvirt API calls fail until libvirtd is back |
| nova-ssh stop/start | yes, when nova_ssh drifts |
NOT AVAILABLE Whether resize or cold-migration disk copies over port 8022 (roles/) are interrupted |
| Scheduling | API, metadata and scheduler restarts are parallel on all controllers (serial 0, nova.yml:115) |
NOT AVAILABLE Whether API calls fail during the restart window. CODE The scheduler gets SIGHUP on every deploy or reconfigure run that reaches its hosts (cell-cache refresh, nova.yml:152-172, roles/); NOT AVAILABLE whether that is harmless |
| Metadata | nova_metadata restarts only when its own check reports a change (roles/) |
NOT AVAILABLE Whether instances that boot during its restart get their metadata |
| Host mapping | discover_hosts runs every time |
runs nova-manage cell_v2 discover_hosts --by-service to map newly registered computes (roles/, through kolla_container_engine exec -t nova_conductor); NOT AVAILABLE whether it affects existing instances |
6. Operational risks and verification¶
- Risks: R1, R2, R3, R24 in Risk register; after an upgrade from 2024.1, F16, F17 and F20.
- Before:
kolla-ansible genconfig -t nova(restarts nothing:kolla_actionisconfig,kolla_ansible/cli/commands.py:113-125, which runs each role'sconfig.ymlonly, whose tasks no longer notify,roles/nova-cell/tasks/main.yml:2), then diff/etc/kolla/nova-*/nova.confon one controller and one compute.genconfigstill reads the hypervisor list from the Nova API for every compute (F20).docker exec -u root nova_compute /usr/local/bin/kolla_set_configs --check; echo $?on a few computes (withkolla_container_engine: podman,podman exec), and the same innova_libvirt: exit 1 means that container will restart (Kolla images §3). The check does not see the unit-file drift of F16, which the module compares on the host (module_utils/kolla_container_worker.py:58-65).- No active live migrations:
openstack server list --all-projects --status MIGRATING.
- Apply in batches:
deploy-containers --limit(Write config first, apply in controlled batches §2) ordeploy -e kolla_serial=N(§1.4); notreconfigure, which ignoreskolla_serial(F19). - After:
openstack compute service list(all up);docker ps --filter name=nova_ -a(allUp, recentCreated/Startedonly where a change was expected);virsh list --allinsidenova_libvirton a sample of computes (domains running), with guest pings;nova-manage cell_v2 list_hostscount equals the number of computes;- after a run that restarted the controllers, a metadata request from an instance (the
nova_metadatacontainer).
- NOT AVAILABLE Confirmation that a
nova_compute-only change leavesnova_libvirtandnova_sshrunning, and the duration of a-t novarun with many computes; to be confirmed by the community.
Related¶
- Risk register — the risks this page names: R1 (any config
change touching nova-compute), R2 (fleet-wide restarts after an
enable_*change), R3 (changing RabbitMQ group membership, password or port) and R24 (container stop timeout:docker_graceful_timeout, 60 s by default) - Technical findings — F16 (the changed systemd unit),
F17 (queue settings), F19 (no batched
reconfigure) and F20 (compute_id) - Nova — service cards of the roles
novaandnova-cell, what changed in 2025.1, and where to look - Nova deep dive §5 — nova-libvirt: why its restart is special
- Pre-execution checklist — the checks before every production run
- Write config first, apply in controlled batches —
genconfig, thendeploy-containers --limitbatch by batch, rolling runs withdeploy -e kolla_serial=N, andmax_fail_percentage - Tags §2.4 — loop-notify is gone: a change restarts the changed container only
- Compute scaling §2 — work per compute host, read from the task files: the source of the per-compute counts of §4