UbuntuIRC / 2020 /02 /21 /#cloud-init.txt
niansa
Initial commit
4aa5fce
[11:25] <boolman> how can I force netplan on cloudinit?
[11:33] <meena> boolman: https://cloudinit.readthedocs.io/en/latest/topics/network-config.html#network-configuration-outputs it's default on Ubuntu 17.10
[11:34] <meena> boolman: but you can override the default: https://cloudinit.readthedocs.io/en/latest/topics/network-config.html#network-output-policy
[11:34] <meena> of course, that would require that the binaries be in place… and that netplan can render for whatever the backend is, that your OS actually supports.
[11:35] <meena> Netplan currently works with these supported renderers
[11:35] <meena> NetworkManager
[11:35] <meena> Systemd-networkd
[13:08] <shibumi> Hi can somebody explain me this error here? udevadm test-builtin net_setup_link /sys/class/net/lo fails with No such file or directory
[13:08] <shibumi> The error message is at this location: https://github.com/canonical/cloud-init/blob/13e82554728b1cb524438163784e5b955c7c5ed0/cloudinit/net/netplan.py#L256
[14:20] <Odd_Bloke> shibumi: What version of cloud-init are you using, and on what distro?
[15:23] <rharper> shibumi: looks like your OS/kernel does not provide a loopback network interface
[15:27] <boolman> im trying to get cloudinit to work on vmware, but it works like 1/10 of the time. other times it either doesnt even get the user/metadata or configures the network to late. different hosts each time. seems so random.
[15:28] <boolman> should mention that im deploying with terraform
[15:37] <rharper> boolman: hi; vmware + cloud-init is not in a great spot; this is a known issue; there are some discussions with VMWare cloud-init devs to work on supporting user-data, network-config and vmware customization;
[15:41] <boolman> rharper: okey, so just not do it is the current solution?
[15:50] <rharper> boolman: well it depends on what "mode" you're using; https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1806133
[15:50] <ubot5> Ubuntu bug 1806133 in cloud-init (Ubuntu) "OVF does not read user-data if vmware IMC is used." [Medium,Confirmed]
[15:51] <shibumi> Odd_Bloke: arch linux
[15:51] <shibumi> Odd_Bloke: newest release
[15:51] <shibumi> Odd_Bloke: cloud-init 19.3
[15:51] <shibumi> Odd_Bloke: maybe a bug in the new arch linux implementation for cloud-init?
[15:51] <shibumi> rharper: it should..i have no idea what's going on
[15:53] <rharper> shibumi: me neither; I don't know what creates the initial loopback interface; I was fairly certain the kernel itself does this;
[15:53] <rharper> which made me wonder what kernel was in use
[15:55] <boolman> rharper: not sure what you mean, Im deploying a regular vm template, without vmware customization
[15:55] <rharper> OVF has many places it "fetches" configuration from
[15:56] <boolman> im not using OVF atleast
[15:56] <rharper> then IMC ?
[15:57] <boolman> Im not following, Ive manually installed a ubuntu bionic from cd, installed cloudinit and vmware's cloudinit guestinfo package. converted to template.
[15:57] <rharper> if you like, you can run cloud-init collect-logs and the tarball will have info we look at what's going on; it may be a known issue, or it could be a new one
[15:58] <rharper> when you boot the template cloud-init needs a datasource; on VMware platforms, this is typically OVF;
[15:58] <boolman> https://github.com/vmware/cloud-init-vmware-guestinfo
[15:58] <rharper> the platform provides to the guest 1) an iso OVF format 2) OVF in the filesystem of the guest 3) vmware customization config in the filesystem of the guest
[15:58] <rharper> we don't support that
[15:59] <rharper> it's out of tree; if VMware wanted to contribute that to cloud-init; that'd be nice
[15:59] <rharper> it has 9 issues; maybe one of them is relevant ?
[15:59] <rharper> https://github.com/vmware/cloud-init-vmware-guestinfo/issues/5
[16:01] <boolman> no that doesnt seem relevant to my problem
[18:35] <johnsonshi> Hi guys, I am trying to configure an Azure VM so that its per-boot scripts would persist across 'cloud-init clean -lr' invocations. I have dropped some scripts into /var/lib/cloud/scripts/per-boot, but when I issue cloud-init clean -lr, the scripts are not executed, and when I look into the per-boot scripts directory, it is empty. The cloud-init.log file also makes no mention of executing any script within the per-boot directory. That means
[18:35] <johnsonshi> somehow per-boot directory gets cleaned when cloud-init clean -lr runs.
[18:36] <johnsonshi> The docs mention that "Any scripts in the scripts/per-boot directory on the datasource will be run every time the system boots." does that mean that in order to configure per-boot scripts, I would need to configure the datasource (which in this case is the Azure datasource (since this is an Azure VM))
[18:52] <Odd_Bloke> johnsonshi: `cloud-init clean` cleans out all of /var/lib/cloud (by design). Perhaps changing your process to put those scripts in place _after_ you clean would work?
[19:00] <johnsonshi> Odd_Bloke: I have just discovered that the write_files module runs first (during the first stage of cloud-init), while the per-boot module runs in the last module. I will try that out instead. Thanks!
[19:01] <johnsonshi> Odd_Bloke: Perhaps I could get write-files to write the scripts into the per-boot directory.
[19:19] <Odd_Bloke> I believe that would work.
[21:20] <Odd_Bloke> blackboxsw: rharper: The updated release process doc/script: https://github.com/CanonicalLtd/uss-tableflip/pull/37
[21:21] <Odd_Bloke> blackboxsw: Can you point me at the template Trello board? I want to be 100% sure I'm modifying the correct thing. :p
[21:21] <blackboxsw> Odd_Bloke: https://trello.com/b/QQYFXpsA/template-sru-cloud-init-xy
[21:21] <Odd_Bloke> Thanks!
[21:21] <blackboxsw> no prob