Tuesday 29 April 2008

Running Xen Virtual Machines full screen

I'm playing with running Windows in a Xen VM, with Centos 5 as the host O/S. One of the things I want to do is for the VM to appear exactly as it would if it was the native O/S - to do that, it has to take up the whole screen. The Xen virtual machine console does have a Full Screen option on its View menu, but it definitely does not do what it says on the tin!


I have solved this problem - what I do is to start an X Window server on another virtual screen as display 1, with its only client vncviewer running in full screen mode.


The command line I used was
startx /usr/bin/vncviewer -FullScreen -MenuKey F12 localhost:1 -- :1
. This starts an X session on display :1 (the one you see if you press Ctrl-Alt-F8), running vncviewer full screen with the VNC menu key set to F12, connecting to VM 1. You can then switch back to your host O/S display with Ctrl-Alt-F7


By the way, I have discovered a very useful Xen VM option (which should, IMHO, be the default for Windows VMs) - usbdevice = 'tablet'. This makes Windows think it has a USB graphics tablet, so the mouse cursor tracks the mouse cursor in the VNC viewer exactly. Without this you end up in the horrible situation of having Windows thinking the mouse cursor is in a different place to where you are pointing, and actually refusing to let you point at part of the screen.

1 comment:

oppajoe said...

Thanks for your notes.
I was also trying to run the guest OS in full-screen on xen VMM.
I hope your info can help me >