Public bug reported: In Ubuntu packaging of systemd cloud-init.service file, cloud- init.service declares ordering as After=systemd-networkd-wait- online.target[1] and Before=sysinit.target[2].
The desktop live installer ISO prefers using NetworkManager as the primary network backend and cloud-init must order After=NetworkManager.service in these cases to avoid DNS-related bugs during datasource discovery and downloading user-data such as LP: #2008952. Short-term fix is to provide an override for cloud-init.service in the livecd-rootfs project[3] Long-term need is to provide a mechanism at systemd-generator timeframe to order cloud-init.service After=NetworkManager.service. Since NetworkManager.service is After=sysinit.target due to After=dbus.service ordering, cloud-init.service would have to drop it's Before=sysinit.target declarations in order to avoid systemd ordering cycles. [1] https://github.com/canonical/cloud-init/blob/main/systemd/cloud-init.service.tmpl#L11 [2] https://github.com/canonical/cloud-init/blob/main/systemd/cloud-init.service.tmpl#L33 [3] livecd-rootfs cloud-init.service overrides https://code.launchpad.net/~chad.smith/livecd-rootfs/+git/livecd-rootfs/+merge/439586 ** Affects: cloud-init Importance: Medium Status: New ** Changed in: cloud-init Importance: Undecided => Medium -- You received this bug notification because you are a member of Yahoo! Engineering Team, which is subscribed to cloud-init. https://bugs.launchpad.net/bugs/2015949 Title: Ubuntu: cloud-init.service order After=NetworkManager.service not possible with Before=sysinit.target Status in cloud-init: New Bug description: In Ubuntu packaging of systemd cloud-init.service file, cloud- init.service declares ordering as After=systemd-networkd-wait- online.target[1] and Before=sysinit.target[2]. The desktop live installer ISO prefers using NetworkManager as the primary network backend and cloud-init must order After=NetworkManager.service in these cases to avoid DNS-related bugs during datasource discovery and downloading user-data such as LP: #2008952. Short-term fix is to provide an override for cloud-init.service in the livecd-rootfs project[3] Long-term need is to provide a mechanism at systemd-generator timeframe to order cloud-init.service After=NetworkManager.service. Since NetworkManager.service is After=sysinit.target due to After=dbus.service ordering, cloud-init.service would have to drop it's Before=sysinit.target declarations in order to avoid systemd ordering cycles. [1] https://github.com/canonical/cloud-init/blob/main/systemd/cloud-init.service.tmpl#L11 [2] https://github.com/canonical/cloud-init/blob/main/systemd/cloud-init.service.tmpl#L33 [3] livecd-rootfs cloud-init.service overrides https://code.launchpad.net/~chad.smith/livecd-rootfs/+git/livecd-rootfs/+merge/439586 To manage notifications about this bug go to: https://bugs.launchpad.net/cloud-init/+bug/2015949/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : [email protected] Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp

