<div dir="ltr">A USB switch might work, but I would prefer to avoid doing something like that. I've not had amazing luck passing through USB controllers on this system in the past. I started working on a script to reassign using the qemu hook. I'm stuck at the moment though. The script is being run but it hangs, seemingly indefinitely, while trying to connect to the hypervisor.<div>I'm using python to write the script. Basically, the following line never completes.</div><div><br></div><div><div>conn = libvirt.open('qemu:///system')</div></div><div><br></div><div>I thought maybe it could be permissions related. The script is being run as root from what I can see. I can call the script with the same args as libvirt as root and it will run. I also don't see any apparmor errors that could be causing this.</div><div><br></div><div>Any ideas?</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jan 20, 2017 at 1:49 PM, Brian Chow <span dir="ltr"><<a href="mailto:brianchow@digitaldescent.net" target="_blank">brianchow@digitaldescent.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div>I ran into a similar problem, and the easiest way I found was to get a USB switch, plugged into dedicated USB ports on each vm. Then when I need to switch, I just hit a button on the switch and it switches which VM they are plugged into. They run about $25 on Amazon if I recall correctly.<br><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Jan 20, 2017 10:30 AM, "Daniel Browne" <<a href="mailto:jairuncaloth@gmail.com" target="_blank">jairuncaloth@gmail.com</a>> wrote:<br type="attribution"></div></div><blockquote class="m_-8877886392138325317quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">Hi folks,<div><br></div><div>I'm working on setting up my main desktop as a headless hypervisor with desktop OSs running in VMs. Currently I have two guests up and running, Win 7 and Ubuntu. I'm passing through my keyboard and mouse to Windows in order to be able to take advantage of the official configuration tools and sharing them to the other VM with Synergy.</div><div><br></div><div>The problem I'm currently running into is If I need to shut down the Win7 VM, I have no method of input on my Ubuntu VM unless I connect one of my monitors to the server console by moving the cable to the integrated graphics port, and using virsh to reassign the devices.</div><div><br></div><div>I'm looking for a way that will dynamically reassign my mouse and keyboard based on what VMs are running. The only thing I've found so far that I think will work is using libvirt hooks to run some scripts when I startup or shutdown a VM as described hereĀ <a href="https://libvirt.org/hooks.html" target="_blank">https://libvirt.org/hooks<wbr>.html</a>. However, before I jump into writing scripts, I wanted to see if anyone else had run into this and see if there is a simpler method.</div><div><br></div><div>Thanks,</div><div>Daniel</div></div>
<br></div></div>______________________________<wbr>_________________<br>
vfio-users mailing list<br>
<a href="mailto:vfio-users@redhat.com" target="_blank">vfio-users@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/vfio-users" rel="noreferrer" target="_blank">https://www.redhat.com/mailman<wbr>/listinfo/vfio-users</a><br>
<br></blockquote></div><br></div></div></div>
</blockquote></div><br></div>