*** rcarrillocruz has joined #openstack-shade | 00:05 | |
*** jamielennox has joined #openstack-shade | 00:33 | |
jamielennox | mordred: here's my associate task: https://etherpad.openstack.org/p/CkDOrWTIUr | 00:34 |
---|---|---|
jamielennox | which is a little abstracted i guess | 00:35 |
jamielennox | mordred: but you can see invocation that i asked for device /dev/xdva (which was supposed to be xvda - but whatever, didn't work that way either) | 00:39 |
jamielennox | and it returned attachments.0.device == /dev/vdb | 00:39 |
jamielennox | i don't have access to the logs of that OS deployment, can i make shade/ansible give me logs? | 00:40 |
mordred | jamielennox: no - sadly the openstack apis do not provide any mechanism to get logs | 00:41 |
mordred | jamielennox: also - sadly enough - specifying a device name also does not always work AIUI and is somewhat driver specific | 00:42 |
jamielennox | mordred: i didn't expect server side logs, i just thought maybe i could see the shade debug output or something | 00:42 |
mordred | oh! shade debug output :) | 00:42 |
mordred | no - but it's a thing I was just running up against a couple of days ago and think we should ad | 00:42 |
mordred | add | 00:42 |
jamielennox | but ugh, specifying device name not being respected is terrible | 00:42 |
mordred | (basically, something that would collect logger info and return it in a variable or something) | 00:43 |
mordred | jamielennox: I'm about to EOD/AFK - but can take a first stab at getting shade debug logs returned in os_ modules when I wake up | 00:43 |
jamielennox | mordred: it'd be interesting to have - thanks, it sounds like either way i'm going to have to work around it | 00:44 |
mordred | yah. sorry I can't be more immediate help | 00:46 |
mordred | clarkb: ^^ do you remember any specific pain about cinder volume device name stuff ? | 00:46 |
mordred | clarkb: (other than "it makes us want to stab our eyes out" ?) | 00:46 |
jamielennox | mordred: the same things seems to be happening with OSC so i'm guessing it's not shade's fault after all | 00:47 |
mordred | jamielennox: \o/ | 00:47 |
clarkb | mordred: yes xen is different than kvm | 00:47 |
mordred | jamielennox: completely unrelated - but I _LOVE_ requests_mock .. thank you | 00:47 |
clarkb | you haveyo use api for xenhave to use dev name stuff for kvm | 00:47 |
clarkb | if you dont the info for the other may be wrong | 00:48 |
jamielennox | mordred: :) i'm actually really happy with how that's turned out | 00:48 |
jamielennox | i do need to doc it better, there were some definite improvements to the API that are mentioned in the docs but not the main way operations are shown | 00:48 |
jamielennox | clarkb: i didn't follow that | 00:49 |
jamielennox | i'm getting it's out of my control, but the xen/kvm api stuff | 00:49 |
clarkb | jamielennox: with xen the only way to find out what deviceyou atta hed to is via nova/cinder apu | 00:49 |
clarkb | with kvm that api is often wrong | 00:50 |
jamielennox | :( | 00:50 |
jamielennox | the mind boggles that any of this actually works | 00:50 |
clarkb | you have to use /dev/disk/by-name orsomething instead with kvm | 00:50 |
clarkb | where you get a name that is the prefix of the cinder uuid | 00:51 |
clarkb | but its not q full uuid bcause /dev entries cant be that long | 00:51 |
jamielennox | yea, that comes up, but i'm creating some servers via ansible so i'm not sure how i can mount/format that reliably by id | 00:51 |
mordred | jamielennox: I _think_ under kvm it shows up as /dev/disk/by-name/{name-of-device-in-cinder} or something | 00:51 |
mordred | jamielennox: like, on review.openstack.org, our volume for gerrit is at /dev/disk/by-label/gerrit | 00:52 |
mordred | this only works for kvm - but I'm guessing yo udon't have any xen clouds laying around | 00:52 |
clarkb | oh it might be by-label not by name | 00:52 |
jamielennox | gah, ok so | 00:53 |
jamielennox | ubuntu@logs:/dev/disk/by-id$ ls | 00:53 |
jamielennox | virtio-8626f2fb-3c7a-4218-8 | 00:53 |
mordred | jamielennox: try ls in /dev/disk/by-label | 00:53 |
jamielennox | and volume list is 8626f2fb-3c7a-4218-8c0c-c553d9269655 | bonnyci-logs | 00:53 |
mordred | hahahahaha | 00:53 |
mordred | yay! let's just truncate | 00:53 |
jlk | oof | 00:53 |
jlk | how does AWS do this? /me ducks | 00:53 |
jamielennox | actually by-label just has cloudimg-rootfs | 00:53 |
mordred | lovely | 00:54 |
mordred | jlk: don't even get me started :) | 00:54 |
jamielennox | paste | 00:54 |
jamielennox | ubuntu@logs:/dev/disk$ tree | 00:54 |
jamielennox | . | 00:54 |
jamielennox | ├── by-id | 00:54 |
jamielennox | │ └── virtio-8626f2fb-3c7a-4218-8 -> ../../vdb | 00:54 |
jamielennox | ├── by-label | 00:54 |
jamielennox | │ └── cloudimg-rootfs -> ../../vda1 | 00:54 |
jamielennox | ├── by-path | 00:54 |
jamielennox | │ ├── virtio-pci-0000:00:04.0 -> ../../vda | 00:54 |
jamielennox | │ ├── virtio-pci-0000:00:04.0-part1 -> ../../vda1 | 00:54 |
mordred | jlk: you know how AWS solves our hard problem of figuring out what IP to use right? ... they use ... DNS | 00:54 |
jamielennox | │ └── virtio-pci-0000:00:06.0 -> ../../vdb | 00:54 |
jamielennox | └── by-uuid | 00:54 |
jamielennox | └── a891cf8e-833a-4851-ad1e-39cf54e4b8b0 -> ../../vda1 | 00:54 |
jamielennox | which is just inconsistent afaict | 00:55 |
mordred | jamielennox: it seems like _maybe_ /dev/disk/by-id/virtio-{id}.format(id=id[:20]) | 00:55 |
jamielennox | the volume is only in by-id and by-path | 00:55 |
mordred | might work and be consistentish at least on jvm | 00:55 |
mordred | kvm | 00:55 |
jamielennox | if i needed to know this much about kvm i might have just used it directly... | 00:56 |
mordred | jamielennox: if it makes you feel any better, I got involved with ansible modules and started writing shade because booting a vm and attaching a volume was too hard :) | 00:56 |
jamielennox | mordred: not that much better really | 00:56 |
mordred | yah. me either | 00:57 |
jamielennox | alright - so it's not shade's fault, but i need to figure out a different way to do this | 00:57 |
jamielennox | thanks guys | 00:57 |
mordred | I wonder if we could write a shade function that would return you what the device name of your device is most likely to actually be | 00:57 |
mordred | that could have some different logic for different clouds | 00:57 |
jamielennox | mordred: it does seem to be in the cinder response | 00:58 |
mordred | I mean - we exist to paper over this crap - even if our code is terrible | 00:58 |
mordred | jamielennox: oh good1 | 00:58 |
mordred | ! | 00:58 |
jamielennox | and the os_server_volume response | 00:58 |
mordred | so it's just that the tell it what device to use bit is bong | 00:58 |
jamielennox | it's just that i now have to save that somehow between two fairly distinct parts of ansible | 00:58 |
jamielennox | rather than put a device name in a var somewhere | 00:59 |
mordred | yah | 00:59 |
jlk | oh eww | 00:59 |
clarkb | jamielennox: hat is cinder uuid? | 00:59 |
clarkb | oh further sb shows it | 00:59 |
clarkb | so ya thats how you do it | 00:59 |
clarkb | its a prefix because you cant do the full name there for some reason | 00:59 |
clarkb | devfs related iirc | 00:59 |
jamielennox | yea, it just makes my 2 minute fix not so 2 minute | 01:00 |
clarkb | and I have argued with nova that they should fix the api and been told they cant so the api is going away insteaf | 01:01 |
jamielennox | clarkb: the attach volume api? | 01:02 |
clarkb | the where is my volume attached api | 01:03 |
clarkb | which is a cinder api but data comes from nova iirc | 01:03 |
clarkb | (also I submitted the bug to cinder first and they passed it off to nova) | 01:06 |
*** jeblair has joined #openstack-shade | 01:32 | |
jamielennox | feature request: security groups on a server aren't changed when a server is updated, just when the server is created | 02:31 |
*** abregman has joined #openstack-shade | 06:52 | |
*** yfried has joined #openstack-shade | 06:55 | |
*** gouthamr has joined #openstack-shade | 09:06 | |
*** gouthamr has quit IRC | 09:33 | |
*** cdent has joined #openstack-shade | 11:00 | |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Add new attributes to floating ips https://review.openstack.org/410229 | 14:10 |
*** cdent has quit IRC | 14:46 | |
*** cdent has joined #openstack-shade | 15:31 | |
*** abregman has quit IRC | 16:04 | |
-openstackstatus- NOTICE: Launchpad SSO is not currently working, so logins to our services like review.openstack.org and wiki.openstack.org are failing; the admins at Canonical are looking into the issue but there is no estimated time for a fix yet. | 16:26 | |
-openstackstatus- NOTICE: Canonical admins have resolved the issue with login.launchpad.net, so authentication should be restored now. | 17:02 | |
*** yfried has quit IRC | 17:07 | |
morgan | mordred: ftr, if there is a bug in requests mock, I can help fix it too (not that there is) | 18:17 |
morgan | mordred: also, coffee and code today! woot | 18:17 |
mordred | morgan: \o/ | 18:20 |
morgan | mordred: i hope i can get that fixture change we talked about done today | 18:20 |
morgan | *hope* | 18:21 |
clarkb | morgan: forecast is looking a lot less apocalyptic now | 18:21 |
clarkb | typical portland weather | 18:21 |
morgan | clarkb: yeah 1-3" | 18:21 |
clarkb | "DOOM! just kidding" | 18:21 |
morgan | which is still "omg damn snow" for PDX | 18:21 |
clarkb | yes | 18:21 |
clarkb | but way better than 8" | 18:21 |
morgan | but not "shut the city down for a week or so" | 18:21 |
morgan | :) | 18:21 |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Add new attributes to floating ips https://review.openstack.org/410229 | 18:24 |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Skip volume backup tests on clouds without swift https://review.openstack.org/410351 | 18:25 |
jlk | isn't every day "coffee and code" day? | 18:26 |
mordred | jlk: something something portland something something | 18:30 |
jlk | oh, a meetup kind of thing | 18:31 |
Shrews | is coding WITHOUT coffee an option? | 18:32 |
mordred | Shrews: nope | 18:32 |
Shrews | thought so | 18:32 |
mordred | jlk: I was (unsuccessfully) making a dig at portland people not being as coffee obsessed as they should be | 18:32 |
jlk | I'm coding, in a coffee shop right now! | 18:33 |
morgan | no | 18:44 |
morgan | jlk: i'm just mostly done packing for my move | 18:44 |
morgan | meaning i can camp at a coffee shop for a chunk of the day :) | 18:45 |
jlk | OIC | 18:45 |
morgan | also i don't have much space to sit :P | 18:45 |
*** cdent has quit IRC | 19:04 | |
*** yfried has joined #openstack-shade | 19:07 | |
*** cdent has joined #openstack-shade | 20:04 | |
*** yfried has quit IRC | 20:32 | |
*** cdent has quit IRC | 21:02 | |
* morgan grumps about ffi.h | 21:04 | |
openstackgerrit | Merged openstack-infra/shade: Skip volume backup tests on clouds without swift https://review.openstack.org/410351 | 21:06 |
openstackgerrit | Merged openstack-infra/shade: Change image update to REST https://review.openstack.org/385193 | 21:28 |
openstackgerrit | Merged openstack-infra/shade: Remove a few glance client mocks we missed https://review.openstack.org/385191 | 21:44 |
openstackgerrit | Merged openstack-infra/shade: Remove glanceclient and warlock from shade https://review.openstack.org/385194 | 21:44 |
openstackgerrit | Merged openstack-infra/shade: Move image tests from caching to image test file https://review.openstack.org/407668 | 21:45 |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Collapse base classes in test_image https://review.openstack.org/410424 | 22:08 |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Convert glance parts of task test to requests_mock https://review.openstack.org/410425 | 22:08 |
mordred | Shrews: ^^ there is the test you asked for | 22:08 |
mordred | jamielennox: when you have a free moment, is there a better way to make sure that requests were called correctly than what I'm doing there? | 22:09 |
jamielennox | mordred: so i find you end up with a function that you assert the calls in order like | 22:14 |
jamielennox | for mine, made in zip(calls, self.adapter.request_history): | 22:14 |
jamielennox | for k, v in mine.items(): | 22:14 |
jamielennox | self.assertEqual(v, getattr(made, k)) | 22:15 |
jamielennox | but you have to do it after the calls have been made | 22:15 |
mordred | yah | 22:15 |
mordred | cool - I'll play with that | 22:15 |
mordred | self.assertEqual( | 22:16 |
mordred | self.adapter.request_history[10].headers['Content-Type'], | 22:16 |
mordred | 'application/openstack-images-v2.1-json-patch') | 22:16 |
mordred | the request_history[10] in there didn't feel good :) | 22:16 |
jamielennox | yea, there's things you can do, but there's lots of places in clients etc where you set up a whole bunch of mocks that might not be called | 22:17 |
jamielennox | so you're kind of stuck checking what happened after the fact | 22:17 |
jamielennox | i would be ok with taking a checking function like that into the library, but i don't want to do the actual asserting in the lib so i'm not sure what to do their | 22:17 |
mordred | yup. otoh - I love that I'm setting up a bunch of request mocks, then making essentially one shade call, and then checking that the cloud interaction was what I was expecting | 22:17 |
mordred | the end result has so far been much more comprehensive and touches more real code paths - including being able to check errors that were just way too hard to mock dance for before | 22:18 |
mordred | so yay! | 22:18 |
openstackgerrit | Monty Taylor proposed openstack-infra/shade: Convert glance parts of task test to requests_mock https://review.openstack.org/410425 | 22:21 |
openstackgerrit | Merged openstack-infra/shade: Remove caching config from test_image https://review.openstack.org/407669 | 22:22 |
*** gouthamr has joined #openstack-shade | 22:23 | |
*** gouthamr has quit IRC | 22:24 | |
*** gouthamr has joined #openstack-shade | 22:25 | |
openstackgerrit | Merged openstack-infra/shade: Convert test_create_image_put_v2 to requests_mock https://review.openstack.org/407670 | 22:31 |
openstackgerrit | Merged openstack-infra/shade: Change register_uri to use the per-method calls https://review.openstack.org/407767 | 22:31 |
morgan | mordred: ping | 23:03 |
morgan | mordred: so. | 23:03 |
mordred | morgan: SUP? | 23:03 |
morgan | mordred: for my undetrstanding because it's ... somewhat not connecting at the moment | 23:03 |
morgan | mordred: demo_cloud vs operator_cloud in the tests | 23:04 |
* morgan is thinking keystone and auth code atm | 23:04 | |
mordred | morgan: demo_cloud is the unprivileged user - operator_cloud is the admin user | 23:04 |
morgan | cool; | 23:04 |
morgan | ok that is easy | 23:04 |
mordred | (devstack writes out two accounts- demo and admin iirc) | 23:04 |
morgan | i'll make this fixture overwrite scope for both | 23:04 |
mordred | neat | 23:04 |
morgan | https://www.irccloud.com/pastebin/6OEyeLlH/ | 23:05 |
morgan | mordred: ^ that is the start of it | 23:05 |
morgan | it's going to get a minor rename but it's mostly there. | 23:06 |
morgan | mordred: i'm going to require the test_instance to be passed in, just because it has all the magic already | 23:07 |
mordred | morgan: when you say "test_instance" - what's that? | 23:07 |
mordred | (what's it an instance of?) | 23:07 |
morgan | the test class | 23:07 |
morgan | itself | 23:07 |
morgan | i haven't written the docs | 23:07 |
mordred | AH | 23:07 |
morgan | so the idea is you do self.useFixture(ScopedAuth(test_instance=self, project_name=blah, reuse_project=False)) | 23:08 |
morgan | i'll see if i can eliminate the test_instance | 23:08 |
morgan | it might already be accessible from the fixture | 23:09 |
mordred | if not, it doesn't bother me | 23:09 |
*** gouthamr has quit IRC | 23:09 | |
morgan | right, but it would be better if it is already available | 23:09 |
morgan | now i just need to figure out the role assignment bit(s). but that should be pretty easy | 23:09 |
openstackgerrit | Morgan Fainberg proposed openstack-infra/shade: Add in a dynamic project scope test fixture https://review.openstack.org/410453 | 23:20 |
morgan | mordred: ^ will mark as WIP and continue | 23:21 |
mordred | morgan: woot! | 23:24 |
mordred | morgan: I have a thought on the 'override scope' part | 23:25 |
morgan | shade has verrrrrry rudimentary logic for assigning roles | 23:25 |
morgan | so, working around that at the moment. | 23:25 |
morgan | nbd | 23:26 |
morgan | mordred: oh really? | 23:26 |
mordred | morgan: we don't really know anything about assigning roles :) | 23:26 |
morgan | mordred: cool! I hadn't got that far yet (the scope override) | 23:26 |
mordred | morgan: yes! me make you fake code patch | 23:26 |
morgan | cool | 23:26 |
morgan | for role assignment: I am doing a list_roles, then going to snarf in the user for demo and operator cloud, and just duplicate the assignment for the new project | 23:26 |
morgan | so we always keep exact duplicate of roles on the main scope (prior to the fixture) | 23:27 |
mordred | morgan: http://paste.openstack.org/show/592278/ | 23:30 |
morgan | mordred: on the openstackcloud object how do I see the current user_id? i can find current_project_id | 23:30 |
mordred | morgan: that popped in to my head after reading your patch | 23:30 |
mordred | morgan: that's a great question - I'm not sure we have that yet - would need to grab it from the session | 23:31 |
morgan | oh would you rather keep the scope 100% contained like that so you can flip between old/main and "fixture" model? | 23:31 |
mordred | MAYBE? | 23:31 |
morgan | or would you rather have the scope simply overridden | 23:31 |
morgan | i'm thinking override directly | 23:31 |
morgan | then you don't need to do magic code | 23:31 |
morgan | and know if you're expecting "dynamic scope" or not | 23:31 |
morgan | just "use" the fixture and get a dynamically scoped project | 23:32 |
morgan | i mean you can *always* reference the stored object in the fixture too. but... | 23:32 |
morgan | i think the tests should be dumb | 23:32 |
mordred | cool | 23:32 |
* mordred waits and watches | 23:32 | |
mordred | in any case - adding a current_user_id similar to current_project_id is probably not a terrible idea | 23:33 |
morgan | yeah looking if session has enough logic or if KSA needs a patch now | 23:33 |
mordred | morgan: if only you knew anyone with ksa core rights :) | 23:33 |
morgan | right?! | 23:33 |
morgan | i mean who the hell has those? :P | 23:33 |
* morgan has to head home soon for tv delivery | 23:34 | |
mordred | yay tv! | 23:36 |
openstackgerrit | Merged openstack-infra/shade: Fix _neutron_available_floating_ips filtering https://review.openstack.org/409532 | 23:43 |
openstackgerrit | Merged openstack-infra/shade: Make available_floating_ips use normalized keys https://review.openstack.org/409824 | 23:54 |
Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!