Public bug reported:
1) Ubuntu Release: Description: Ubuntu 26.04 LTS Release: 26.04
2) Package Version: cloud-init: Installed: 26.1-0ubuntu2
3) What I expected to happen: Cloud-init should successfully detect the
Ec2 datasource and configure networking. Specifically, cloud-init-
local.service should have a dependency on network hardware enumeration
(udev) to ensure that the primary network interface (ena) is visible
before attempting to identify the cloud platform.
4) What happened instead: On modern, fast-booting hardware (specifically
Graviton 4 / m8g instances), or a minimalist OS image, or in scenarios
where the ena driver is slightly delayed, cloud-init-local executes
before the ENA driver has finished probing the PCI bus. Cloud-init sees
only the 'lo' interface, fails to identify the Ec2 datasource, and falls
back to DataSourceNone. This results in the instance booting without
network connectivity, causing systemd-networkd-wait-online to time out.
The cloud-init log explicitly shows the failure:
"DataSourceEc2.py[ERROR]: The instance must have at least one eligible
NIC"
The systemd unit file for cloud-init-local.service in this release is
missing any hardware or udev dependencies: [Unit] Description=Cloud-
init: Local Stage (pre-network) DefaultDependencies=no Wants=network-
pre.target After=hv_kvp_daemon.service Before=network-pre.target
Before=sysinit.target
STEPS TO REPRODUCE: The issue can be deterministically reproduced by
artificially delaying the ena driver initialization to simulate a fast
OS boot outrunning the hardware probe:
Launch a stock Ubuntu 26.04 m8g.medium instance.
Add a modprobe delay for the ena driver: echo "install ena /usr/bin/sleep 10;
/sbin/modprobe --ignore-install ena" > /etc/modprobe.d/ena-delay.conf
Clean cloud-init state and reboot: cloud-init clean --logs && reboot
On the subsequent boot, cloud-init will fail to detect the EC2 datasource
because the ENA driver will still be in its 10-second sleep when
cloud-init-local executes.
Thanks!
** Affects: cloud-init (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2151279
Title:
cloud-init-local executes before ENA network driver completes PCI
probe, causing DataSourceEc2 failure
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/2151279/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs