[04:02] jtv: so, adding default-driver into the maas.tgt didn't h [04:02] elp [04:02] Can I have a look at the config you have now? [04:03] If you were running on a machine that has also run the old ephemerals script, before you added the --conf option to tgt-admin you would always have gotten a default-driver setting anyway. [04:04] jtv: AHA [04:04] we add that and remove the driver option in each block [04:04] and it worked [04:04] Yeah, it's the driver option. [04:04] now I get a different error, of course.... [04:04] ? [04:04] Multiple 'readonly' definitions in 'backing-store' not allowed! [04:04] ... [04:05] it seems like it hates the multiple targets in the same file [04:05] Can I see the file? [04:06] Guh. Is that root-image file seriously over a GB in size? [04:06] http://paste.ubuntu.com/7144556/ [04:06] it is [04:06] Thanks. [04:06] I hope that's very sparse... [04:06] tgt-admin is basically as bug-ridden per-LOC as you'd expect for Perl [04:06] Looks like we have two identical entries in that file... If I were tgt I wouldn't like that either. [04:07] jtv: interesting - so the list_boot_images() had two similar entries. Oh.... two purposes! [04:07] Yup. [04:07] * bigjools fixorates [04:08] jtv: did you review that branch BTW? [04:08] ah you did [04:08] Yes. [04:12] ok made the extra changes [04:12] forgot that extra close after thinking to myself that I needed to fix it, too ... [04:13] We would have caught it at some point. [04:20] jtv: bug #3453453534324, if anything fails after the maas.meta is written, the script will never try to write the tgt files on the next run [04:20] Error: Launchpad bug 3453453534324 could not be found [04:20] it exits early as it thinks it's in sync [04:21] How about we try to generate all the file contents first, and then call atomic_write to do the actual writing? [04:22] Not so much to get complete atomicity, as to put as much of the stuff that can fail before the part where we write files. [04:22] It'll break more, but when it breaks, it'll be more likely to break in a consistent nothing-got-done state. [04:22] jtv: I am victorious [04:23] Pleased to meet you, Victorinox. [04:23] we could have another state file [04:23] but yes atomic_write for state + data please [04:24] "sudo tgt-admin -s" now shows me stuff. [04:24] Good! [04:24] need to do a proper fix for list_boot_images [04:24] Will it boot? [04:24] I just hacked it [04:24] dunno I just did all this on canonistack where it's quick to delete huges files and redownload [04:25] To be clear: you don't need a fix for list_boot_images itself, just the call site, right? [04:25] Or is the boot purpose completely gone? [04:25] no, a fix is needed in extract_image_params [04:25] it is completely gone [04:26] do you fancy doing that while I test a real boot? [04:26] one thing that's annoying now is that it copies a 1.4G file [04:26] Let me just finish up what I'm doing here... [04:26] so there's two copies of it after download [04:26] Whoops. [04:27] yeah [04:27] And will the copy support holes? [04:27] that's the slowest part of this on canonistack! [04:27] no idea [04:27] sparse file you mean? [04:27] Where does the copying happen? [04:27] Yes. [04:27] not sure, looking [04:31] jtv: it uses simplestreams.objectstore [04:31] I vaguely remember something from scott about it supporting sparse files [04:31] If Scott did it, I'm sure it'll support sparse files as needed. [04:31] I don;t understand why we need to keep 2 copies of such huge files [04:31] Because IIRC the boot disk image does have holes. [04:32] it's still going to be 400Mb [04:32] I'm sure Scott would have used a link if he could... [04:33] jtv: do we still need that policy hack? [04:33] No. [04:33] Should be supported directly by the code now. [04:34] cool [04:34] ta [04:44] jtv: how are we supposed to put an arch list in the filter in pserv.yaml? [04:44] I tried a list and it says it needs to be a single value [04:45] It does. [04:45] I am guessing it wants a filter [04:45] which leaves me itching [04:45] If you need multiple arches but not '*', define multiple sources. [04:45] ! [04:45] srsly? [04:46] srsly. But easy enough to change. [04:46] I'm hammering a little bit of abstraction into that code as we speak. [04:46] * bigjools adds a card [04:46] I'm supposed to be adding logging, but in order to log what's going on, we need to know what's going on. [04:47] yes :) [04:47] jtv: also the error reporting from a dodgy pserv.yaml is ugly as hell with a stacktrace [04:47] * bigjools files another card [04:48] jtv: do you know if we fixed the bug where we still need i386 when booting amd64? [04:50] Don't know [05:05] christ it's slow to download [05:05] 82M in 15 minutes [05:57] jtv: ok done, attempting boot [05:59] jtv: 2014-03-24 15:57:06+1000 [TFTP (UDP)] Datagram received from ('10.0.0.104', 49155): [05:59] darn [05:59] That means pxeconfig didn't find a matching image. [06:00] yup [06:01] jtv: AND it thought it was enlisting, and it was an installation boot [06:01] this is using FPI [06:01] Enlistment vs. installation is decided by... the database, right? [06:01] let's see what bootimages are there [06:02] Unknown node gets enlistment image? [06:02] if "node" is set, yes [06:02] basically if there's a recognised MAC in the request [06:02] (For some reason my twistd stopped using up gobs of memory) [06:03] I'll watch the console this time, one sec [06:07] it sends the mac [06:12] contents of BootImage look ok [06:15] jtv: so basically this code fails to find an image: [06:15] latest_image = BootImage.objects.get_latest_image( [06:15] nodegroup, arch, subarch, series, purpose) [06:17] Mismatch between purpose names..? [06:18] trying to use the harness to see what it would be using [06:19] What I like to do is "open('/tmp/foo.log','a').write("Got purpose: %s\n" % purpose)" [06:19] jtv: aaaaa [06:19] no "xinstall" [06:19] xinstall!? [06:19] yeah [06:19] see get_boot_purpose() [06:19] Oh, this is while installing? [06:19] yes [06:19] And do the boot purposes in the database still say xinstall? [06:20] Try "sudo maas-region-admin dbshell --installed" [06:20] no [06:20] they just have commissioning and install [06:20] Ah. Well there we go. [06:20] I downloaded the trusty amd64 images [06:20] and it set those up [06:21] Will the classic installer work? [06:21] let's see [06:22] jtv: working [06:23] ok so [06:23] not sure what to do here. are we getting rid of "purpose" or not ... [06:23] oh ha spoke to soon [06:23] d-i stopped with debconf message saying "no kernel modules found" [06:26] Missing initrd..? [06:26] Well, no, it wouldn't be missing I guess or you'd fail during pivot(). [06:26] Or so I seem to remember. [06:26] mismatching kernel version vs modules version [06:27] I suspect crap data coming from simplestreams [06:27] That would be pretty awful. [06:27] But what if it's a filtering problem somewhere? [06:27] in what way? [06:27] Maybe there's an arbitrary, unstable choice between similar images. [06:28] there's only one image [06:29] jtv: ok so let's go back to xinstall [06:30] extract_image_params() only reports commissioning and install, and we want to get rid of those. Do we now need to differentiate boot purpose here like that in get_boot_purpose? [06:31] it looks like we still depend on that purpose to select a different preseed for the FPI [06:33] There's an irony there. [06:36] I suppose you could just add xinstall to the list of purposes in extract_image_params..? [06:36] By the way, it does look as if the files that the import script puts in the snapshots are links into the cache, as you'd expect. [06:37] jtv: I can but we also depend on that list only having a single item for the report_boot_images call to work [06:37] sorry list_boot_images [06:37] which sets up the tgt targets [06:38] Shouldn't that code just strip off the purpose and run the rest of the images' data through a set to eliminate duplicates? [06:39] sorted( { (img['arch'], img['subarch'], img['release'], img['label']) for img in list_boot_images(...)}) [06:40] Or more legibly: [06:40] sorted({ [06:40] (img['arch'], img['subarch'], img['release'], img['label']) [06:40] for img in list_boot_images(...) [06:40] }) [06:40] that's one way to fix it, not sure if it's the best [06:41] Well it's only this use of the boot images that needs them to be unique despite ignoring the purpose, right? [06:41] we don't really need to discern the difference when selecting a boot image [06:41] they are all the same now [06:41] Then we should drop BootImage.purpose. [06:41] indeed [06:41] Just... not now :) [06:42] well I'll take it out of the code and see how it goes [06:42] I put "xinstall" in the list for now [06:43] looking good so far [06:47] boom [06:48] cloud-init crashed ot because: [06:48] --2014-03-24 06:44:26-- http://10.0.0.9/MAAS/static/images/amd64/generic/trusty/xinstall/root.tar.gz [06:48] Connecting to 10.0.0.9:80... connected. [06:48] HTTP request sent, awaiting response... 404 Not Found [06:48] 2014-03-24 06:44:26 ERROR 404: Not Found. [06:48] somewhere else that needs purpose eliminating [06:54] By the way, there's some code in the new import script that checks if the JSON in the maas.meta file already matches the latest data, but it doesn't sort dict keys so that might be a little arbitrary. [06:54] I'm dumping the json with sorted keys instead. [06:55] ok [06:56] jtv: ARGH. The curtin installer expects the root.tar.gz to live under tftp, as served by apache [06:58] Huh? [06:59] You mean that it expects to be able to access the tftp tree through http? [07:01] there's apache config to mirror it at /MAAS/static/images/ [07:02] we need to fix the packaging for this. [07:02] dammit [07:04] Not a good time. [07:09] jtv: also, another problem [07:09] get_curtin_userdata() needs to know the label in the path now [07:09] not sure how it's going to do that [07:11] We have the label in the path now, don't we? [07:14] yes [07:19] bigjools: care to have a look at this tiny fix? https://code.launchpad.net/~rvb/maas-test/fix-new-option/+merge/212356 [07:20] rvba: done [07:20] Ta [07:22] I am this -><- close to FPI installer working [07:26] FPI success! \o/ [07:26] \o/ [07:26] \o/ [07:26] it was a *hack* though [07:26] still have a problem to fix as I describe in the email [07:26] * bigjools hands baton to rvba [07:27] bigjools: question about the first item in your email: [07:27] yarp [07:27] You said we could do away with the purpose in boot images. [07:27] I don't think we want that. [07:27] ok, go on [07:28] Right now, when we import stuff, for each "selection" (arch/subarch/series[/soon:label]) we import both the ephemeral and the install image. [07:28] yes [07:28] But in the future, we thought it would be nice to let the use select what image he wants to import. [07:28] The reason being that the ephemerals are huge. [07:29] And the install images are not. [07:29] yes [07:29] as things stand, purpose is useless though [07:29] So you might want to download the ephemerals for just, say, trusty/amd64/generic. [07:29] When this is the case the purpose will be useful. [07:30] ok [07:30] I don't disagree [07:30] go with the first option to fix then [07:30] * bigjools heads to dinner. back for call === ging_ is now known as ging [07:54] jtv: one question about https://code.launchpad.net/~jtv/maas/write-tgt-data-at-once/+merge/212358 [07:55] jtv: Unless I'm mistaken, you didn't solve the problem where the same entry gets written multiple times in the tgt config file… right? [07:55] jtv: which is fine btw, I just want to be sure. [07:55] No, that's a separate problem which Julian worked on. [07:55] Okay. [07:56] My take was: just turn the data into tuples, without the purpose, and put them in a set to eliminate duplicates. [07:56] That's the problem I started working on. [07:56] Ah. [07:56] I thought Julian said he was doing that. [07:56] I didn't catch that. [07:57] No, we talked about it just now (see above). [07:57] Ah. [07:57] I'll take care of it. [07:57] OK [07:57] Once I'm done with your review. [07:57] Thanks. [07:59] There will be conflicts in the branch after that, but nothing serious. [08:03] jtv: branch approved! [08:03] Thanks. === CyberJacob|Away is now known as CyberJacob [08:23] jtv: would you reciprocate? https://code.launchpad.net/~rvb/maas/fix-list-boot-imgs/+merge/212363 [08:24] Honour demands it. [08:24] heh [08:26] rvba: in trying to figure out what the code does, I did do a bit of refactoring — which will also facilitate my ongoing work. [08:26] jtv: I see that. [08:26] Can't log what's going on without knowing what the code means. :) [08:26] Makes sense. [08:27] I'm turning the "arch" config into an "arches" — which will benefit from the new helpers. [08:28] Hang on. [08:29] Not sure this is appropriate. [08:29] Because the subarches list really only makes sense for a particular architecture. [08:30] jtv: if we turn 'arch' into a list we will end up with the same mess that we have now where the import script imports a huge product of things. [08:30] True — but what's the harm in a filter that allows 'generic' and 'highbank' for armhf and i386? [08:30] That's precisely why we have a 'selections' list. [08:30] jtv: In this case it would be fine but in the general case, it won't make sense. [08:31] And can lead to import more things than you thing… which — I think — I bad. [08:31] s/thing/think/ [08:32] I agree that it can be used for evil, but is it our job to prevent that? The filters within one selections stanza form a Cartesian product, which I think is fine for the usual "i386/generic + amd64/generic"—style situation. [08:32] When the Cartesian product gets out of hand, split up the selections. [08:33] Wouldn't a comment suffice? [08:33] Hum, maybe… [08:34] I think that by renaming that field to 'arches' we encourage a potentially dangerous practice. [08:34] We make it possible. Potentially dangerous is not the same as bad. [08:34] But maybe a well-written comment will suffice. [08:35] I'll document it carefully. [08:35] Okay. [09:00] rvba: whoops, there's no set.append(). :-) [09:01] jtv: whoops… fixing… [09:01] Did you say my logging branch was dangerous and needed testing before landing? :-P [09:02] yeah :) [09:03] jtv: I just pushed a fix. Sorry about that. [09:04] No worries. It'll just make me feel slightly less guilty next time I break something. :) [09:04] heh [10:46] I'm getting breakage on the new import script, looks related to the simplestreams data: [10:46] arch, subarches = item['arch'], item['subarches'] [10:46] KeyError: u'subarches' [10:52] Trying with the -v2 data. [11:18] I unsubbed maas-maintainers from https://code.launchpad.net/~maas-maintainers/maas/new-import-script-integration. Please add yourselves manually if you need. [11:53] My last import run went suspiciously smoothly. [12:23] Not much luck booting with the new images yet... unhandled error during Deferred. :( [12:24] rvba: https://code.launchpad.net/~jtv/maas/multi-arch-imports/+merge/212392 [12:25] That's the one we discussed. Hope you find the comments clear enough. [12:25] k, I'll have a look in a sec. [12:33] jtv: here is a review for you if you have time: https://code.launchpad.net/~rvb/maas/fix-curtin-url/+merge/212402 [12:33] Looking. === cmagina-away is now known as cmagina === cmagina is now known as cmagina-away === cmagina-away is now known as cmagina === roaksoax_ is now known as roaksoax === cmagina is now known as cmagina-away === zchander is now known as _zchander_ === cmagina-away is now known as cmagina === tooth_ is now known as tooth === teknico__ is now known as teknico === cmagina is now known as cmagina-away === cmagina-away is now known as cmagina [17:57] blake_r: Hello. How’s the UEFI refactor branch doing? I’m eager to review and land it, because my next task is to port it to the new boot resources importer. [17:58] allenap: just updated it to the lastest trunk, cut the diff in half [17:58] allenap: I am porting the uefi script port to the new simple streams [17:59] blake_r: Hehe, that’s grand. I’ll review the first bit if you want. [17:59] allenap: yeah go ahead and start reviwing [17:59] allenap: I will get the rest in here soon [18:00] blake_r: Create a merge proposal for it and I’ll do it. [18:00] allenap: there is one, let me get the link [18:00] allenap: its in wip, want it set to review? [18:00] blake_r: Yeah. [18:00] allenap: done [18:00] Tip top. === zchander_ is now known as zchander [19:13] Hello! Is there a way to specify cloud-init user-data for maas? [19:26] manjiri_: can you be more specific? Do you want this for enlistment, commissioning or deployment? [19:27] (and if for deployment, then during install stage, or for final boot?) [19:28] rbasak: Deployment. I want to wget a file at the end. [19:29] rbasak: Install stage, I think. Can you explain what is "final boot" ? [19:30] manjiri_: what I mean by "final boot" is the boot that your MAAS client (eg. juju) will get. [19:33] rbasak: My goal is make this "wget" part of "staging" rather than during "juju deploy". But I can settle for it to be during "juju add-machine". === roadmr_nothere_f is now known as roadmr [19:35] manjiri_: juju controls cloud-init userdata to actually boot juju machines. I'm not aware of any mechanism to control that. [19:36] manjiri_: what's the purpose of your wget script? [19:36] manjiri_: if there's a one-off action you want on all MAAS-deployed juju nodes, you could do that in the installer. [19:36] manjiri_: either by preseeding d-i (if using d-i), or a suitable curtin hook (for the fast path installer; I know less about this) [19:36] rbasak: Yes that is it. How do I "do that in the installer". ? [19:37] manjiri_: if using curtin then I guess you could use cloud-init userdata, but I think that would apply before the installer has finished [19:38] rbasak: Got it. This is what I had surmized but I wanted to confirm. Thanks! === roadmr is now known as roadmr_afk === roadmr_afk is now known as roadmr [19:39] rbasak: Any pointers for more info on "curtin hooks" ? [19:43] allenap: just pushed the install_bootloader from the UEFIBootMethod, should all be their now [19:43] rbasak: Any pointers on making the URL arg for wget a config option? [20:00] manjiri_: http://bazaar.launchpad.net/~curtin-dev/curtin/trunk/view/head:/doc/topics/overview.rst#L112 [20:00] manjiri_: I'm not sure how curtin's config is generated. Probably via templates in /etc/maas or something. [20:09] maas user interface does not talk to or sets up dns/dhcp | http://askubuntu.com/q/438705 [20:12] rbasak: Thanks! I think a late or final command should do the trick. There are no examples to parametrize the URL through GUI/CLI. For now, hardcoding seems to be the only option. [20:19] manjiri_: the templates let you execute arbitrary Python and access the data model (IIRC). [20:19] manjiri_: But, I don't know of any means to put arbitrary parameters into the data model that you can then use. [20:20] manjiri_: you can apply arbitrary tags which you could probably get to from the template, if that helps. [20:20] (and of course anything you do in this area might break in a future release) [20:21] rbasak: Good advice. Thanks! === cmagina is now known as cmagina-away === roadmr is now known as roadmr_afk === cmagina-away is now known as cmagina [21:52] blake_r: Your packaging change looks good, but I’d prefer for roaksoax to see it before it lands; there may be some paperwork to do this close to release. === cmagina is now known as cmagina-away === cmagina-away is now known as cmagina [22:47] hi guys - any word on maas for arm devices === cmagina is now known as cmagina-away [23:47] Valduare: what specifically are you looking for? [23:47] looking forward to the day when all these little mk902 style devices could be used with something like MaaS :P [23:48] maas supports armhf, I don't know much else about the devices themselves [23:49] i dont know much about maas yet [23:49] someone was telling me it powers down the devices, pxe wol stuff? [23:49] wol cannot power down [23:49] but maas supports many power typesa [23:50] does this require a custom u-boot or anything? [23:50] or can I start playing with a few of my little mk808 devices that are running an ubuntu server armhf rootfs [23:50] possibly, yes. The image that is served up depends on the boot request path [23:50] let me just double check the path [23:52] ok so if uboot TFTP requests default-armhf or default.armhf it should work [23:54] hmm [23:55] so is it just u-boot on the device and kernel and rootfs are tftp over?