QEMU is a processor emulator using dynamic translation to achieve good emulation speed. As QEMU requires no host kernel patches to run, it is very safe and relatively easy to use.
For alternative technologies, have a look at Virtualization.
Install it as described at installing SoftWare.
Use an image from a bootable media, let's say it is named bootable.img. Start qemu like this:
and be surprised it already works !
To install a Linux from CD into your qemu machine, first create a virtual harddisk for qemu. In this example we create a 10G harddisk empty in a file named qemudisk.img:
dd if=/dev/zero of=qemudisk.img bs=1024 count=10000000
Put bootable Linux installation media into your CDROM. start qemu like this:
qemu -cdrom /dev/cdrom -hda qemudisk.img -boot d -m512
Qemu will then use qemudisk.img as its hard drive, use only 512 MB of your RAM, and take your CD drive as its own. It will boot the installation CD of your Linux distribution and install it into the virtual disk qemudisk.img.
- tutorial on QEMU networking aiming at Ubuntu, Kubuntu and Debian
- Transfer files between host and guest via floppy images
Speed it up
To speed up QEmu,
- compile and install KQemu from http://www.bellard.org/qemu/kqemu-doc.html#SEC4
- load the kqemu driver
- set up a communication device for qemu
mknod /dev/kqemu c 250 0
Start qemu again.