/srv/irclogs.ubuntu.com/2021/01/05/#cloud-init.txt

testing1818282Hello Odd_Bloke hope you remember me from yesterday. I had a question regarding ssh host key keys that I think get generated too late. I am sorry for leaving in the middle of the conversation but my isp has failed on me and couldn't log back in. Do you have any idea what I can do to have my machine print the keys? Thanks for the help08:28
testing1818282These are the logs I have on hand: https://pastebin.ubuntu.com/p/DrZ84SWsfM/ & https://pastebin.ubuntu.com/p/dk4hMqsCVX/08:31
beantaxi_Hi all ... thought I'd ask about how PS #745 is looking (https://github.com/canonical/cloud-init/pull/745). If there's anything needed from me to help move it forward I'm happy to help. Thanks!16:05
rharperOdd_Bloke: in case testing1818282 returns, it looks to me like, the instance 1) already has existing host keys; they get deleted in the log 2) the instnace does not invoke ssh-keygen, which could be cause of user-data config , or the RHEL image it's running may generate ssh-keys via the ssh-keygen.service; in which case maybe that is running (or not running) at the correct time;16:13
rharperbeantaxi: it's on my list to review;  my quick take is that each of those scripts are 99% identical other than the name and file;  I would like to see a common handle implementation that each of those script files import and use, passing in the variable name/path;16:15
Odd_Blokerharper: Aha, didn't know about that service, that's really handy info.  We'll see if I get to use it. :p16:33
Odd_Blokehttps://github.com/canonical/cloud-init/pull/750 is open, clarifying how netplan passthrough works; I couldn't find anywhere that we documented it previously.16:37
rharperOdd_Bloke: thanks for 750, I'll review;  I myself have had to re-read the code a few times to recall how we keep the imported config around and detect v2 pass-through to write out the original16:44
minimalOdd_Bloke: that PR came about from a discussion I'd had with the reporter on here over the holiday period16:45
minimalI was pointing out to him that just because what he was doing with netplan currently worked in c-i was no guarantee that it would continue to work as it wasn't a documented c-i network-v2 configuration16:46
minimalplus the issue of course of it not working for e/n/i and other renders16:46
Odd_Blokeminimal: Aha, right, I hadn't put the IRC backlog and bug together; thanks for helping them out!16:49
minimalat the time it surprises me to see him using the "from:" value as I've used static routes with e/n/i and had not seen that before16:50
Odd_Blokerharper: I've just seen https://paste.ubuntu.com/p/CWcp88S2QM/ in a focal cloud-init KVM run; does that look like the same kernel issue we've been seeing from time-to-time?16:51
rharperOdd_Bloke: that looks new to me;16:52
rharperthe stack track looks KVM related;  I would guess either the host OOMed or otherwise couldn't fill the memory request; so highly memory contention;16:54
rharperOdd_Bloke: looks like this, https://github.com/torvalds/linux/commit/2a266f23550be997d783f27e704b9b40c4010292  ; which landed in 5.11, not sure if kernel team has that in 5.4.1 in focal ;16:59
beantaxirharper: Sounds reasonable. I can do that today. Thanks for the feedback!17:07
rharperbeantaxi: cool!17:07
rharperbeantaxi: I also elaborated on the PR directly, please look at those comments as well17:08
Odd_Blokerharper: That looks like it landed in v4.15, if I'm reading the GH tags right?17:20
rharperOdd_Bloke: yeah, I don't fullly understand what that 4.15 tag means;  if it did land in 4.15, how did it get into 5.4, and why also 5.1117:35
Odd_BlokeI believe that displays the tags which include this commit in their history; so I think it landed in 4.15 (and is therefore present in every subsequent tag).17:36
Odd_BlokeWe're also seeing https://paste.ubuntu.com/p/N395dZxnGz/ on groovy.17:42
beantaxirharper: Yes I read through your comments and smosers too. They're great: politeful and respectful but very clear. Much appreciated!17:57
=== ijohnson is now known as ijohnson|lunch
Odd_Blokerharper: Thanks for the review. :)19:17
=== vrubiolo1 is now known as vrubiolo
=== ijohnson|lunch is now known as ijohnson
wyoungo/22:02
wyoungI am using cloud-init with AWS EC2 deployed via CloudFormation.  If I change the cloud-config can I get it to apply on an CloudFormation update?  For example, I want to update the contents of a file created via write_files.22:04
rharperwyoung: on an existing instance? or new instance?22:05
wyoungrharper: existing.22:06
rharperby default, cloud-init won't re-run write_files config on the same instance;  you can force a particular module to run with:  cloud-init single --name write_files --frequency always ;22:07
wyoungrharper: I would add that to the runcmd section?22:08
wyoungand run it manually for the existing instance?22:08
rharperyou need to run that command on the instance itself  (ie, ssh into and run that command)22:12
rharperwyoung: ^22:12
wyoungrharper: And for new instances (after I add in that command to runcmd) will it write files on a change?22:13
wyoungOr do I need to manually run the command again after any change/.22:13
rharpernot really; manually need to run that any time it changes;22:13
rharperI'm not sure how CloudFormation works; but ideally; you could set up some http long poll against the CF config URL; and on-change, run an update; but that's just not in place;  any given cloud-init config moodules (run_cmd, users, packages, etc...) may not be idempotent; so it's not clear what cloud-init should do if the user-data config changed ...22:15
rharperfor something like a write_files where you know you want to update a particular file, you may want to set up some sort of watch on the config URL, and on change run the command;22:16
rharperless effort but not as dynamic would be put that into a cron job which runs every so often22:16

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