[00:13] <rharper> bdx: if you can pastebin /var/log/cloud-init.log we can see what's going on;
[03:19] <bdx> rharper: https://bugs.launchpad.net/cloud-init/+bug/1729715
[14:00] <smoser> rharper: in netwokr config v1, i think that we can't rename an interface without knowing the mac. is that right ?
[14:09] <rharper> smoser: correct
[16:49] <smoser> https://git.launchpad.net/~smoser/cloud-init/commit/?h=feature/json-socket-server
[16:49] <smoser> thats my json server
[16:49] <smoser> see that commit message for how to use.
[16:59] <Sargun> Can you write templates in write_files?
[17:13] <blackboxsw> not sure what you mean Sargun, you can write any file content  you want. if you wrote templates in write_files I'd guess you'd be processing templates  in your runcmd config.
[17:18] <blackboxsw> the files written by the write_files is a list with a single file declared per list item.
[17:53] <bdx> @rharper, @smoser does static interface network-config for nocloud work for you guys?
[18:07] <rharper> bdx: working; I replied, you need network-config in separate file, and drop the top 'network' key
[18:10] <bdx> rharper: that is awesome!
[18:10] <bdx> I just got it to work
[18:10] <rharper> ]o/
[18:10] <bdx> many thanks
[18:10] <rharper> what happened to my arm!?
[18:10] <rharper> \o/
[18:10] <rharper> there we go
[18:10] <bdx> :)
[18:10] <rharper> np, sorry it wasn't clear from the docs
[18:11] <bdx> its cool, its pretty clear, there are just a few gotchas
[18:11] <bdx> like you *must* use the network-config file
[18:11] <bdx> which I did
[18:11] <bdx> geh
[18:11] <rharper> I've filed https://bugs.launchpad.net/cloud-init/+bug/1708255
[18:12]  * bdx beats his own head
[18:12] <rharper> which should have made it obvious that it got a config but was unhappy with it
[18:12] <rharper> now just to allocate time toward that one
[18:12] <bdx> ha - right
[18:12] <bdx> thanks all the same
[18:13] <rharper> np
[18:13] <rharper> I may repurpose your bug into updating the docs around NoCloud's use of network-config since that part wasn't clear
[18:14] <bdx> that would be great
[18:15] <Sargun> blackboxsw: I have a file I want to write in write_files, but I want to substitute instance_id into the config files in some places. Is there an easy way to do this?
[18:40] <smoser> Sargun: no. :-(
[18:40] <smoser> but https://trello.com/c/AYaCdQyT
[18:40] <smoser> that is the trello card that i descried what i'd want.
[18:41] <smoser> powersj: what am i doing wrong
[18:43] <smoser> Sargun: i'd be interested in your thoughts on that.
[18:43] <powersj> smoser: not sure yet, I was just finishing lunch let me dig in
[18:49] <powersj> smoser: hmm now it is working, but super slow... 20 seconds for each pull.
[18:50] <powersj> https://paste.ubuntu.com/25881348/
[18:51] <powersj> are you seeing similar results?
[18:52] <smoser> for each pull ?
[18:52] <smoser> what is pull
[18:52] <powersj> sorry each cmd run
[18:54] <smoser> no..
[18:54] <smoser> 2017-11-03 18:53:28,938 - tests.cloud_tests - DEBUG - running collect script: result.json
[18:54] <smoser> 2017-11-03 18:53:28,938 - tests.cloud_tests - DEBUG - Executing "collect: result.json"
[18:54] <smoser> 2017-11-03 18:53:29,321 - tests.cloud_tests - DEBUG - running collect script: status.json
[18:54] <smoser> 2017-11-03 18:53:29,322 - tests.cloud_tests - DEBUG - Executing "collect: status.json"
[18:56] <powersj> hmm
[18:56] <smoser> powersj: i have a thoguht that it could be sudo and dns related possibly.
[18:57] <smoser> or it could be paramiko related.
[18:58] <smoser> maybe the wway we are sending stdin now is not rigiht
[18:58] <smoser> (we were not sending before)
[19:07] <smoser> powersj: can you try
[19:08] <smoser>  http://paste.ubuntu.com/25881453/
[19:08] <smoser> that re-uses the connected ssh client
[19:35] <blackboxsw> smoser: powersj I'm seeing successes on nocloud-kvm (artful)
[19:35] <blackboxsw> will pull in your paste too
[19:37] <powersj> blackboxsw: Are you seeing timings like smoser, which are quick?
[19:39] <powersj> smoser: still getting 20-second delays between each collect... that definitely feels like something is timing out somewhere along the path.
[19:39] <powersj> I'll pastebin shortly
[19:40] <blackboxsw> lemme, check timestamps on that powersj
[19:41] <powersj> https://paste.ubuntu.com/25881623/
[19:41] <blackboxsw> meh powersj yeah 20 second delays between collect calls
[19:41] <blackboxsw> http://pastebin.ubuntu.com/25881628/
[19:43]  * powersj goes and find's smoser's venv cmd
[19:47] <smoser> powersj: ./tools/tox-venv
[19:47] <smoser> blackboxsw: where are you running that ?
[19:48]  * blackboxsw hasn't tried smoser I'm running that on artful desktop at home.
[19:48] <smoser> oh. i thought you said you had.
[19:48] <blackboxsw> tox -e citest -- run --verbose --os-name xenial --deb cloud-init_17.1-46-g8a49e051-1~bddeb_all.deb --data-dir ~/collection --preserve-data --platform=nocloud-kvm --test=tests/cloud_tests/testcases/modules/final_message.py
[19:51] <powersj> smoser: still having issues: https://paste.ubuntu.com/25881674/
[19:53] <blackboxsw> smoser: sorry about the last couple comments,  I had tried running artful with the following commandline  I see various successes there, but I'm seeing the 20 second gap between each collect
[19:54] <blackboxsw> and that 20 second gap persists even across your re-use ssh patch
[19:55] <smoser> could one of you letl me in somewhere ?
[19:55] <smoser> so i can run. i'm kind of out of ideas.
[19:56] <blackboxsw> smoser: yeah adding you
[19:57] <blackboxsw> gotta open up my router one min
[20:00] <smoser> blackboxsw: hm.. ok . i ran here and i see it. (locally on artful desktoip) rather than on diglett.
[20:00] <blackboxsw> smoser: ok. I've got creds for you if needed
[20:06] <powersj> Running on torkoal seems fine
[20:06] <smoser> it hangs on
[20:06] <smoser>             rc = channel.recv_exit_status()
[20:14] <blackboxsw> should we be checking exit_status_ready ?
[20:17] <blackboxsw> not going to help
[20:17] <blackboxsw> I looped in a pdb session
[20:17] <blackboxsw> http://pastebin.ubuntu.com/25881811/
[20:17] <blackboxsw> it also is false for about 20 seconds
[20:17] <blackboxsw> then true
[20:17] <blackboxsw> which presumably is when the exit status becomes available to paramiko
[20:22] <smoser> blackboxsw: yeah, iwas looking at that too.
[20:22] <smoser> the examples of paramiko and sending data are not a lot.
[20:22] <smoser> just tried here doing a channel.shutdown(2)
[20:22] <smoser> http://docs.paramiko.org/en/2.3/api/channel.html
[20:22] <smoser> rather than shutdown_write()
[20:22] <smoser> and taht didnt help
[20:42] <smoser> blackboxsw: dropping remvoes the hang.
[20:43] <smoser> self.ssh(["sudo", "cat", "/etc/cloud/build.info"])
[20:43] <smoser>  ^^ slow ---- vv faster
[20:43] <smoser> self.ssh(["cat", "/etc/cloud/build.info"])
[20:45] <smoser> ok.
[20:45] <smoser> well... not paramiko fault
[20:45] <smoser> this hangs similarly
[20:45] <smoser> ssh ubuntu@localhost -p 37425 -i results.nocloud-kvm.d/id_rsa "cat /etc/passwd"
[20:46] <smoser> i really, really hate that feature in sudo
[20:51] <blackboxsw> geez right, it's sudo trying to hit resolve or something for the hostname?
[20:51] <rharper> yeah
[20:51] <rharper> you need the hostname in /etc/hosts or sudo barfs;
[20:52] <blackboxsw> so we could set the hostname in /etc/hosts
[20:52] <blackboxsw> yeah
[20:52] <rharper> or, set NOPASSWD in sudoers
[20:52] <smoser> ?
[20:52] <smoser> we do have nopassword for that user
[20:52] <rharper> ah, right, I guess it still does the lookup
[20:53] <rharper> looks like ALL would work
[20:53] <blackboxsw> ok in ip tools world (no netstat) how do I check what open ports I'm listening too
[20:55] <blackboxsw> I'm so used to netstat -ln
[20:55] <smoser> its such a non-feature
[20:55] <smoser> https://superuser.com/questions/429790/sudo-command-trying-to-search-for-hostname
[20:55] <smoser> that describes what it is and what is doing it.
[20:55] <rharper> hey, you want to share your sudoers file across your entire company
[20:55] <rharper> it needs to know which host it's on
[20:56] <blackboxsw> ss -l
[20:57] <smoser> im' not sure why, but
[20:57] <smoser>  'time host ubuntu'
[20:57] <smoser> that returns in 1 second on my system (where this is slow)
[20:57] <smoser> and 0.014 seconds on diglett
[20:57] <blackboxsw> dns search order?
[20:57] <smoser> which i think is basically the source of why it works fast on diglett
[20:58] <rharper> what does host -v show ?
[20:58] <rharper> that walks the dns search list here
[20:59] <rharper> with vpn, it rns through all of those domains in the list
[20:59] <rharper> all those domains have to say no before your caching nameserver can give up and let /etc/hosts respond IIUC
[20:59] <rharper> wow, localhost even has to do that with the "host" command
[21:01] <blackboxsw> so on artful I'm talking to systemd/resolved, what's diglett running again?
[21:01] <rharper> artful
[21:01] <blackboxsw> hmm ok
[21:01] <smoser> diglet is bionic
[21:01] <rharper> oh, when did we upgrade ?
[21:02] <smoser> https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1728616
[21:02] <smoser> looks like i did on 2017-10-30
[21:02] <smoser> :)
[21:02] <rharper> heh
[21:03] <smoser> we really should fix sudo
[21:03] <smoser> to not do a dns lookup if it doesnt need to
[21:13] <rharper> the claim is that it wants to, ifyou set the section to (ALL) for the hostname it won't do that
[21:13] <smoser> it doesnt claim that.
[21:13] <rharper> https://bugs.launchpad.net/ubuntu/+source/sudo/+bug/32906
[21:13] <smoser> well, it doesnt fail
[21:14] <smoser> …yeah, sudo, it’s all very clever until someone loses an eye!
[21:14] <smoser> i like that :)
[21:14] <rharper> now, it appears are are using (ALL); so now I'm confused
[21:16] <rharper> https://www.sudo.ws/repos/sudo/rev/1e10105ade5b
[21:16] <rharper> fun stuff
[21:16] <rharper> sudo + PAM
[21:18] <smoser> well, acouple of options here.
[21:18] <smoser> a.) cloud-init can be set to write the  hostname to /etc/hosts
[21:18] <smoser> b.) we can just eat this once when we first run a command
[21:18] <smoser> but even then, 20 seconds is suck
[21:19] <smoser> c.) maybe this is sufficient, for nocloud we can just modify it pre-boot
[21:20] <smoser> also in these scenario..
[21:20] <smoser> we can be trickly.
[21:20] <smoser> for nocloud-kvm, if i add an 'ubuntu' to the *hosts* /etc/hosts
[21:20] <smoser> then qemu dns -> host resolv -> that entry
[21:20] <smoser> and magic fast
[21:21] <smoser> 127.0.0.1   localhost ubuntu
[21:22] <blackboxsw> yeah I think I don't want to eat that 20 second cost even on setup
[21:22] <blackboxsw> that makes every test that much more costly
[21:23] <smoser> with that in place, on diglett
[21:23] <blackboxsw> I like being trickly
[21:23] <smoser> http://paste.ubuntu.com/25882159/
[21:23] <blackboxsw> looks much better
[21:23] <smoser> ~ 0.06
[21:23] <blackboxsw> instead of 0.014 right?
[21:24] <smoser> oh. no. instead of something like a half a second it hink
[21:24] <blackboxsw> Ohh I was thinking you were talking time host ubuntu ... and 0.014 seconds on diglett
[21:25] <rharper> I'm +1 for writing ubuntu into hosts
[21:26] <rharper> oh, heh, I forgot we had something like this for m-i-c
[21:26] <blackboxsw> yeah, I think that's warranted given we know sudo's shortfall w.r.t. hostname lookup