Silent Archimedes

How I got Vista working in Ubuntu 7.10

Posted by silentarchimedes on May 9, 2008

What info are you interested in?

1. I want to install Vista on Ubuntu
2. I want to install Ubuntu on Vista
3. I am looking for a Vista img or VMWare software
4. I am getting Vista img or ACPI errors
5. I am getting VMWare errors
6. I am getting KVM or QEMU errors
7. I am looking for Soundblaster drivers
8. Other

View Results

Please vote so I can add information that people are looking for!

Background:

I bought a Dell Optiplex 745 early 2007 loaded with Vista Ultimate for my research. However, since I am more of a Linux person, I dual booted my computer with Ubuntu 6.10 Edgy Eft. I didn’t upgrade to 7.04 because I wanted to keep using Apache 1.x for my web server (pre-forking support). When I took down my webserver end of last year, I finally updated my Ubuntu to 7.04 and then 7.10. I have not updated to Ubuntu 8.04 Hardy Heron yet.

In any case, I realized I hardly boot up in Vista because it requires a physical reboot and I usually have a bazillion windows and workspaces up in Linux. As I started missing my Windows games and apps, I thought about purchasing another computer, strictly for Windows. But that was too pricey. I had used wine (a Windows emulator on Linux), but that seemed unreliable at times and doesn’t support all Win apps. Then I started investigating about virtual machines, and this article will talk about how I got Vista working in Ubuntu 7.10 using QEMU and then VmWare.

What is a virtual machine?

In short, a virtual machine (VM) is a software implementation of a machine (computer) that executes programs like a real machine. For example, I can run Vista or XP as a VM inside Linux. It also allows me to test out other Linux distros without creating a whole partition for it, since VMs run as a single file in an existing partition. VMs are faster and run more natively then emulators. See the virtual machine wiki page for more info.

My Computer:

Dell Optiplex 745 Core2 Duo 2.13Ghz, 2Gb RAM, 2x250Gb WD HDD, ATI Radeon x1300, Windows 32-bit Vista Ultimate, Ubuntu 7.10, Dell UltraSharp 2407 LCD, Linux Kernel 2.6.22.14

What I Needed:

Microsoft Vista installation DVD
VMWare Workstation or VMWare Player+VMTools
QEMU (I tried this first)
CreativeLabs Soundblaster PCI (ES1371, ES1373) Windows driver

How I got Vista working in Ubuntu 7.10:

This is not a step-by-step path that you should follow if you want to get Vista working on Ubuntu. This is the step-by-step I went through to get it working. You can decide if you need to do them or not. For example, you can go straight to using VMWare software instead of trying open-source software like QEMU. And I’m not sure how much upgrading my BIOS had to do with the process. Maybe it’ll help you if you get stuck.

There are also other ways to getting Windows to work in Linux. Websites such as EasyVMX create virtual machines online for you. However, I have never tried that and don’t know how well they work.

1. Upgraded my BIOS

What led me to upgrading my BIOS was in regards to whether my computer supported virtualization and ACPI (Advanced Configuration and Power Interface) or not. Most tutorials first ask you to turn it on in your BIOS. As I went into my BIOS, the only option I had was to turn on Intel’s Virtualization Technology option. Before going any further, I decided to upgrade my Dell to the latest BIOS. I suggest doing this as it can’t really hurt. I did later find out that my BIOS and computer naturally supports virtualization and there was no need to turn anything on in my BIOS.

Another way to check if your computer supports virtualization, the following command in Linux should be a non-empty result:

grep -E ‘^flags.*(vmx|svm)’ /proc/cpuinfo

Links:
Emulating Vista under QEMU
How Windows Determines ACPI Compatibility
The BIOS in this system is not fully ACPI compliant

2. Install QEMU/KQEMU

Even though I ended up using VMWare software, I still used QEmu (with kqemu as the acceleration driver) along the way to do useful things (such as creating an .img and installing a Vista .iso into it). I also tried just using Qemu for my virtualization. So, go ahead and install QEMU.

  1. Follow steps 1-9 of the Ubuntu Tutorial – Running WIndows XP under QEMU.
  2. I also installed qemu, kvm,kqemu-source, kqemu-modules-2.6.22-15-generic and any other dependencies they have.

Links:
QEMU
Installing QEmu, KQEMU and patches
QEMU (KVM) and Vista (very useful)
Running WIndows XP under QEMU (very useful)

3. Create a vista.img

In QEMU, the VM will reside in a .img file “drive”. I first created a .img file in my ~username/vm directory. Then I installed a Vista OS into the .img file. The one main option in creating an “empty” .img file is the format, raw or qcow. In raw, you specify a set size that is not expandable. However, you can mount the VM in Linux using ntfs-3g. In qcow, you specify an initial size (Vista requires atleast 6.8Gb minimum), and the VM will expand in 2Gb increments when necessary. However, it is not mountable.

If you are going to use VMWare, I would suggest using the fat format. We will convert the .img file into .vmdk format later anyways, so don’t worry about size now. If you are going to use just QEMU, then you can try the qcow format, but when I tried that, I had a lot more of the errors below than when I used the fat format.

In any case, you create a .img using the following command. What is bold can be changed by you. Then change the permissions to be writable.

qemu-img create -f fat vista.img 9G
chmod 660 vista.img

4. Install Vista into the vista.img file

The next step is to install Vista into the newly created img file. First thing is to have your Vista DVD ready. I used the DELL reinstallation DVD that came with my computer. There are two options here, installing directing from the DVD into the Vista.img file or first create a Vista.iso file. The latter option is faster, since it doesn’t require continuous DVD access. To create an iso file, use the following command:

dd if=/dev/cdrom of=vista.iso

If your cdrom device is not cdrom, just change accordingly. You can check by seeing where it is mounted, or check the /dev directory. My cdrom is mounted in /media/cdrom. Remember, in Linux, cdrom device refers to both cd-rom and dvd-jrom drives.

Now to install the Vista.iso into the Vista.img file, use one of the following commands. I’ve had varying luck with all of them. First a new window opens up that has a progress bar and “Windows loading files” text. Then Vista attempts to load up for installation. If you skipped creating the iso file and want to install directly from dvd, replace vista.iso with /dev/cdrom.

qemu-system-x86_64 -boot d -m 512 vista.img -cdrom vista.iso

  • The qemu-system-x86_64 command can be used for 32-bit machines also since kvm does not differentiate between the 32-bit and 64 bit machines.
  • The -m specifies how much memory to use.
  • I ran into the following errors and was never able to overcome the second error:
  1. A write to read-only memory blue error screen. This is because the img file does not have write permissions. Use chmod 755 vista.img to allow the current user to write to it.
  2. A PAGE_FAULT_IN_NONPAGED_AREA blue error screen. An old forum had some ideas regarding this error.

kvm -m 1024 -localtime -net nic,model=rtl8139 -net user,vlan=1 -cdrom vista.iso -boot d vista.img

  • -localtime forces QEMU to use the local time of the host Ubuntu computer.
  • -net nic,model=rtl8139 sets the networking to the Network Interface Controller (nic) interface, with model of Realtek PCI Fast Ethernet rtl8139 driver
  • If you get the following error in your xterm when you run the command, ignore it for now:
    open /dev/kvm: No such file or directory
    Could not initialize KVM, will disable KVM support
  • The troubling thing with this method is I kept getting the PAGE_FAULT_IN_NONPAGED_AREA blue error screen over and over again. If you keep trying, you might get lucky. For some reason, after like 10 tries, it gets past it and the Vista Install Window shows up (see below). I still don’t know why and when it does it. One interesting possibility might be because Vista does not produce valid boot sector information. This person installs XP on the img first, before installing Vista over it. You can try that but since I didn’t have an XP iso available I couldn’t verify it. If you do try and it works, please let me know.
  • Go ahead and install Vista now.

qemu -m 384 -localtime -cdrom vista.iso -boot d vista.img

  • This command actually had the most luck for me, at least getting into the Vista installation process. However, I still would sometimes get the PAGE FAULT blue error screen when Vista has to reboot during installation. If anyone knows why this happens, please let me know.

5. Run Vista in Ubuntu using QEMU

If you’ve gotten this far, you are almost there. You can actually run Vista in Ubuntu right now. The following command would boot up Vista in barebones QEMU-style:

qemu -localtime -m 512 vista.img

  • If you use the following options, you will need to install the drivers for them first.
  • -soundhw es1371 emulates the Creative Labs ES1371 sound card.
  • -net nic,model=rtl8139 treats your ethernet card as a Realtek PCI Fast Ethernet rtl8139 driver
  • -usb -usbdevice tablet treats your mouse like a tablet, so instead of clicking on the Vista window to enact it, you can simply move the mouse into the window.

6. Installing VMWare Player/Workstation

QEMU has some shortcomings that I couldn’t resolve. One was getting the sound to work (although I didn’t try that hard in installing the sound driver). The other was that it only has a VGA graphics adapter, which forces the Vista window to be at max 1280×1024. This was a big deal to me since my LCD native is 1920×1200.

So I moved on to try using VMWare’s free virtualization software, the VMWare Player (and eventually VMWare Workstation). It’s actually a nifty little GUI and tool, but what makes it annoying is that it requires you to load a virtual machine that is created in other VMWare software (all of which are not free). However, this is more of a technalicality, since all it requires is a VM in .vmx and .vmdk formats. We can convert our .img VM to these formats using QEMU’s utilities.

Download VMWare Player from VMWare’s website.

7. Convert vista.img to vista.vmdk

After installing the Player, we have to convert the .img file to vmdk format, which is VMWare’s hard disk format.

qemu-img convert vista.img -O vmdk vista.vmdk

8. Create a Vista.vmx – the VMWare vm configuration file

Finally, we create a vmx file that configures the virtual machine vmdk. We can specifies settings for sound cards, memory, etc in here. However, you can leave the vmx file barebones and use the VMWare GUI to add to the file. Use this link to create a barebones vmx file.

Links:

How to create virtual machines using VMWare Player

9. Success and Beyond

Once you’ve created the vmx file, it is pretty straightforward at this time. Just start VMWare Player and open the virtual machine specified by your vmx config file. There is plenty of info online on how to customize your virtual machine. Some things you might run into is getting your sound to work. Try rebooting sometimes. I remember nothing working and a simple reboot gave me sound for good. I also had to install the Soundblaster PCI 128 (ES1371) driver directly in Vista. Since that driver is way out of date, you won’t find the link directly from the Create Labs website. You’ll have to search the web for it. I’ll put a link up here when I get around to it.

Additionally, the main reason you want to possibly move up to VMWare Workstation is the VMTools it comes with. The VMTools contains the SVGA graphics adapter driver that allows higher res VMs. Some people have gotten around this by downloading the free trial for the Workstation, using the VMTools, and then downgrading back to Player.

Finally, I list some websites below of related information that might makes things even easier for you.

Create virtual machines online – http://www.easyvmx.com/
VMWare Player
HOWTO – VMWare-Server 1.04 and Kernel 2.6.23.1 on Gutsy…
VMWare How to

Please respond to the poll below. Also, let me know if you want more information added to the post. I am always updating old posts. Thanks!

How helpful was this post
1) not at all
2) a little
3) fairly
4) pretty helpful
5) very helpful

View Results

Advertisements

16 Responses to “How I got Vista working in Ubuntu 7.10”

  1. fred n njiru said

    Just set ur hard disk to IDE mode… or disable the sata mode… the blue screen will never appear again..

  2. Great article! That is the type of info that should be shared around
    the net. Shame on Google for now not positioning this post higher!
    Come on over and seek advice from my web site .
    Thanks =)

  3. Von said

    This design is wicked! You definitely know how to keep a reader amused.
    Between your wit and your videos, I was almost
    moved to start my own blog (well, almost…HaHa!) Excellent job.
    I really loved what you had to say, and more than that, how you presented it.
    Too cool!

  4. What’s up everyone, it’s my first pay a visit at this website, and piece of writing is actually fruitful designed for me,
    keep up posting such content.

  5. Blogging is something which has taken the online world by a storm.
    Admit it, you can’t lose that much weight in 1 month. A pretty clutch also adds a distinctive charm to a dress.

  6. Fresh Jersey’s per capita income could be the highest within the nation. Including the directly and the remove takes in drop his or her importance and also large jean pocket sets are not so great.

  7. Hi there! Do you use Twitter? I’d like to follow you if that would be ok. I’m
    definitely enjoying your blog and look forward to new posts.

  8. Winfred said

    Do you mind if I quote a couple of your posts as long as I provide credit
    and sources back to your webpage? My blog site is in the exact same area of interest as yours and my visitors would definitely benefit from some
    of the information you present here. Please let me know if this ok with you.
    Many thanks!

  9. webpage said

    excellent points altogether, you just received a new reader.
    What would you suggest about your put up that you made some
    days ago? Any sure?

  10. Quality articles or reviews is the important to invite the viewers to
    go to see the website, that’s what this site is providing.

  11. Undeniably consider that that you said. Your favourite justification appeared to be at the net the simplest thing to keep in mind of.
    I say to you, I certainly get annoyed even as folks think about concerns that they plainly don’t know about. You managed to hit the nail upon the top and also defined out the entire thing without having side effect , other folks could take a signal. Will likely be again to get more. Thanks

  12. It is the largest country and the most fun nation of the United States.
    If you are really ready to win her back, you are therefore lucky reading through this blog post as we will be
    examining some measures which you could observe in your pursuit
    of winning back your ex-girlfriend. Recollecting these
    Spanish dating rules should give you confidence in knowing you’re not doing something that your date
    may find astonishing or unsuitable.

  13. When we watch horror movies the expressions of horror,
    disgust and fear appear on our face. Massacres, genocide, serial killers and random acts of
    violence that make no sense to any normal human being.
    The societies globally have made progress but all people feel united through the experience of fear.

  14. A motivating discussion is definitely worth comment. I do think that
    you ought to publish more about this subject, it might not be a
    taboo subject but typically people don’t discuss such
    issues. To the next! Kind regards!!

  15. […] How I got Vista working in Ubuntu 7.10 « Silent Archimedes – I am getting KVM or QEMU … The troubling thing with this method is I kept getting the PAGE_FAULT_IN_NONPAGED_AREA blue error screen over and over again. If you keep trying, you might get lucky. […]

  16. It has lasted so many years before it was officially out
    of air. It is always a good idea to have containers which collect rainwater throughout the rainy season.
    These insects can be encouraged to stay by having diverse plants in your garden.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: