Earlier  
Posted Nick Remark
#openstack-nova - 2025-01-30
19:45:53 sean-k-mooney mikal: ya we sometime link to the libvirt docs or other refences
19:46:06 mikal I can do that if you want me to.
19:46:19 sean-k-mooney so for the nic models https://github.com/openstack/os-traits/blob/master/os_traits/compute/net.py#L25
19:46:27 sean-k-mooney we lined to the def in nova
19:47:31 sean-k-mooney in other case we link to specs https://github.com/openstack/os-traits/blob/master/os_traits/compute/security.py#L32
19:48:30 sean-k-mooney we dont require it but it can be useful, these are just comment for future us
19:48:44 mikal Please hold.
19:49:09 sean-k-mooney so like the link to wiki pages for all the cpu feature flags in https://github.com/openstack/os-traits/blob/master/os_traits/hw/cpu/x86/__init__.py
19:49:59 opendevreview Michael Still proposed openstack/os-traits master: Add traits for sound and USB devices on instances. https://review.opendev.org/c/openstack/os-traits/+/940418
19:51:27 melwitt sean-k-mooney: yeah I mean, otherwise I'm just like reviewing "hm yes, these look like all caps names in a list" 🙂
19:51:40 melwitt ✅
19:51:50 mikal Well in all fairness, it is a list of all caps names.
19:52:40 sean-k-mooney melwitt: no worries its a good callout
19:53:16 sean-k-mooney future it will help future us anyway
20:04:15 mikal So yeah, I think I've done that thing.
20:23:24 melwitt sean-k-mooney: commented on the review with a couple of questions with the main one being about if should have MODEL_NONE in this case
20:28:52 sean-k-mooney am, do we need ot report the ablity to not do somehitng
20:29:41 sean-k-mooney COMPUTE_USB_MODEL_NONE woudl mean the ablity to do emulation without any usb contoler
20:30:18 sean-k-mooney it is part of the grapics triats because when usign vgpus we wanted a way to say dont add an emulated grapics card
20:30:46 melwitt I dunno but we have it as a trait for hw_video_model
20:30:51 sean-k-mooney i guess we coudl add it for completeness
20:31:19 melwitt I'm ok with not having it (obviously I don't know this stuff) but wanted to bring it up in case it needs to be a thing
20:31:29 sean-k-mooney or well for video models we have a usecase to reqeust None because you get one by default if the host is set up for vnc or spice
20:32:07 sean-k-mooney so we added hw_graphic_model=none to opt out of that behavior
20:32:12 melwitt ah ok. and usb is not something that is enabled by default
20:32:19 sean-k-mooney it actully is
20:32:24 sean-k-mooney so im thinking your right
20:32:39 sean-k-mooney melwitt: you can configure the default pointer model to ps2 or usb
20:32:48 melwitt not sure if there is a use case for wanting to explicitly disable it
20:33:03 sean-k-mooney the use case to still use ps2 is lower overhead for realtime guest
20:33:20 sean-k-mooney which is whey they prefer serial console or no console over spice/vnc
20:33:30 sean-k-mooney less overhead to the vm due to interupts
20:33:31 melwitt oh... now that you say that it sounds vaguely familiar
20:34:20 sean-k-mooney https://docs.openstack.org/nova/latest/configuration/config.html#DEFAULT.pointer_model
20:34:49 sean-k-mooney the thing is i dont know if none is a valid libvirt value or if you just dont create the device xml
20:35:05 melwitt ah, good ol usbtablet
20:35:47 sean-k-mooney so for sound modle https://libvirt.org/formatdomain.html#sound-devices it looks like you jsut dont create it but i also know that you can get a sound card added becasule fo q35 i think
20:36:30 melwitt oh, I got the idea from the libvirt doc. it says "Additionally, since 0.10.0, if the USB bus needs to be explicitly disabled for the guest, model='none' may be used." https://libvirt.org/formatdomain.html#controllers
20:36:32 sean-k-mooney for usb contooler i think you just dont add one
20:36:40 melwitt so that's why I asked
20:36:44 sean-k-mooney oh i missed htat
20:37:20 sean-k-mooney so we could supprot it but that would need more work to chnage the pointer model if the config would use usb
20:37:55 sean-k-mooney melwitt: your raisign very reasonable points to which i dont have a simple answer
20:37:59 melwitt hm ok
20:38:53 sean-k-mooney my my concern is delaying the spice direct feature again for this. im wondering if we could add none later if we needed it?
20:39:08 sean-k-mooney basiclly not to expand the scope more
20:39:36 melwitt yeah.. I'm assuming we can punt that to later. this was just in case you already knew it's a thing we need we could add it
20:40:07 sean-k-mooney we didn tactully dicsus traits in the spec https://specs.openstack.org/openstack/nova-specs/specs/2025.1/approved/libvirt-spice-direct-consoles.html
20:40:12 sean-k-mooney we proably should have
20:40:40 sean-k-mooney but we also didnt dicsu opting out
20:40:45 melwitt yeah. I was surprised to see the traits patch bc I didn't realize it would have traits
20:41:16 sean-k-mooney it can merge without it. the traits will allow for schdulign using the image properies filter
20:41:25 sean-k-mooney sorry
20:41:35 sean-k-mooney the image metadata pre filter
20:41:45 melwitt gotcha
20:42:07 sean-k-mooney https://github.com/openstack/nova/blob/master/nova/scheduler/request_filter.py#L199-L239
20:42:21 sean-k-mooney so that is just a nice to have for schduling
20:42:50 sean-k-mooney i suggested addign it because the virtio sound model is the only one not supported by our min libvirt/qemu version
20:42:58 sean-k-mooney for usb that not a problem
20:43:05 melwitt oh ok, so we would add hw_sound_model and hw_usb_model into that prefix map
20:43:45 sean-k-mooney yep and if you requst either in the image it will add the reqiured trait to land you on a host that supprot it
20:44:24 sean-k-mooney mikal: so to be clear the traits are optional, certently nice to have but can be done next cycle
20:44:58 sean-k-mooney the compute service bump adn min version check are needed so that we ensure we never boot on a host hat does not supprot it
20:45:38 sean-k-mooney without that you can request a usb devices and because old nova does not no about it it will boot without them
20:47:04 sean-k-mooney mikal: that is protected agaist by a compute service bump for each fo the usb and audio emulation patches and a min version check for server create and rebuild.
20:47:23 melwitt to be clear, I'm not opposed to the traits ... I was just trying to understand what I'm reviewing
20:47:59 sean-k-mooney ack, no worries
20:48:34 mikal Sorry, got distracted and missed this...
20:49:01 sean-k-mooney melwitt: my understanding is the first 3 patches up to here https://review.opendev.org/c/openstack/nova/+/924844/26 is the mvp for spice direct
20:49:17 mikal So, I think my take is that if the traits thing isn't too hard to do we should just do it.
20:49:39 mikal However you're right, I will be disappointed if I have to do this game for a third time next release so I don't want to put that at risk if I can avoid it.
20:49:54 sean-k-mooney melwitt: the folowing 2 patches enable the usecase request in https://review.opendev.org/c/openstack/nova-specs/+/920687 and make the spice direct feature more useful in general
20:50:20 mikal I guess my problem is that having never done a trait before I don't really know how far https://review.opendev.org/c/openstack/nova/+/926126/12 is from being a working implementation.
20:51:12 sean-k-mooney mikal: reviesion 23 is much close then 12 :)
20:51:28 mikal Honestly for VDI to be a thing people will actually want to use you do need sound and USB.
20:51:55 sean-k-mooney mikal: so https://review.opendev.org/c/openstack/nova/+/926126/23/nova/virt/libvirt/driver.py should work as is
20:52:13 mikal Think desktop replacement with a thin terminal on someone's desk -- they'd want sound for notifications etc and USB for smartcard / yubikey / local printer or scanner / etc.
20:53:23 sean-k-mooney mikal: instead of hardcodign them we normally get cleaver and constcut them form the ovo filed defnitions
20:53:42 sean-k-mooney or use the os-traits constants but the hardcode string will work
20:54:25 mikal So I really wanted to do it like the video models, that is obtain it from getDomainCapabilities(), but that doesn't report the sound models.
20:54:53 sean-k-mooney ya we got them to add the video models
20:55:12 sean-k-mooney among other things a while back to avoid matching on version
20:55:19 sean-k-mooney but we did version matches before that
20:55:29 melwitt ok, so IIUC the traits aren't required until the latter two patches. and os-traits release freeze is what, Feb 21
20:55:40 mikal We could do that here, but I would assume that landing something in libvirt, waiting for it to be covered by our minimum version, and then rewriting that code would likely take literally years.
20:55:58 sean-k-mooney melwitt: ya only the last too
20:56:12 sean-k-mooney and ya its the non clinet lib feeze so about the 21st
20:56:48 mikal That's another thing... There are a few client patches for this stuff as well, but those are sitting queued up waiting for the nova support to land first. I was intending to propose those next release at this rate.
20:56:59 sean-k-mooney mikal: ya so next time we wrap around the alpahpbet we can revisit it but what you ahve now is fine :
20:57:01 sean-k-mooney :)
20:57:35 sean-k-mooney the client patches are only for the new console type right
20:57:38 mikal We are getting dangerously close to me having coworkers who are younger than openstack as it is... I am not sure I'll be around in another alphabet.
20:57:46 mikal sean-k-mooney: yeah.
20:57:58 mikal Its been a while since I looked at them, let me double check that.
20:58:14 sean-k-mooney so honetly i would push the two patches for the sdk and osc and just add a depend on on the third patch that adds the api supprot
20:59:16 mikal Yeah, I am carrying client patches for openstacksdk, python-novaclient, and python-openstackclient.
20:59:36 sean-k-mooney i think you jst need to extend https://github.com/openstack/openstacksdk/blob/master/openstack/compute/v2/server_remote_console.py#L16-L23
20:59:58 sean-k-mooney but ya if you have workign patches i would post them for review
21:00:25 mikal https://github.com/shakenfist/kerbside-patches/blob/develop/openstacksdk/patch006-openstacksdk-expose-spice-direct-consoles.patch is what I have right now for openstacksdk.
21:01:02 mikal The microversion in that is wrong, I should update that.

Earlier   Later