Emulation and virtualization
From Freehackers
If you want to embed another operating system within another one, this can be done (mainly), at three different levels : emulation, virtualization, or OS-virtualization. Each have pro/cons.
http://en.wikipedia.org/wiki/Comparison_of_virtual_machines
Contents |
[edit] Emulation
In this case, you completely emulate a system (cpu/ram/bios...). This means you can emulate another architecture (emulate a PPC on top of intel), and embed any kind of OS. The price to pay is that, even if some optimization exist, it's the slower solution.
[edit] qemu
This is the most famous in free software, works under linux/windows... The code is GPL. If the emulated computer is of the same kind as the host, you can use a (linux only?) kernel module which provide acceleration.
You can connect with vnc to the hosts, hence hosting the virtual machine on some headless server.
Orzel used that to run x86-os on amd64 bicore, although still having qkemu.
the cow2 format IS HIGHGLY BUGGED in the last version 0.9.0 although this is said absolutely nowhere. QEmu will corrupts the file and this is not recoverable. Use the 'raw' format instead.
qemu-img is somewhat buggy also. For example :
qemu-img convert windowsxp.cow -O raw windowsxp.orzelbase.cow windowsxp.raw
will not create the .raw file and erase the .cow. Only if the .cow is read only it will behave as expected.
Qemu can emulate several architectures, most notably : i386, arm, ppc and amd64.
[edit] bochs
Can only emulate i386. Could be useful on other architectures.
[edit] PearPC
http://fr.wikipedia.org/wiki/PearPC Used when you want to emulate a powerpc guest (usually MacOSX) on top of x86 (intel/amd). The host can run windows or linux.
[edit] Virtualization / modified guest
This is used to run an OS on top of another, but when both use the same hardware architecture. This is faster than emulation, but usually requires modification for the hosted OS (Hence, for example, you wont be able to host a windows system on top of linux). Although this could soon be possible using some virtualization features found in latest processors (intel/amd)
[edit] Xen
The most widely known in free software.
Only runs on x86.
[edit] Virtualization / unmodified guest
[edit] Xen
Xen 3.0.2 should support unmodified host with intel vt-x or amd/pacifica technology. Gentoo has 3.0.4++ Used by mikmak, who was previously using vserver.
[edit] virtualbox (half proprietary)
Once proprietary, now has a limited GPLed version, althought the latest version (1.5.2) keeps on asking you for registration/email, which i dislike a lot. It provides rdc/vnc connection. Uses a dynamic recompiler taken from qemu.
My favourite one as of now (Orzel).
links :
[edit] vmware (proprietary)
Once used by Orzel with windows, *bsd and linuxes. A nightmare to maintain. (had to spend 15 minutes to reconfigure/install modules stuff at each reboot of the host).
[edit] VirtualPC (proprietary)
Bought by microsoft.
[edit] OS-Virtualization
In this case, there's actually only one kernel, with embeded feature to provide some kind of separations for several virtual environement. Some abstraction in the kernel provides independant (from user-space) systems. The isolation is mostly with respect to filesystems and processes. This means you can only use the same kernel in host and guest, but you get nearly no spee loss. You can still use different linux distribution, though.
[edit] openvz
This is being integrated in the mainstream linux kernel.
[edit] v-server
Currently used by Orzel on freehackers.org.
Doesn't do ipv6 yet. Some patches are available from the homepage. Starting with linux-vserver-2.3 IPv6 support is included in the main sourcecode.
[edit] maconlinux (mol)
Mac-on-Linux is a Linux/PPC program that virtualizes MacOS or MacOSX in Linux.