/srv/irclogs.ubuntu.com/2024/02/09/#cloud-init.txt

holmanbananke: and what triggers the shutdown? 01:22
anankeholmanb: aws ec2 shut down event, presumably comes in as an ACPI call. system performs regualr shutdown01:24
acibacommunity notice: cloud-init 23.4.3 is uploaded to ubuntu's -proposed pockets for SRU verification and review. We'll be performing our SRU validation of this release for stable Ubuntu releases over the next 7 days.  https://github.com/canonical/cloud-init/releases/tag/23.4.309:41
=== lesbraz is now known as sbraz
tryfanHi all, been having no luck figuring this out.  Is setting a DNS server on SLES/OpenSUSE Leap 15 supported in cloud-init?  It's setting the ip/gateway correctly in the ENI files but isn't touching the config file for netconfig, nor is it setting anything in resolv.conf.  I didn't see anything explicit in the code for setting the nameservers in suse15:33
tryfaneither.15:33
minimaltryfan: what "ENI files"? AFAIK SLES/OpenSUSE have never used /etc/network/interfaces17:50
minimalwhere exactly are you specifying the DNS server to use? Which DataSource are you using?17:50
tryfanminimal: the datasource is NoCloud and is an ISO mounted to the VM on boot. The IP is being set in /etc/sysconfig/network/ifcfg-eth0 and gateway is in ifroute-eth019:29
minimalok, so wondering why you mentioned ENI19:30
minimalso did you check /var/log/cloud-init.log to see the network details cloud-init obtained from the ISO in order to config networking? can you pastebin (or equivalent) the user-data from the ISO?19:32
tryfansorry, it looks so similar19:32
tryfanI'm getting the data again.  the relevant logs are: https://paste.centos.org/view/4e246ef219:34
tryfanif I set resolv_conf in the cloud.cfg, cloud-init sets resolv.conf but it's overwritten by wicked/netconfig on reboot19:35
minimalso where do you want/expect the nameserver to be set?19:35
tryfanif could-init is to obey whatever the official sles way is, it would be according to this: https://documentation.suse.com/sles/15-SP5/html/SLES-all/cha-network.html#sec-network-yast-change-host19:40
tryfanso either a command to yast, or modifying the /etc/sysconfig/network/config file19:41
tryfanthe more I dig, the more I dislike the way suse does things19:41
tryfanI saw an old bug around this, but nothing was done with it: https://bugs.launchpad.net/cloud-init/+bug/184929619:44
-ubottu:#cloud-init- Launchpad bug 1849296 in cloud-init "use netconfig for DNS settings on SUSE" [Medium, Expired]19:44
minimaltryfan: the comments in that bug did say "if we work with netconfig and support a "merging" behaviour that would be behaviour change for which we will probably also get complaints"20:21
tryfanminimal: imho, doing nothing will eventually get a complaint.  as it stands, it just doesn't work and there's no option to just clobber resolv.conf support in suse, which I'd personally be ok with.  at least there would be an option to make it work20:34
tryfanright now, there's just nothing20:35
minimal"clobber resolv.conf support" support? how about not providing "manage_resolv_conf: true" and also provide "nameservers" (within "resolv_conf:") in your user-data?20:44
minimals/not //20:44
tryfanminimal: I did: https://paste.centos.org/view/ea1e333b20:53
minimalumm, why are you specifying network config in BOTH meta-data and network-config files? why are you specifying DNS config in meta-data and network-config and user-data?21:01
tryfanit's a payload for multiple OSes and versions, it works for everything from centos 7 to ubuntu 2221:05
minimalvery weird21:10
tryfanI understand it's not ideal and in a perfect scenario, it would be precise for every distro and version target, but it's not exactly the space I'm in21:10
minimalwell it will be hard for someone (else) to figure out any interactions between duplicated settings in different places..21:14
tryfanin the logs I posted starting line 8 it has the correct config, sets IP, gateway, and that's it.  no mention of dns or resolvers anywhere else.  I don't believe it's an interaction issue.21:25
tryfanI understand it's not cut and dried, I even see other attempts to make it work such as https://github.com/canonical/cloud-init/issues/360621:25
-ubottu:#cloud-init- Issue 3606 in canonical/cloud-init "[cloud-init] '/etc/resolv.conf' is out of control of netconfig after done cloud-init GOSC on SLES15SP1" [Open]21:25
tryfanI'm going to try disabling all control of that file from sles and see if I can get it to work21:26
minimaltryfan: if you're aware of problematic multi OS differences in cloud-init behaviour it would be useful to raise Issues for them as I assume many/most cloud-init users only use it with 1 or 2 different distros....if such issues aren't highlighted then they'll probably never get addressed21:31
minimalobviously multiple cloud-init versions (especially older ones shipped by more "enterprise", i.e. slow to update, distros) complicates things21:31
minimalthe cloud-init.log portion you provided doesn't show the activation of any modules (such as the resolv_conf one)21:33

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!