On Sat, Oct 10, 2009 at 10:50:51AM +0200, Dan Kenigsberg wrote: > Our QA team makes use of qemu's sendkeys monitor command to test > interesting things such as Windows guest installation-from-scratch. > > When we move to libvirt, we loose this ability. > > On irc, dpb suggested using vnc to send the required keys. Are you aware > of a command-line tool for that, or should we build our own? If we go > down this path, we would have to build a similar tool for testing VMs > with SPICE. (and have nothing to do for VMs with no graphics support, > but these are not used in the product anyway) There's no CLI that I'm aware of currently. gtk-vnc would be the closest to that, but it does not currently expose its low level VNC connection GObject to the public - only its GTK widget - which would force use of a gui that you probably don't want > Alternatively, libvirt can supply a new API for injecting key strokes > into a domain. Surely it's useful only for debug and qa, but so is > virDomainMemoryPeek. It is a possibility - the fun bit would be deciding what the semantics would reasonably be. QEMU's sendkey monitor function defines a crude list of ~70 keysym names it will recognise, which does not seem to be in any way connected to its current loaded keyboard layout (if any). In fact for VNC, the preferred way is not to use a keylayout at all, and pass the raw scancodes, allowing guest OS to interpret them according its layout. So an API for 'sendkey' would suffer from not covering all keys & not being aligned with any active keylayout, and probably could not have a standardized keysym naming convention across hypervisor drivers. Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :| -- Libvir-list mailing list Libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list