/srv/irclogs.ubuntu.com/2014/06/02/#maas.txt

=== vladk|offline is now known as vladk
=== CyberJacob|Away is now known as CyberJacob
gmbjtv: Where do we stand with the bootresources.yaml killage? I see a bunch of cards on the board but I assume that they’re just going to wither and die now.06:37
jtvgmb: the killage in itself is done.06:38
gmbWewt06:42
gmbjtv: So we’re left with documentation and then UI stuff… What’s the word on the latter?06:43
jtvgmb: didn't we halt work on the latter?  The documentation is really just for making people aware of the change — the new way of doing things is already documented.06:44
gmbjtv: Yeah, we did, but I haven’t pored through all my email yet, so I wanted to check that we’re still halted :)06:44
bigjoolsjtv, gmb: ui is deeeed. long live the ui07:18
gmbbigjools: That’s *precisely* the conversation that I’m thinking could have happened somewhere :)07:18
gmbI’ve removed the UI cards anyway… we can always put ‘em back.07:19
bigjoolsgmb: yeah, well...07:26
gmbRuh roh07:27
bigjoolsrvba: halp. django.07:27
bigjoolsself.filter(ip__gte=range_low, ip__lte=range_high)07:27
bigjoolsresults in:07:27
bigjoolsTypeError: argument of type 'IPAddress' is not iterable07:27
bigjoolsdafuq07:27
rvbahum…07:28
bigjoolsip is a GenericIPAddressField so I guess I need to do something07:28
rvbaWeird that you're getting the error "is not iterable".07:28
rvbaNothing looks like it needs to be iterable in your query.07:29
rvbaDo you have the full stacktrace?07:29
bigjoolsI am07:29
bigjoolserr I do07:29
rvbaYou're a stacktrace?07:29
rvbaPlease dial 911!07:30
bigjoolshttp://paste.ubuntu.com/7571266/07:30
bigjoolsno such number07:30
bigjools:)07:30
rvbabigjools: looks like the operators for the GenericIPAddressField expect strings (not IPAddresses).07:32
bigjools!07:32
bigjoolssigh07:32
bigjoolsthanks rvba07:32
rvbabigjools: They use "':' in value" to check if the value you give them is IPv6 or not.07:32
bigjoolsyeah07:33
bigjoolsrvba: I also have a dilemma07:33
bigjoolsrvba: my new model is called IPAddress which clashes nicely with the one in netaddr :(07:33
rvbaAh, right.07:34
bigjoolsgonna have to rename it I think, otherwise confusion will likely ensue07:34
rvba+107:34
bigjoolsunless we prefix it everywhere07:34
bigjoolssuggestions for a new name?07:35
* rvba thinks…07:35
rvbaNodeIPAddress?07:35
rvba(Or is this going to be used to store non-node IPs as well?)07:36
=== vladk is now known as vladk|offline
bigjoolsyes07:44
bigjoolsI need to fix the column name called "type"... wasn't thinking too hard about that one07:45
rvbaDeviceIPAddress then?07:45
bigjoolsrvba: StaticIPAddress07:48
bigjoolssince that's what it is07:48
bigjoolsand no more07:48
bigjools:)07:48
rvbaYeah, sounds good.07:48
bigjoolsthey will be used for non-devices as well07:48
bigjoolsVIPs07:48
* bigjools hax-rs07:49
jtvManagedIPAddress?07:52
bigjoolsthey're not all managed07:59
MosibiHi all.08:13
MosibiIs this the right channel to ask for a MAAS problem? :: "No matching node is available" with juju deploy nova-compute08:14
jtvMosibi: yes, this is the right channel — at least for the MAAS part.  It's possible that the origin of the problem is somewhere else, but let's have a look.08:22
jtvThe error message means that a node was requested, but there was no node in the Available state that matched all of the constraints given in the request.08:22
=== vladk|offline is now known as vladk
Mosibijtv: in tried several times, with and without setting constraints.08:38
MosibiCould it be that there are constraints that i do not see?08:39
jtvYes, that's quite possible.08:39
Mosibiokay...08:39
MosibiIs there a possibility to show/extract that constraints?08:39
MosibiSetting MAAS in debug mode did not show me anyhting more i allready knew.08:40
rbasakMosibi: I've seen constraints embedded in the HTTP GET URI inside one of the log files in /var/log/maas/08:52
rbasakI'm not sure if that's still the case but it maybe that will help?08:52
rvbabigjools: happy to have a pre-imp about the DHCP work now if you're available.08:55
bigjoolsrvba: bien sur08:55
jtvMosibi, rbasak: Yes — some clients will pass those parameters in that way — I think those would go in /var/log/apache2/access.log though.08:55
bigjoolsrvba: I'll head back to same hangout08:55
rvbaokay08:55
rvbabigjools: s/sur/sûr/ (sur ~= dessus, sûr = certain)08:56
jtvWeird place for a vestigial ‘s’...08:58
gmbjtv, rvba, bigjools, allenap: A review, if you please: https://code.launchpad.net/~gmb/maas/update-changelog-bootresources.yaml/+merge/22167809:00
jtvComing.09:00
gmbHad to invent the 1.5.2 release for the sake of the update…09:00
Mosibirbasak and jtv: thx will have a look at the httpd logs09:01
MosibiSadly i could not find any contraints in the httpd log files.09:12
MosibiI noticed when i force a tag on one off my 'ready' machines in MAAS and after that, do a juju deploy with --contraints tag=mytag, the deployment starts09:13
rbasakMosibi: did you set constraints when you bootstrapped the environment?09:15
rbasakIIRC, that sets default constraints. There is a command to change the default.09:15
Mosibirbasak: nope, i did not set any constraints when i bootstrapped the environment.09:18
Mosibilet me explain what i am trying/doing :)09:19
Mosibii am building a demo openstack environment with juju and allready deployed the openstack components with juju09:20
MosibiSo i have, keystone, cloud-controller, quantum-gateway etc...09:21
MosibiThus i have a working MAAS/Juju env.09:21
MosibiNow i want to deploy a nova-compute host and i have 4 (virtual :: KVM) compute nodes available in MAAS.09:22
MosibiAnd that's te troubling part..09:22
Mosibi+h somewhere :)09:22
MosibiTo me it looks like the nova-compute charm should have set some constraints (i need x mem and minimaal x CPU's), but i can not find any of that in the charm itself.09:24
jtvMaybe even a constraint to ensure that you get a physical machine.  I guess that might explain what's happening — if we can find it.09:24
rbasakMosibi: you would do that in your deployment yourself, or via your bundle I think. It sounds to me that MAAS is doing exactly the right thing for you, and that you have a juju question if anything. Try #juju for more expertise maybe?09:25
MosibiSince MAAS is returning the 'No matching node is available', i would love to see the list of contraint MAAS is working with.09:25
jtvNo reason to show those in the error message, really.  I'll file a bug about that.09:26
jtvNo reason *not* to, I mean!09:26
Mosibirbasak: indeed, it looks like a juju problem, but i would like a more 'verbose' notice from MAAS09:26
Mosibijtv: :)09:26
Mosibijtv: thx!09:27
Mosibirbasak: also thx for your insights09:27
MosibiI'll switch to #juju :)09:27
jtvAh, we already have bug 1274085 — but the counter-argument is that MAAS returns a raw API error, and maybe it's up to Juju to show what it was trying to do (at a higher level of abstraction).09:28
ubot5bug 1274085 in MAAS "error when maas can't meet juju constraints is confusing and not helpful" [Wishlist,Triaged] https://launchpad.net/bugs/127408509:28
Mosibijtv: that's a 'he, but we aren09:29
Mosibi't doing anything wrong'09:29
MosibiSince MAAS is receiving the call, more verbosility would be welcome and more important: it would lower the support calls in #maas :)09:30
jtvYes, I agree our message could be clearer.  I can probably just fix the message.09:30
Mosibijtv++;09:31
Mosibi:)09:31
jtvIt may be that Juju can do a better job, but that's not in itself an argument against not doing one ourselves.09:31
Mosibiidd09:31
gmballenap, jtv, rvba: anyone free for a preimp about https://bugs.launchpad.net/maas/+bug/1312844?10:09
ubot5Ubuntu bug 1312844 in MAAS "MAAS commissioning page shows distributions that are not available" [High,In progress]10:09
jtvgmb: will be in a minute10:15
gmbjtv: Okay, call me when you’re ready.10:15
jtvWill do.10:16
jtvgmb: rinnggg10:18
gmbTotal lack of notifications10:18
jtvMaybe I invited your wrong persona.10:18
bigjoolsthere's JS lint... how did that appear I wonder10:34
jtvThere seems to be some weirdness where sometimes lint just doesn't get reported.10:41
bigjoolsrvba: https://code.launchpad.net/~julian-edwards/maas/allocate-static-ip/+merge/22170210:42
bigjoolsand now I shall EOD10:42
bigjoolsjtv: do you have an IRC notification on the word "lint" ? :)10:42
jtvHey, the NSA's got to be good for _something_...10:43
=== vladk is now known as vladk|offline
jtvIt may be version skew, or something at a low level limiting itself to revision-controlled files, or something.10:44
=== vladk|offline is now known as vladk
jtvallenap: session-level locks... but the locking code opens and closes a dedicated cursor for each locking command.  Do we know that those cursors are on the same session..?11:01
allenapjtv: That’s up to Django ;)11:08
allenapjtv: Maybe it should keep that cursor around?11:09
jtvThen that would explain the problem...11:09
=== vladk is now known as vladk|offline
allenapjtv: If the session is going away, then that’s Django’s responsibility I think, though it might just be going away because of garbage collection, in which case holding the cursor should prevent that.11:15
=== vladk|offline is now known as vladk
=== vladk is now known as vladk|offline
=== vladk|offline is now known as vladk
allenapjtv: Do you think it’s worth trying to validate that, or should we just go straight to keeping a reference to the cursor around?11:41
jtvallenap: it really ought to be the same session that's performing the locked operation.12:02
rvbajtv: Although Julian's solution is probably good as a first step, I seem to remember you had a better idea, to allocate new IP addresses, than select one in the allowed range different from the pool of existing allocated IP addresses.  This solution is a bit racy, obviously.12:05
jtvrvba: not sure I fully undestand you, but that sounds like how we thought our existing scheme would work — which might work with a different dhcpd.12:23
rvbajtv: this is about the code Julian mentioned this morning.12:23
rvbaThe code to allocate a new IP address.12:24
jtvOh, for picking a free address.12:24
rvbaYeah.12:24
jtvRight.  The idea there was to cache a pool of available addresses.12:24
rvbacache?12:25
rvbaThis means like a weird way to second-guess the DB…12:25
jtvThat's pretty much what caches are.  The database is the source of truth, but a cache can help find efficient "guesses."12:26
rvbaRight.  Well, I guess that's probably something we can do as a second step.12:26
rvbaLooks like an optimization.12:26
jtvExactly.  It's optimisation.12:26
=== vladk is now known as vladk|offline
=== vladk|offline is now known as vladk
gmballenap: Is there “nice” way to untangle where a circular import is creeping in? I see errors that are utterly unrelated to where I’m working at the moment and it’s highly frustrating to have to comment stuff out, especially in a big file.12:52
gmbrvba, jtv: That question was for you too; I jsut wanted to engage the Gavinator…12:57
rvbagmb: the only solution I know is the local import.12:58
gmbrvba: Yeah, I know the solution, I’m trying to find a nice way to identify the actual problem imports.12:58
rvbaOh, I see.12:59
gmbSo I’m working on maasserver.forms and I see things like:12:59
gmb  File "/home/graham/workspace/maas-work/maas/src/maasserver/views/clusters.py", line 45, in <module>12:59
gmb    from maasserver.forms import (12:59
gmbImportError: cannot import name NodeGroupEdit12:59
gmbI know that maasserver.forms has the problem but it has 80 lines of imports :)12:59
gmbAnd I don’t know which one to kill with fire.12:59
rvbaIn Django, it's usually the models that are the problem.12:59
gmbWell, that helps a bit… It at least gives me a place to start, which is better than my current scattergun approach.13:00
=== vladk is now known as vladk|offline
allenapjtv: I have discovered that Django closes the connection when it pleases, so DatabaseLock.__enter__() and .__exit__() can run in entirely different sessions.14:30
allenapjtv: It explicitly closes it too, so hanging onto a reference does no good.14:30
allenapI feel that Django owes it to us to remove itself from the MAAS codebase.14:32
jtvallenap: it can't reasonably close a connection while it's in a transaction though, so if we can get a hold of our "regular" DB session, we'll be alright.14:45
allenapjtv: Ensuring that the _session_ lock is taken within a _transaction_ seems to satisfy Django.15:02
jtvallenap: satisfy in what way?15:02
allenapjtv: It keeps the connection open.15:04
allenapAnd thus the session.15:04
jtvIs that a promise?  Or could there be some pool with its own eviction policies?15:04
allenapjtv: I’ve added a check to DatabaseLock.__exit__() to ensure that it’s actually released a lock that it held. That ought to keep us on our toes.15:05
jtvThanks.  At least it'll give us a more precise failure.15:06
allenapjtv: If you’re around, would you mind having a look at https://code.launchpad.net/~allenap/maas/database-locks-revisited/+merge/221762?16:03
jtvNot at all.16:03
allenapThanks :)16:03
jtvallenap: done16:09
allenapTip top, thanks jtv. I hope this will plug the problem.16:15
jtvAs we say in Dutch, I'll help you hope.16:17
allenapHeh, I like that.16:20
=== vladk|offline is now known as vladk
blake_rallenap: could you do a review of this review!16:39
blake_rallenap: https://code.launchpad.net/~blake-rouse/maas/powernv-support/+merge/22084016:40
allenapblake_r: Sure. OTP right now, I’ll do it later. Is that okay?16:40
blake_rallenap: i think roaksoax was wanting it really soon, for sru16:41
blake_rallenap: anyone else around maybe?16:42
allenapjtv, gmb: Either of you free for urgent review? ^16:42
jtvI can take it.16:42
blake_rjtv: thanks16:42
jtvIs it Blake's?16:42
jtvThat answers that.  :)16:42
blake_rjtv: yeah16:42
blake_rjtv: so don't be to harsh!16:43
blake_rjtv: also jhobbs already did a review on it16:43
jtvI'll be harsh if it's huge!16:43
blake_rjtv: <80016:44
blake_rjtv: like requested!16:44
jtvTook me a while that wasn't an emoticon... "obese KKK member" or something.16:44
jtv*to figure out16:45
blake_rHaha!16:45
jtvblake_r: Jason is right about the factory convention.  We try not to be fanatical about it, but it does help answer the question "where from?"16:51
jtvAhem.  That's a bit non-ab-ovo.  I mean: we do usually prefer "make_foo" factory functions over "get_foo" ones.16:51
jtvNow all you need to do is read my messages in the wrong order.  :)16:51
blake_rjtv: no make_mac_address in pserv16:52
blake_rjtv: did want to add to the line count, :)16:53
blake_rjtv: didn't*16:53
jtvIf it's for testing, there's one in maastesting.factory.  But it follows an aberrant convention: getRandomMACAddress.  :(16:53
blake_rjtv: yep, the one i used!16:53
jtvOn another arbitrary note, compiling regexes probably isn't useful in many situations.  IIRC there's transparent caching for those million-in-a-row cases.16:56
jtvNot that I'm against it, but if it gets in the way, don't let your conscience stop you.16:59
=== jfarschman is now known as miles_
rvbaallenap: looks like your recent modification broke the build.17:16
rvbaallenap: d-jenkins.ubuntu-ci:8080/view/MAAS/job/utopic-adt-maas/54/17:16
rvbaallenap: paste.ubuntu.com/7574376/17:16
allenaprvba: Hey, that’s great news! Really :)18:09
allenaprvba: I’ll investigate this evening.18:10
allenaprvba: Is that CI of trunk?18:10
=== vladk is now known as vladk|offline
=== CyberJacob is now known as CyberJacob|Away

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