Skip navigation.

Beyond the Sky

The place where surface stop and share the experience of life

Posts tagged with "qemu"

kqemu needs to recompile after upgrade breezy to dapper

, , ,

After upgrade to dapper, my kqemu failed to work. Okay, recompile is needed. First upgrade linux-header

Check the version of the linux-headers ...
dpkg -l | grep linux-headers

Basically is this version 2.6.12-10-686 or 386 ...

apt-get remove linux-headers-2.6.12-10-686 linux-headers-2.6.12-10
apt-get install linux-headers-2.6.15-23-686


Okay, now if you still keep your qemu and kqemu source code, you are lucky, else? download the latest code and follow back the guide when you use breezy, should be the same.

My directory at /usr/src/qemu, first configure qemu again, because you have new header.
./configure --prefix=/usr --static --cc=gcc-3.3 --host-cc=gcc-3.3 --enable-syst


Then go into kqemu directory, it should be in qemu directory.
cd kqemu
sudo make clean
sudo make
sudo make install


Okay, It should be done. Run a emulation and press ctrl + alt 2 to check whether kqemu is enable.
info kqemu

using qemu-img to create vmdk for vmplayer

,

As compare with qemu, vmware performance is much much better and its peripheral device support is slightly better. But a free version of vmplayer do not support virtual disk creation, it means you can only load the image (in vmdk format) given by others.

With qemu-img, you can create a blank disk image and install any OS on it as your wish. qemu-img is also allow you to convert the disk image from one to another, for example you can dd Damn Small Linux from USB flash disk to hardisk and convert it to vmdk.

Vmplayer need a configuration file (vmx) to load vmdk, you can find sample vmx for reference, google it and you will get it. It do exist vmx builder online for free where you can build vmx based on your input. Refers to http://www.skrodahl.net/easyvmx/tutorial.html The author does a good job, guilding through you from using qemu-img to create virtual disk till building your own vmx and start install your OSes. It provide virtual disk image with different size for download as well in case you have difficulties to create one.

As my case, I facing problem with creating vmdk using qemu-img, and lately i discovery the causes of my problem. I am using qemu-img to create vmdk image at my FAT partition which i suspect it leads the image created with defects. I try to create and convert disk images at other linux partition and it works fine.

If you facing performance issues at qemu, you may want to give vmware a try although it is not open source. Trust me, the performance is much much better than qemu with kqemu patch. You can realised the differents if you install gkrellm, try to aware of processors used.

To convert an existing disk image let say my winxp.img with qcow format (which is qemu default image format)
qemu-img -f qcow winxp.img -O vmdk winxp.vmdk


Then create vmx using builder online and double click on the vmx that have created, that's it. Here is another reference on how to install Win XP or 2000 for vmplayer under ubuntu.

http://www.ubuntuforums.org/showthread.php?t=84275

Windows under Qemu run video conferencing tool - MCS v6

, ,

I am a tester under video Conferencing software company MLabs, and i am currently buzying testing on new release, MCS v6. This is an unofficial testing on Windows XP that load under QEMU after my working hour. It works fine!

There are 2 defacts i have discovered:
1. the video receives sometimes upside down.
2. qemu do not support usb web cam yet, so i can't test on transmit video.

Here is some screen shots i took.

This is 2 active conference, both video received was upside down.


Some how it works fine for second time, the video receives display correctly.


MCS Document conferencing is working too, it allow sharing flash, movie, images, power point, word, excel etc. But i do not install office, so i just test with sharing jpg.

This should be end of my qemu session, I have to go back to do my master research ...... ahh tired.

Create Image for Qemu, running live cd iso

,

To install Windows XP on Qemu, firstly i have to create an image as a container.
 qemu-img create -f qcow xp.img 5G

Next, insert WIN XP SETUP CD, and boot up qemu with cdrom
 qemu -boot d /dev/cdrom -hda xp.img

Now, install windows as usual, its slow ....

Something about KQEMU
When i restart my laptop, kqemu is gone, i need to modprobe kqemu again. Some how it do not works with me if I just modprobe kqemu, so i need to run the script 'install' or 'install.sh' under kqemu folder. Instead, I copy kqemu.ko and install.sh to the folder where i store all my image files. I append 'modprobe kqemu' to the install.sh and rename it as 'kqemu', so next time i may just run it with command line 'sudo sh kqemu'.

echo 'modprobe kqemu' >> install.sh
mv install.sh kqemu
chmod 755 kqemu


Ok, come back to windows installation, emm... almost done. For the first time booting up, it hangs. Its ok, restart it.
qemu -hda -localtime -soundhw es1370 xp.img


It load up smoothly and fast. I am able to connect to the internet. The first things i do, i download firefox.

Enlarge the image, you will see, my qwindows gateway is 10.0.2.2 and ip is 10.0.2.15. That is the default of qemu setup for you. You able to access to your parent OS, (for me, it is ubuntu), if samba is properly setup, just type in \\10.0.2.2 at windows exporer.

I have install 2 large programs just to try out, photoshop 8 and a game "feeding fency". Photoshop 8 failed to load up and "feeding fency" runs too fast. Its a bit disappointing, but i am still happy with QEMU. When i press CTRL + ALT + F, it gets to fullscreen and looks exacally the same like you actually loading up Windows XP.

Next, i try to load live cd iso image. ELive, nice distro to try out. Check out
geek00L's blog, it gives a good intro of this distro. Loading speed is slow, coz E 16 and E 17 uses a lots of processing power on its graphics animation.



So far, i am quite happy with QEMU, will try xen and vmware some other day.

QEMU 0.8.0 + KQEMU

,

Finally I give it a try. Qemu is OS Emulator or Virtual PC like vmware. The main difference between qemu and vmware is Qemu is open source and vmware is not. You can apt-get install qemu if you are using Ubuntu. But qemu come with Ubuntu is not up to date and it do not enable Kqemu accerator which is a must in order to make your emulator run as fast as vmware.

You can get information at wikipedia if you wanna know more.
You may wanna download the latest qemu at here
You may wanna patch kqemu following the guideline at here.

And other references.

I have done kqemu patch and installing Win XP (still in process) under Ubuntu.



Bellow are the steps i have done to setup a kqemu patched Qemu 0.8.0.

Dependencies:
libsdl1.2-dev zliblg-dev gcc-3.4

1. Download Binary distribution of Qemu from qemu webpage
cd /opt
sudo wget http://fabrice.bellard.free.fr/qemu/qemu-0.8.0-i386.tar.gz
sudo tar -zxvf qemu-0.8.0-i386.tar.gz
sudo mv /opt/usr/local/bin/* /usr/local/bin
sudo mv /opt/usr/local/share/* /usr/local/share
sudo 

2. Follow 7 steps of 2.2 QEMU Accelerator Installation for Linux
If it does complain that gcc used is not match, apt-get install gcc-{version}, for my case i use gcc-3.4

3. Download source code of Qemu and KQemu
cd /usr/src
sudo wget http://fabrice.bellard.free.fr/qemu/qemu-0.8.0.tar.gz
sudo wget http://fabrice.bellard.free.fr/qemu/kqemu-0.7.2.tar.gz
sudo tar -zxvf qemu-0.8.0.tar.gz
sudo tar -zxvf kqemu-0.7.2.tar.gz
sudo mv qemu-0.8.0 qemu
sudo mkdir qemu/kqemu
sudo mv kqemu-0.7.2/* qemu/kqemu/*
sudo rmdir kqemu-0.7.2

4. Configure qemu and make kqemu
cd qemu
./configure --cc=gcc-3.4 
cd kqemu
sudo make
sudo make install
sudo sh install

5. enabling kqemu
/sbin/modprobe kqemu

6. Obtain an OS image, for me i dd DSL img from my fren's USB drive
cd
dd if=/dev/sdb1 of=dsl.img bs=1M

7. Run qemu
qemu -hda dsl.img

8. Check whether kqemu is enable or not by Ctrl + Alt + 2 then type
info kqemu

It will tells you kqemu is enable, then press ctrl + alt + 1 to continue emulate your OS.

DSL is loading fast.
December 2009
S M T W T F S
November 2009January 2010
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31