cloud-init status --wait fails with yaml load error

Bug #2131809 reported by Jonas Jelten
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-init (Ubuntu)
Status tracked in Resolute
Resolute
Fix Released
Undecided
Unassigned

Bug Description

$ lxc init -c security.nesting=true ubuntu-daily:26.04 openldap-ppm-test --config=user.user-data='#cloud-config
runcmd:
  - echo '"'"'hai'"'"'
'
Creating openldap-ppm-test
$ lxc start openldap-ppm-test
$ lxc exec openldap-ppm-test -- cloud-init status --wait
2025-11-18 15:06:50,230 - util.py[WARNING]: Failed loading yaml blob. Yaml load allows (<class 'dict'>,) root types, but got str instead
...........status: done

this comes from /etc/cloud/cloud.cfg.d/90_dpkg_local_cloud_config.cfg with content:
# written by cloud-init-base debian package per preseed entry
#
10 cloud-init-base/local-cloud-config doesn't exist

which was created via /var/lib/dpkg/info/cloud-init-base.postinst handle_preseed_local_cloud_config() where
   process_debconf_setting local-cloud-config && ccfg="$RET" || :
seems to generate the failure message, which is just written down plainly as invalid yaml for cloud-init.

Jonas Jelten (jj)
description: updated
Revision history for this message
Jonas Jelten (jj) wrote :

workaround: before running cloud-init status --wait, do:
$ lxc exec openldap-ppm-test -- rm /etc/cloud/cloud.cfg.d/90_dpkg_local_cloud_config.cfg

Revision history for this message
Chad Smith (chad.smith) wrote :

Confirmed behavior on Ubuntu resolute with cloud-init 25.4~1gcb12e00e-0ubuntu1.
This is a packaging issue in resolute that doesn't affect other downstream Ubuntu series.

Changed in cloud-init (Ubuntu):
status: New → Confirmed
Chad Smith (chad.smith)
Changed in cloud-init (Ubuntu Resolute):
status: Confirmed → In Progress
Revision history for this message
Chad Smith (chad.smith) wrote :

Upstream PR in review with this fix:
https://github.com/canonical/cloud-init/pull/6598

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cloud-init - 25.4~1gcb12e00e-0ubuntu2

---------------
cloud-init (25.4~1gcb12e00e-0ubuntu2) resolute; urgency=medium

  * d/cloud-init-base.config and d/cloud-init-base.postinst:
    - fix debconf value migration error resulting in invalid config created
      by debian script (LP: #2131809)
    - address shellcheck failures

 -- Chad Smith <email address hidden> Wed, 03 Dec 2025 14:48:59 -0700

Changed in cloud-init (Ubuntu Resolute):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.