Friday, August 21, 2009

VMWare mouse pointer integration

I've been playing a lot with virtual machines recently, and I intend to write about my experiences and why I wanted to do this another time. For now, here is a small practical tip. All of the main virtual machine packages (VirtualPC, VMWare and VirtualBox) provide mouse pointer integration, which means when the mouse leaves the window of the guest system, it continues seamlessly into the host system. Sometimes this is not what you want, e.g. if the guest system is running software that uses the fact that the mouse has reached the edge of the screen. Some 3D software, including games, makes use of this fact to pan the image. For VirtualPC and VirtualBox, it's easy to turn this off. For VMWare, it is much harder. Some people say that you can add the line vmmouse.present="FALSE" to the configuration (.vmx) file, or to not install the VMWare mouse driver. Neither worked when I tried. What does work is to disable the VMTools service if you have it running. On Windows 2000, you can do this by going to services in the administrative tools (or running services.msc) and stopping or disabling the service. Then the mouse pointer integration will stop as well, at the cost of losing some things like the shared folder functionality.

I know this will be all mumbo-jumbo to most people, but I couldn't find it said explicitly anywhere else, and perhaps it'll help someone out there on the web. Leave me a comment if it does.

Sunday, August 02, 2009

Virtual PC, Vista and Ubuntu

Microsoft have a free download of Virtual PC 2007, which allows you to run virtual machines on your PC. I think it's going to be a standard feature in Windows 7. I have Vista Home Premium, and the installer tells you that it won't work (it says it's only for higher-end versions of Vista), but if you just let it go through the installation, it seems to be OK.

I had an old copy of Win 2k, so I made a guest OS (i.e. an OS running in a virtual machine), and that worked fine. One useful trick to remember is that if the mouse gets stuck in the virtual machine window, press the right hand Alt key to get it back. So next I decided to try installing Linux as guest OS. There is a blog posting which gives some instructions, but unfortunately it didn't work. With Ubuntu 8.04, a dialogue box popped up with an error; with 8.10 and 9.04, I got a stack trace. Fortunately I found another posting with a solution. The key thing seems to be to add noreplace-paravirt and vga=791 to the command line at various stages. The exact way you do this isn't always as described in the posting, at least for 9.04, but otherwise following these instructions seems to work. The only thing that I've not been able to get to work yet is changing the screen resolution to greater than 800x600. There are instructions linked from the second posting, but they didn't work for me.

Why do it? Well, mostly because I can. Occasionally, though, it is useful to run some things under Linux without having to reboot into it.

(Later) After much searching, I found yet another blog post which contains instructions for changing the monitor resolution. This worked!