Skip to content

fix: update nova-compute notification config for telemetry meters - #210

Merged
hemanthnakkina merged 2 commits into
canonical:stable/2025.1from
wilkmar:bug/2162762-2025.1
Sep 2, 2026
Merged

hemanthnakkina merged 2 commits into
canonical:stable/2025.1from
wilkmar:bug/2162762-2025.1

Conversation

@wilkmar

@wilkmar wilkmar commented Aug 27, 2026

Copy link
Copy Markdown

Change notification_format from versioned to both so that Ceilometer receives unversioned notifications on the notifications topic and Watcher receives versioned ones on the versioned_notifications topic [0][1]. Ceilometer already subscribes to both topics [2]. Add notify_on_state_change = vm_and_task_state to enable instance lifecycle notifications like compute.instance.booting.time.

[0] - https://docs.openstack.org/watcher/2025.1/configuration/configuring.html#configure-nova-notifications
[1] - https://docs.openstack.org/nova/2025.1/configuration/config.html#notifications.notification_format
[2] - https://opendev.org/openstack/sunbeam-charms/commit/15739a4dbf4245234c2a6348c14654f9c2980156

Partial-bug: #2162762

QA steps

  1. Deploy sunbeam
  2. Enable telemetry
sunbeam enable telemetry
  1. Build and install the openstack-hypervisor snap with this branch
    Verify nova-compute config
grep -A5 oslo_messaging_notifications /var/snap/openstack-hypervisor/common/etc/nova/nova.conf
[oslo_messaging_notifications]
driver = messagingv2

[notifications]
notify_on_state_change = vm_and_task_state
notification_format = both
  1. Launch an instance and verify compute.instance.booting.time metric
openstack server create --flavor m1.small --image ubuntu --network demo-network test-vm
openstack metric resource show <instance-id>
# Should include compute.instance.booting.time (missing without this fix)
  1. Enable Watcher and verify it receives versioned notifications

Links

Jira card: OPEN-4670

@wilkmar
wilkmar force-pushed the bug/2162762-2025.1 branch from c634077 to c4a6c60 Compare August 28, 2026 09:13
@wilkmar
wilkmar marked this pull request as draft August 31, 2026 09:39
@wilkmar
wilkmar marked this pull request as ready for review September 2, 2026 08:19

@hemanthnakkina hemanthnakkina left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to see 2 commits each cherrypicked from main

#208
#213

Add notify_on_state_change = vm_and_task_state to enable instance
lifecycle notifications like compute.instance.booting.time.

Partial-bug: #2162762

Signed-off-by: Marcin Wilk <marcin.wilk@canonical.com>
This is a follow up to the previous commit [1], which did not properly
configured nova.conf to support Ceilometer notifications.

On 2026.1, according to [2], all instance-related metric are collected
by pollster, so theoretically, no nova.conf changes are needed at all.
However, when enabled, Nova sends the legacy, unversioned notifications
to Ceilometer, with the following meters, which are not available via
pollster [4]:
- memory
- vcpus
- disk.root.size
- disk.ephemeral.size

Without the Nova notifications enabled the above, flavor-based,
meters will not be available. This is important because some
external or third party billing systems may rely on that.

This commit fixes missing nova.conf Ceilometer notification
settings.

[1] canonical#208
[2] https://docs.openstack.org/ceilometer/2026.1/admin/telemetry-measurements.html#openstack-compute
[3] https://opendev.org/openstack/nova/src/branch/stable/2026.1/nova/compute/utils.py#L342
[4] https://opendev.org/openstack/nova/src/branch/stable/2026.1/nova/notifications/base.py#L337

Partial-bug: #2162762
Signed-off-by: Marcin Wilk <marcin.wilk@canonical.com>
@wilkmar

wilkmar commented Sep 2, 2026

Copy link
Copy Markdown
Author

I would like to see 2 commits each cherrypicked from main

#208 #213

Done

@hemanthnakkina
hemanthnakkina merged commit 0c5cea2 into canonical:stable/2025.1 Sep 2, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants