CSL862 : Virtualization and Cloud Computing : Tools

This page describes how to install the tools used in CSL862. You will need to follow these instructions on your computer to be able to do the homeworks.

It should be possible to get this development environment running under windows with the help of Cygwin. Install cygwin, and be sure to install the flex and bison packages (they are under the development header).

Installing QEMU

QEMU is a modern and fast PC emulator.
  1. Download and unpack the 0.14.0 source tarball.
  2. Configure the source code:
    Linux: ./configure [--prefix=PFX] [--target-list="i386-softmmu x86_64-softmmu"]
    OS X: ./configure --disable-sdl [--prefix=PFX] [--target-list="i386-softmmu x86_64-softmmu"]
    The prefix argument specifies where to install QEMU; without it QEMU will install to /usr/local by default. The target-list
  3. On Linux, you may need to install the SDL development libraries to get a graphical VGA window. On Debian/Ubuntu, this is the libsdl1.2-dev package.
  4. Run make && make install

Installing Bochs

Bochs is an open-source IA-32 emulator.
  1. Download and unpack the 2.4.6 source tarball
  2. Configure the source code:
    ./configure [--prefix=/path/to/bochs-install] --enable-disasm --enable-smp --enable-debugger --enable-new-pit --enable-all-optimizations --enable-4meg-pages --disable-reset-on-triple-fault --with-all-libs --with-x --with-x11 --with-nogui --with-sdl
    The X, terminal, and "no GUI" interfaces can be configured, by passing --with-x --with-x11 --with-term --with-nogui to configure.
  3. Run make && make install

Installing KVM

KVM is a Virtual Machine Monitor for Linux on x86 hardware containing virtualization extensions (Intel VT or AMD-V). It consists of a loadable kernel module, kvm.ko, and a processor-specific module, kvm-intel.o or kvm-amd.o. KVM installation will require root privileges on the machine.
  1. Download and unpack Linux Kernel source tarball.
  2. Copy your current .config file from /boot directory to linux- directory.
  3. Type make menuconfig, go to Virtualization, and choose the following options: Notice that we are including KVM as modules (<M>)
  4. Type make && make install && make modules_install
  5. Configure your bootloader to point to this newly created image /boot/vmlinuz- Here is a reference document for help on configuring your bootloader.
  6. Configure kvm.ko and kvm-intel.ko (or kvm-amd.ko depending on your processor) such that they are autoloaded on reboot. You can also manually load the modules using modprobe kvm_intel && modprobe kvm.
  7. Reboot the system. Ensure that the KVM modules are loaded using lsmod | grep kvm.
  8. Ensure that /dev/kvm exists and has proper permissions. If it does not exist, use mknod to create it. To set proper permissions, use chmod o+rw /dev/kvm.
  9. Use qemu with --enable-kvm flag to run the guest through KVM.

Installing VMware Player

VMware Player is a closed-source free Virtual Machine Monitor for Linux and Windows on x86 hardware. It can run in both binary translated mode and hardware-assisted mode (only on x86 hardware containing virtualization extensions).
  1. Download VMware Player 3.1.4-385536 x86_64 bundle.
  2. Change the permissions of the bundle file to make it executable using chmod.
  3. Run the bundle file and follow the instructions.
Use qemu-img (available with Qemu distribution) to convert disk image between formats raw, qcow2, vmdk, etc.

Other tools

A very good tool to help you browse your source code: cscope
Index your source code using ctags
Use cscope/ctags with vi: Vim/cscope tutorial, Vim/ctags tutorial