/srv/irclogs.ubuntu.com/2018/03/23/#cloud-init.txt

kalyanhi all ... i am facing some issue with cloud init on suse.... is anyone available now to help me? thanks in advance !12:04
kalyan i have installed cloud-init version 0.7.6 ... and i am seeing cloud-init-local or config status as unused12:04
kalyancould someone please help/correct me if i missed something..thanks12:04
smoserkalyan: cloud-init-local does need to run.12:31
kalyansmoser: Thanks, but when i tried starting it ..i am seeing the message "failed"12:37
kalyansmoser: just curious.. so it will be in "unused" state?12:42
smoserwhat is the init system ?12:49
kalyancloud init 0.7.6 on suse12:50
kalyansuse 1112:50
smoserkalyan: the init system.. sorry i'm not familiar enough to know12:52
smoserupstart ? systemd? sysvinit ?12:52
smoseryou'll have a file on your system:12:52
smoser /etc/cloud/cloud.cfg.d/05_logging.cfg12:52
smoseryou proably have a line like12:52
smoser - [ *log_base, *log_syslog ]12:53
smoserin it.12:53
smosercomment that line out12:53
smoserthen re-run and pastebin /var/log/cloud-init.log12:53
kalyanok sure12:53
do3melihey smoser. do you have some time to look at some code in https://code.launchpad.net/~d-info-e/cloud-init/+git/cloud-init/+merge/340220 ?13:08
do3melii am struggeling to find a nice way to easy parse a file that can have 2 different layouts.13:09
do3meliwhile writing tests for this branch i realized that the output of "mount" command can be different - so we have to take care of both layouts13:10
smoserdo3meli: sure13:19
smoserdo3meli: well i guess the one thing is to have some intermediate object there.13:21
smoserdef parse_mounts():13:21
smoser  """Return a representation of mounts on the system."13:21
smoser  if util.isFreeBSD():13:21
smoser      return one thing13:21
smoser    else13:21
smoser       another13:21
smoserthen use that thing13:22
smoserbut maybe that doesnt help you13:22
smoserunrelated: dont bother passing the LOG thing around . i just didn't really understand python logging when i put that stuff in (handle taking a 'log=' param)13:23
smoserjust use LOG.debug or LOG.warning13:23
smoseroh. i see so we do have 'parse_mount' . and that returns a dev path, fstype and mount point.13:24
do3meliahh did not know that. my pycharm always told me its not so nice to use a variable that has not been passed.13:25
do3melii may can get rid of get_mount_parse_regex() i am just about to put together a better regex that makes it obsolete13:27
do3melii have this regex now that matchs both formats:13:29
do3melihttps://regex101.com/r/2F6c1k/1 and the other format https://regex101.com/r/T2en7a/113:30
do3melithe problem now is that the group id's are differnet. for the first one the fs_type is group id 4 and for the second one its group id 3.13:32
smoserdo3meli: you can do names in your regex14:29
smoserand reference them by name14:30
smoserdo3meli: (?P<name>...)14:30
smoserhttps://docs.python.org/3.4/library/re.html14:30
rharpergroupdict() FTW14:31
do3melilet me try that. this would make things much easier ;)14:45
do3melinot sure that works in combination with a positive lookahead14:50
do3melior the other way around: having the if and else clause the same group name does not work. it says "name must be uniqe"14:51
do3melisee this here: https://regex101.com/r/2F6c1k/214:55
smoserdo3meli: thats neat. i'd nto seen that.16:19
do3melii think i found a solution in the meanwhile smoser16:19
do3melirefactoring that whole stuff now ;-)16:19
smosergreat. thanks.16:20
smoserdo3meli we really apprecate your contributions16:20
do3melithanks :-)16:20
do3melisaw the monday protocol btw. was not able to attend unfortunately. and most likely can't attend the next one too16:21
smoserblackboxsw: https://code.launchpad.net/~kgarloff/cloud-init/+git/cloud-init/+merge/34184416:43
blackboxswsmoser: just saw you merged it16:43
smosermerged that with16:43
blackboxswwas bringing that up. will respond on dojordan's branch16:43
smoser review-mps -v --project-name=cloud-init --git-user=smoser --merge16:43
smoserbut the related bugs did not get marked fix-committed16:43
blackboxswahh, something to tackle today. I'll re-run it and make sure the bugs get marked by review-mpos16:44
blackboxswahh, something to tackle today. I'll re-run it and make sure the bugs get marked by review-mps16:44
blackboxswgot it.16:51
blackboxswrunning now and pushing the regex improvemnt. needed to match \s* at end of line not \s+16:52
blackboxswdojordan: welcome, sorry for the delay, I'm posting a minor round of  review comment to your azuretimeout branch and testing it today. something landed in trunk today that affects the exception_cb passed to readurl.16:59
blackboxsw.. and sorry for IRC pouncing16:59
dojordanno worries, its why im here!16:59
blackboxswI'll have a patch suggestion for you shortly to see what you think. unless you beat me to it after you git fetch; git rebase master17:00
blackboxswbasically exception_cb to readurl needs to return True to retry17:02
blackboxswif it returns False the current exception gets raised17:03
dojordanyup just found that17:03
blackboxswbasically this I'm thinking //paste.ubuntu.com/p/qPd7fTp7rz/17:04
blackboxswbut wanted to test it17:04
dojordanyup, my thoughts exactly17:04
blackboxswok good deal.17:04
blackboxswI'm running through a deployment of that + tip + your branch now should clear out on your branch then in the next hour17:05
dojordanwant me to push that patch?17:06
blackboxsw+1 dojordan it'd save me time17:06
blackboxswafter a git rebase17:06
dojordansure, just running unit tests first17:06
blackboxswjust to include Kurt's changes. thanks17:06
dojordanhmm, getting a slow test: tests.unittests.test_ec2_util.TestEc2Util.test_userdata_fetch_fail_server_not_found 5.0287s . Not a chance my change of AzureDataSource affects this but just FYI17:12
smoserhm... yeah, i was just seeing that oto. will investigate, dojordan17:13
blackboxswahh good find, that tends to mean a missed requests mock17:13
smoserthanks17:13
blackboxswor a readurl/wait_for_url mis-mocked17:13
dojordan@blackboxsw pushed17:16
blackboxsw+1 I'm testing live now on a xenial instance w/ your patch ++ the minor pastbin17:16
dojordansounds good17:17
blackboxswBTW we are going to change the logic of exception_cb passed to readurl in a subsequent branch (post 18.2 release). Now exception_cb will be expected to raise an exception if warranted and ignore if retries are expected. It's more intuitive than this return True|False stuff (as you have to go re-read readurl implementation to see what expected behavior is)17:18
blackboxswthat change will then align more with wait_for_url behavior too17:19
blackboxswand we'll fix this callsite for readurl + openstack and scaleway datasources17:19
blackboxswwhich also use exception-cb17:19
dojordangreat, i'll keep my eye out for that change17:20
dojordanthanks for the warning17:20
blackboxswdojordan: landing it, both failure modes (404 versus service not present work great) thanks for the bump17:59
dojordangreat, thanks for the help!18:02
smoserblackboxsw: 2 reviews please. quick-ish.18:12
smoser https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34199518:12
smoser https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34199718:12
smosersecond is (i think) not objectionable in any way18:12
smoserblackboxsw: ping18:26
blackboxswsmoser: +1 on the second and will get through the first. didn't want to report back til finished :/18:26
powersjblackboxsw: smoser: thoughts on https://bugs.launchpad.net/cloud-init/+bug/1758409 when you have a sec18:27
ubot5Ubuntu bug 1758409 in cloud-init "integration tests: restructure ssh timeout " [Undecided,New]18:27
* blackboxsw removes python-jsonschema deb from my env as it should have failed for me locally 18:27
smoserblackboxsw: i was pinging becauase of https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34199818:29
smoserwhich dojordan pointed out.18:30
smoserif we wanted to touch that like this... or just go for the bigger fix18:30
* blackboxsw looks over read_file_or_url implemetation18:31
blackboxswdang, ok missed the third caller18:31
blackboxswhrm. I think we should just go for the bigger fix since we have context at the moment. it shouldn't be that big. OpenStack. Scaleway, Ec2 and Azure. Then we don't have to revist risk in 18.3 SRU validation too18:33
blackboxswsmoser: well, actually, I have to get through your IBMcloud run too and I'd like us to make a bionic cut today including it if we can18:34
smoserblackboxsw: sure.18:34
smoseri can work on b igger fix18:34
blackboxswso, I wouldn't be able to write up that branch. :/ so don't want to force you to do it18:34
smoserbut we can just as well take the small one  now.18:34
blackboxswyeah +118:34
blackboxswwill approve18:34
smosernote that https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34199518:35
smosermade jenkins catch the failure18:35
smoserblackboxsw: just becausae youre bored...18:37
smoser https://code.launchpad.net/~dojordan/cloud-init/+git/cloud-init/+merge/34054618:37
smoserthat has a comment on it with a bad hash18:38
smoser(ie, click the link)18:38
dojordan@blackboxsw, random question. Any reason why the upstream commit https://git.launchpad.net/cloud-init/commit/?id=2d618e27 isn't showing up?18:39
dojordanhaha18:39
smoser:)18:39
dojordani had that typed out but assumed it was a stale cache or something18:39
blackboxswinteresting.... hmm, checking how the lander got that hash18:40
blackboxswhrm hold up.18:41
blackboxswdojordan: smoser ok fixed. I had the lander sitting at pdb18:46
blackboxswit did all the launchpad work, just didn't git push18:46
dojordanhahaha18:46
dojordannice18:46
=== r-daneel_ is now known as r-daneel
blackboxswsmoser: minor tweak and then approved https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34199718:58
smoserblackboxsw: maybe it wasnt clear to you why you had jsonschema in your tox env.19:19
smoserits in requirements.txt19:19
smoserso it gets put in there by setup.py19:19
smoserso we could either deal with "optional" things in a generic way, which woudl be fine  or like this.19:20
blackboxswsmoser: yeah, I just generally had performed a pip remove of it when testing new schema additions, I forgot about that when I put up test_snap and test_ubuntu_advantage19:20
smoserbut for the moment thats the only optional19:20
smoserthis way C-I will catch it for you.19:20
blackboxswhence the tests which passed locally, (because or requirements.txt)19:20
blackboxswyeah19:20
blackboxswI like that19:20
blackboxswsmoser: and oauthlib right?19:21
blackboxswas for optional requirements19:22
smoserand pyserial :)19:22
blackboxswohh right yep19:22
smoserso we could do something more generic19:22
smoserbut the schema is the most invasive19:22
smoserthe others are very optional paths19:22
blackboxswyeah  I think your approach in tox -e xenial. it at least asserts we are exercising optional paths without the dependency19:24
blackboxswwe could come up with something a bit more generic if we have more cases I guess.19:25
blackboxswcan you rebase and push https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/341995 so we get the pretty ci green19:26
blackboxswnow that you've landed the prior branch19:26
smoserdone19:27
smoserblackboxsw: wow. MAAS comopatibiltiy testing takes 11 minutes now19:28
smoseri swear it wasnt that long before19:28
smoserpowersj: ^19:28
smoserhttps://jenkins.ubuntu.com/server/job/cloud-init-ci/19:28
smosersomething got slower... but of course i have to data to that.19:28
powersjthat's about right19:29
powersjthat was half the ci time19:29
smoserwell, it looks like its more 2/3 now19:29
smoserbut ohw ell19:30
powersjthe other times, for reasons unknown to me, seem to have gone down19:30
powersjI know blackboxsw and I found a number of test escapes last fall and fixed them19:30
powersjThe build and the integration tests specifically19:31
blackboxswright, yeah invalid mocks w/ httpretty, but yeah I don't know what else would have been improved19:31
powersjI would like to consider moving the maas compat back out and run it only nightly on trunk19:32
smoserblackboxsw: c-i happy now19:47
blackboxswthen bbsw is happy19:47
smoserand i updated the commit message19:47
blackboxswlanded19:51
blackboxswIBMcloud next19:51
blackboxswthen chrony/ntp19:51
blackboxswminor comments on https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/341774ConfigDriveReader21:24
blackboxswsans the ConfigDriveReader21:24
smoserblackboxsw: https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34200721:26
smoserthats not all the way done.. but21:26
smoserblackboxsw: i  had thought the .json thing too...21:27
smoseri dont know.21:28
blackboxswsmoser: yeah I just have a hard time looking over 3 item tuples instead of two. take it or leave it not critical by any means21:28
smoserblackboxsw: i really have to go now.21:29
smoseri'd like to have that in too, bjut just out oftime21:29
smoserif you want you can take it and just finish it.21:29
smoseri'm really 30  minutes over :-(21:30
blackboxsw+1 see ya.21:30
blackboxswhave a good weekend21:30
smoseri will pop backc in if you have aMP for upload21:30
blackboxsw+1 will have one21:30
smoserjust because that is "easy"21:30
smoserlater21:30
rharperhrm, all of the reword of the url reading makes me a little nervous, post 18.2, right ?21:35
blackboxswrharper: your comment on the ibmcloud branch.... blocker for release or tech-debt we can pickup as a separate branch?21:38
blackboxswShouldn't we update util.find_devs_with() to make use of this? or some other refactoring21:38
blackboxswsince we now have to callers to blkid?21:38
rharpernot a blocker21:38
rharperI understand the two modes21:38
rharperbut it is tech debt IMO21:38
blackboxswI see your point, lots of commonality with find_devs_with. it seems like a good candidate for consolidation though21:38
rharperfind_devs should be implemented with util.blkid() however, util.blkid needs to change to accept the parameters that are in-use by find_devs_with()21:39
rharperso, that'll be a bit of refactoring21:39
blackboxswagreed21:39
blackboxswyour comment about the reword of url reading is related to this one right? https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/34200721:40
rharperwell, there are like at least two no? the raise exception, and then the follow up ?21:41
blackboxswyeah we've landed the prior already which was to invest the readurl(exception_cb) logic to continue retries when exception_cb returns True. False == raise21:41
rharperblackboxsw: the invert and then consistent21:42
blackboxswrharper: right those have both landed, invert and consistent across 4 datasources21:42
rharper=/21:42
rharperok21:42
blackboxswyeah, it was inconsistent for OpenstackDatasource for months. resulting in long retries on 404s21:43
rharperI should have spoke sooner; those sort of changes seemed post 18.2 release, but I guess we'll just need to poke on them21:43
rharperOpenstack 404ed in what scenario ?21:43
blackboxswhttps://bugs.launchpad.net/cloud-init/+bug/170216021:44
ubot5Ubuntu bug 1702160 in cloud-init "OpenStack datasource should not retry user-data on 404" [Medium,Fix committed]21:44
blackboxswwhen no user-data is provided, it'd retry to exhaustion21:44
blackboxswinstead of bailing and continuing21:44
rharperlol21:46
rharperwhy wouldn't the file be empty ?21:46
blackboxswand finally smoser's last attempt is to change behavior of exception_cb to actually raise if needed, instead of expecting that readurl will do the raise. only reason I thought about getting that 'in' is because we are already exposed on the exception_cb changed behavior front21:46
blackboxswso might as well only cross that changed-behavior on 4 clouds once.21:47
rharpery21:47
rharperit all makes sense, just wish it was post 18.2; we have one more release before 18.04 anyhow; but I guess for bionic, at least, sooner is better21:47
rharperit does worry me re: SRU though21:47
blackboxsw+1, yeah we'll have to manually exercise upgrade path and fresh install on Openstack too (we already handle Azure/ec2). Not sure what to do about Scaleway though21:49
blackboxswI'll give ec2 a run right now with tip before we cut an MP for publish to bionic (just to make sure the system hasn't been killed)21:50
rharpery21:50
blackboxswjust tested on EC2 with tip of smoser's branch.23:08
blackboxswI'm awaiting a jenkins integration test then I'm merging and proposing a bionic release23:08
blackboxswhttps://jenkins.ubuntu.com/server/view/cloud-init/job/cloud-init-ci/922/23:08
blackboxswtested on azure earlier today with basically the same content (regarding the exception_cb behavior changes as do-jordan's branch had to account for that)23:09
blackboxswsmoser: it's up for review23:29
blackboxswhttps://code.launchpad.net/~chad.smith/cloud-init/+git/cloud-init/+merge/34201123:29
blackboxswif you wanted to enable IBMCloud in debian cloud.cfg.tmpl go4it23:29
blackboxsw:)23:29

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