[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** No longer affects: cloud-init ** No longer affects: cloud-init (Ubuntu) ** No longer affects: cloud-init (Ubuntu Xenial) ** No longer affects: cloud-init (Ubuntu Yakkety) -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Also affects: cloud-init Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/cloud-init/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Changed in: systemd (Ubuntu Yakkety) Importance: Undecided => Medium ** No longer affects: resolvconf (Ubuntu Yakkety) ** No longer affects: resolvconf (Ubuntu Xenial) ** No longer affects: resolvconf (Ubuntu) ** Package changed: resolvconf (Debian) => ubuntu-translations ** Changed in: ubuntu-translations Importance: Unknown => Undecided ** Changed in: ubuntu-translations Status: Fix Committed => New ** Changed in: ubuntu-translations Remote watch: Debian Bug tracker #847440 => None ** No longer affects: ubuntu-translations ** Bug watch removed: Debian Bug tracker #847440 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=847440 -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
The resolvconf portion of this issue has been moved to bug #1649931. I'm removing resolvconf 1.78ubuntu3 from xenial-proposed and will replace it with a resolvconf 1.78ubuntu4 with the correct bug ref. ** Changed in: resolvconf (Ubuntu Xenial) Status: Fix Committed => Invalid ** Changed in: resolvconf (Ubuntu Yakkety) Status: In Progress => Invalid -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
This bug was fixed in the package systemd - 231-9ubuntu2 --- systemd (231-9ubuntu2) yakkety; urgency=medium [ Dan Streetman ] * rules: introduce disk/by-id (model_serial) symlinks for NVMe drives (LP: #1642903) [ Martin Pitt ] * Drop systemd-networkd's "After=dbus.service" ordering, so that it can start during early boot (for cloud-init.service). It will auto-connect to D-Bus once it becomes available later, and transient (from DHCP) hostname and timezone setting do not work in 16.10 anyway. (LP: #1636912) -- Martin Pitt Thu, 24 Nov 2016 13:21:05 +0100 ** Changed in: systemd (Ubuntu Yakkety) Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
This bug was fixed in the package systemd - 229-4ubuntu13 --- systemd (229-4ubuntu13) xenial; urgency=medium [ Martin Pitt ] * Backport graphical-session{,-pre}.target user units, for future usage from snaps. (LP: #1640293) * debian/rules: Clean up *.busname units. They are useless in 16.04 as they will always be "condition failed" as kdbus has never existed. But they add ordering constraints which make it impossible to start systemd-networkd.service during early boot, which is an upcoming requirement for cloud-init. (Part of LP: #1636912) * Drop systemd-networkd's "After=dbus.service" ordering so that it can start during early boot (for cloud-init.service). It will auto-connect to D-Bus once it becomes available later, and transient (from DHCP) hostname and timezone setting do not work in 16.04 anyway. (LP: #1636912) [ Dan Streetman ] * rules: introduce disk/by-id (wwid and model_serial) symlinks for NVMe drives (LP: #1642903) -- Martin Pitt Thu, 24 Nov 2016 12:41:23 +0100 ** Changed in: systemd (Ubuntu Xenial) Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
This bug was fixed in the package resolvconf - 1.79ubuntu4 --- resolvconf (1.79ubuntu4) zesty; urgency=medium * debian/resolvconf.service: Add missing Wants=network-pre.target. -- Martin Pitt Thu, 08 Dec 2016 10:21:12 +0100 ** Changed in: resolvconf (Ubuntu) Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Also affects: resolvconf (Debian) via http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=847440 Importance: Unknown Status: Unknown -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
> Before=networking.service > +Before=systemd-networkd.service FTR, this should be generalized to Before=network-pre.target. This is also applicable to Debian. ** Also affects: resolvconf (Ubuntu) Importance: Undecided Status: New ** Changed in: resolvconf (Ubuntu) Status: New => Triaged ** Changed in: resolvconf (Ubuntu Xenial) Status: New => Triaged ** Changed in: resolvconf (Ubuntu Yakkety) Status: New => Triaged -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
This bug was fixed in the package systemd - 232-7 --- systemd (232-7) unstable; urgency=medium [ Michael Biebl ] * Mark liblz4-tool build dependency as * udev: Try mount -n -o move first initramfs-tools is not actually using util-linux mount (yet), so making mount -n --move the first alternative would trigger an error message if users have built their initramfs without busybox support. [ Alexander Kurtz ] * debian/extra/kernel-install.d/85-initrd.install: Remove an unnecessary variable. (Closes: #845977) [ Martin Pitt ] * Drop systemd-networkd's "After=dbus.service" ordering, so that it can start during early boot (for cloud-init.service). It will auto-connect to D-Bus once it becomes available later, and transient (from DHCP) hostname and timezone setting do not currently work anyway. (LP: #1636912) * Run hwdb/parse_hwdb.py during package build. * Package libnss-systemd * Make libnss-* depend on the same systemd package version. -- Martin Pitt Wed, 30 Nov 2016 14:38:36 +0100 ** Changed in: systemd (Ubuntu) Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Changed in: systemd Status: New => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
I suppose you want this for yakkety too, so backported: https://anonscm.debian.org/cgit/pkg-systemd/systemd.git/commit/?h =ubuntu-yakkety&id=648c659e9 ** Description changed: Ubuntu Core 16 images using cloud-init fail to function when the DataSource is over the network (Like OpenStack) as networking is not yet available when cloud-init.service runs. cloud-init service unit deps look like this: [Unit] Description=Initial cloud-init job (metadata service crawler) DefaultDependencies=no Wants=cloud-init-local.service Wants=local-fs.target Wants=sshd-keygen.service Wants=sshd.service After=cloud-init-local.service After=networking.service Requires=networking.service Before=basic.target Before=dbus.socket Before=network-online.target Before=sshd-keygen.service Before=sshd.service Before=systemd-user-sessions.service Conflicts=shutdown.target Here's networkd unit deps: [Unit] Description=Network Service Documentation=man:systemd-networkd.service(8) ConditionCapability=CAP_NET_ADMIN DefaultDependencies=no # dbus.service can be dropped once on kdbus, and systemd-udevd.service can be # dropped once tuntap is moved to netlink After=systemd-udevd.service dbus.service network-pre.target systemd-sysusers.service systemd-sysctl.service Before=network.target multi-user.target shutdown.target Conflicts=shutdown.target Wants=network.target # On kdbus systems we pull in the busname explicitly, because it # carries policy that allows the daemon to acquire its name. Wants=org.freedesktop.network1.busname After=org.freedesktop.network1.busname And a critical-chain output: root@snap-test7:~# systemd-analyze critical-chain systemd-networkd Failed to get ID: Unit name systemd-networkd is not valid. The time after the unit is active or started is printed after the "@" character. The time the unit takes to start is printed after the "+" character. root@snap-test7:~# systemd-analyze critical-chain systemd-networkd.service The time after the unit is active or started is printed after the "@" character. The time the unit takes to start is printed after the "+" character. systemd-networkd.service +440ms └─dbus.service @11.461s └─basic.target @11.403s └─sockets.target @11.401s └─dbus.socket @11.398s └─cloud-init.service @10.127s +1.266s └─networking.service @9.305s +799ms └─network-pre.target @9.295s └─cloud-init-local.service @3.822s +5.469s └─local-fs.target @3.813s └─run-cgmanager-fs.mount @12.687s └─local-fs-pre.target @1.393s └─systemd-tmpfiles-setup-dev.service @1.116s +195ms └─kmod-static-nodes.service @887ms +193ms └─system.slice @783ms └─-.slice @721ms cloud-init would need networkd to run at or before 'networking.service' so it can raise networking to then find and use network-based datasources. # grep systemd /usr/share/snappy/dpkg.list ii libnss-resolve:amd64 229-4ubuntu11 amd64nss module to resolve names via systemd-resolved ii libpam-systemd:amd64 229-4ubuntu11 amd64system and service manager - PAM module ii libsystemd0:amd64 229-4ubuntu11 amd64systemd utility library ii systemd 229-4ubuntu11 amd64system and service manager ii systemd-sysv 229-4ubuntu11 amd64system and service manager - SysV links # grep cloud-init /usr/share/snappy/dpkg.list ii cloud-init 0.7.8-201610260005-gf7a5756-0ubuntu1~trunk~ubuntu16.04.1 all Init scripts for cloud instances SRU INFORMATION FOR systemd === - Fix: For xenial it is sufficient to drop systemd-networkd's After=dbus.service (https://github.com/systemd/systemd/commit/5f004d1e32) and drop the useless org.freedesktop.network1.busname unit (which is always "condition failed" as there is no kdbus, but it moves systemd-network.service after sockets.target which is too late for cloud-init). + Fix: For xenial it is sufficient to drop systemd-networkd's After=dbus.service (https://github.com/systemd/systemd/commit/5f004d1e32) and (for xenial only) drop the useless org.freedesktop.network1.busname unit (which is always "condition failed" as there is no kdbus, but it moves systemd-network.service after sockets.target which is too late for cloud-init). Regression potential: Low. networkd is not widely being used outside of netplan/snappy in xenial. Running it before dbus.service is running has two consequenc
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Changed in: cloud-init (Ubuntu) Status: Fix Released => Triaged -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
This bug was fixed in the package cloud-init - 0.7.8-45-g584b843-0ubuntu1 --- cloud-init (0.7.8-45-g584b843-0ubuntu1) zesty; urgency=medium * New upstream snapshot. - pep8: fix style errors reported by pycodestyle 2.1.0 [Scott Moser] - systemd: drop both Wants and After local-fs.target [Scott Moser] - systemd: networking service adjustments. (LP: #1636912) - systemd: replace Before=basic.target, dbus.target with sysinit.target (LP: #1629797) - doc: Add documentation on stages of boot. - doc: make the RST files consistently formated and other improvements. - Ec2: fix syntax and tox in previous commit. - Ec2: protect against non-dictionary in block-device-mapping. - doc: fixed example to not overwrite /etc/hosts [Chris Glass] - Doc: fix spelling / typos in ca_certs and scripts_vendor. -- Scott Moser Thu, 10 Nov 2016 21:04:09 -0500 ** Changed in: cloud-init (Ubuntu) Status: Triaged => Fix Released -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
** Bug watch added: github.com/systemd/systemd/issues #4504 https://github.com/systemd/systemd/issues/4504 ** Also affects: systemd via https://github.com/systemd/systemd/issues/4504 Importance: Unknown Status: Unknown -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
The "networkd after D-Bus" ordering was introduced in https://github.com/systemd/systemd/commit/1346b1f038 and later refined in https://github.com/systemd/systemd/commit/bcbca8291f . So with the latter, removing this ordering would break the "UseHostname: yes" flag (when you receive/set your host name from what DHCP gives you), i. e. it would silently not work. We don't use that feature in the distro itself, but it would be a shame to break it for everyone even when cloud-init is not involved at all. So this at least gives us a quick way out for 16.04 -- we can simply drop the "After=dbus.service" from systemd-networkd.service without much trouble, but for devel I'd at least discuss this with upstream. ** Also affects: cloud-init (Ubuntu Xenial) Importance: Undecided Status: New ** Also affects: systemd (Ubuntu Xenial) Importance: Undecided Status: New ** Changed in: systemd (Ubuntu) Importance: High => Medium ** Changed in: systemd (Ubuntu Xenial) Importance: Undecided => High ** Changed in: systemd (Ubuntu Xenial) Status: New => Triaged ** Changed in: cloud-init (Ubuntu) Assignee: Martin Pitt (pitti) => (unassigned) -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs
[Bug 1636912] Re: systemd-networkd runs too late for cloud-init.service (net)
cloud-init already has *very* strong dependencies: Requires=networking.service Before=basic.target (which is sorting the early boot fairly strictly). But I guess in the same vein, if cloud-init wants to run in between networkd and basic.target, it needs to grow an After=systemd-networkd.service. I also suggest to replace the "Requires=networking.service" with "After=networking.service" as ifupdown is not mandatory any more. However, due to networkd's After=dbus.service this wouldn't work yet, as dbus.service runs in late boot -- I proposed/tried to change this, but it's not ready for that (bug 1629797, https://bugs.freedesktop.org/show_bug.cgi?id=98254). networkd can run without D-Bus in principle, but if that is not running yet but dbus.socket is we'll run into deadlocks again -- and if we start it before we need to teach it to connect to D-Bus once it becomes available. ** Bug watch added: freedesktop.org Bugzilla #98254 https://bugs.freedesktop.org/show_bug.cgi?id=98254 ** Changed in: systemd (Ubuntu) Status: New => Triaged ** Also affects: cloud-init (Ubuntu) Importance: Undecided Status: New ** Changed in: cloud-init (Ubuntu) Status: New => Triaged -- You received this bug notification because you are a member of Ubuntu Desktop Bugs, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1636912 Title: systemd-networkd runs too late for cloud-init.service (net) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1636912/+subscriptions -- desktop-bugs mailing list desktop-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/desktop-bugs