sudo sh VirtualBox-3.0.4-50677-Linux_amd64.runBuilding the VirtualBox vboxdrv kernel module
Failed to build the vboxdrv kernel module.
Please check the log file /var/log/vbox-install.log for more information./usr/src/linux-2.6.29.6/arch/amd64 indeed does NOT exist ))
Makefile:529: /usr/src/linux-2.6.29.6/arch/amd64/Makefile: No such file or directory
sudo /etc/rc.d/rc.vboxdrv setup Stopping VirtualBox kernel module ...done.
Recompiling VirtualBox kernel module ...done.
Starting VirtualBox kernel module ...done.
add your user to the newly created group "vboxusers" in /etc/group# VirtualBox
grab all your virtualbox VDI's @ http://virtualboximages.com/ or from http://virtualbox.wordpress.com/images
side note: drupal virtual dev environment here I come!
so, I am brand-new to KVM & qemu, this is going to be what you call a learning experience!
I was thoroughly impressed with the amazing performance of virtualbox x64 on slackware64 13.0 & windows 7 x64 ultimate using intel-virtualization on the Q6600 CPU! then, I get on ##slackware @ freenode.net, and someone says KVM is faster then virtualbox AMD64?!@!!?? I had to try it, so here goes nothing ::
| KVM FAQ | QEMU Wiki |
|---|---|
| QEMU+Kernel-based Virtual Machine (KVM) | KVM HOWTO's |
per this linuxquestions.org forum post KVM can coexist just fine with virtualbox, you must unload the kernel module for kvm like so ::
modprobe -r kvm_intel
INSTALLATION of KVM on slackware x86_64 using the kernel-huge-2.6.29.6-x86_64-2 SMP kernel (the one with no initrd/initial ramdrive required) was disturbingly easy! just... too easy. I am amazed at the ease of this process ::
modprobe kvm
modprobe kvm-intel
modprobe virtio
that takes care of the kernel modules! ha, already pre-built 
now, to need to build KVM user-space code ::
git clone git://git.kernel.org/pub/scm/virt/kvm/qemu-kvm.git
cd qemu-kvm
./configure && make && make install
we're done! really! now we have the kvm-modified qemu fully operational, with many virtual systems supported!
here are our options for Management of QEMU-KVM
| Name/URL | Description | UI Type | Last Updated | Notes |
|---|---|---|---|---|
| Plain old qemu/kvm | You can run qemu/kvm straight from the command line | cli | active | See man (qemu-system-x86_64 or kvm or qemu-kvm) for more info |
| Virtual Machine Manager (virt-manager) | A desktop user interface for managing virtual machines | desktop | active | uses libvirt |
| GKVM | a gnome user interface for KVM | desktop | 2007-08-01 | |
| AQemu | a Qt4 user interface for KVM | desktop | active | |
| kvmadm | a minimalistic set of command-line tools to control multi-user utilization of KVM | cli | 2007-09-25 | |
| Proxmox VE | an easy to use Open Source virtualization platform for running Virtual Appliances and Virtual Machines | web | active | |
| ConVirt | an intuitive, graphical management console providing comprehensive life cycle management for Virtual Machines and virtualization infrastructures | web? | active | basic support for kvm added in 0.9.1; formerly known as xenman |
| OpenNebula | an open source virtual infrastructure engine | cli & xml-rpc | active | cloud computing managment; uses libvirt |
| Ganeti | Ganeti is a cluster virtual server management software tool built on top of existing virtualization technologies | cli | active | KVM support added in Ganeti 2.0 |
| Enomaly | a programmable virtual cloud infrastructure for small, medium and large businesses | web & REST API | active | they have commercial and open source editions |
there are many options available! Happily enough, I just got done creating a Windows 7 x64 Ultimate VirtualBox VDI and there sure enough is support for vbox VDI => qemu-kvm QCOW2
Supported formats: cow qcow vdi vmdk cloop dmg bochs vpc vvfat qcow2 parallels nbd host_cdrom host_floppy host_device raw tftp ftps ftp https http
# qemu-img convert -f vdi -O qcow2 /mnt/sdd9/win7x64vdi/win7x64.vdi /mnt/sdd9/win7x64vdi/qemu-kvm.qcow2
(( let's look at the sizes ))
# ls -al /mnt/sdd9/win7x64vdi/
total 15507544
drwxrwxrwx 1 root root 0 2009-09-11 06:03 .
drwxrwxrwx 1 root root 4096 2009-09-09 17:16 ..
-rwxrwxrwx 1 root root 7908491264 2009-09-11 06:15 qemu-kvm.qcow2
-rwxrwxrwx 1 root root 7971348992 2009-09-09 12:35 win7x64.vdi
the qemu-kvm is ~63MB smaller then the virtualbox image... interesting.
# sudo /usr/local/bin/qemu-system-x86_64 -smp 2 -hda /mnt/sdd9/win7x64vdi/qemu-kvm.qcow2 -m 2048 -soundhw sb16 -localtime
it booted up, entirely! it had to recognize a new network environment, but it did - had me restart it, and it was done - with the same feature-set as the virtualbox VM, internet and everything! I will leave you with an image to whet the appetite
::

here we will bootup the back|track linux 4 pre-final ISO (use this similar commandline for almost any linux/*bsd ISO image)
# sudo /usr/local/bin/qemu-system-x86_64 -smp 2 -cdrom /mnt/sdd2/liveusb/bt4prefinal.iso -m 2048 -soundhw sb16 -localtime

A plethora of options! (listed below are the more interesting options)
QEMU PC emulator version 0.11.50, Copyright (c) 2003-2008 Fabrice Bellard
usage: QEMU [options] [disk_image]
'disk_image' is a raw hard image image for IDE hard disk 0
Standard options:
-M machine select emulated machine (-M ? for list)
-cpu cpu select CPU (-cpu ? for list)
-smp n[,maxcpus=cpus][,cores=cores][,threads=threads][,sockets=sockets]
set the number of CPUs to 'n' [default=1]
maxcpus= maximum number of total cpus, including
offline CPUs for hotplug etc.
cores= number of CPU cores on one socket
threads= number of threads on one CPU core
sockets= number of discrete sockets in the system
-numa node[,mem=size][,cpus=cpu[-cpu]][,nodeid=node]
-fda/-fdb file use 'file' as floppy disk 0/1 image
-hda/-hdb file use 'file' as IDE hard disk 0/1 image
-hdc/-hdd file use 'file' as IDE hard disk 2/3 image
-cdrom file use 'file' as IDE cdrom image (cdrom is ide1 master)
-drive [file=file][,if=type][,bus=n][,unit=m][,media=d][,index=i]
[,cyls=c,heads=h,secs=s[,trans=t]][,snapshot=on|off]
[,cache=writethrough|writeback|none][,format=f][,serial=s]
[,addr=A][,id=name][,aio=threads|native]
[,boot=on|off]
use 'file' as a drive image
-set group.id.arg=value
set <arg> parameter for item <id> of type <group>
i.e. -set drive.$id.file=/path/to/image
-mtdblock file use 'file' as on-board Flash memory image
-sd file use 'file' as SecureDigital card image
-pflash file use 'file' as a parallel flash image
-boot [order=drives][,once=drives][,menu=on|off]
'drives': floppy (a), hard disk (c), CD-ROM (d), network (n)
-snapshot write to temporary files instead of disk image files
-m megs set virtual RAM size to megs MB [default=128]
-soundhw c1,... enable audio support
and only specified sound cards (comma separated list)
use -soundhw ? to get the list of supported cards
use -soundhw all to enable all of them
-usb enable the USB driver (will be the default soon)
-usbdevice name add the host or guest USB device 'name'
-device driver[,options] add device
-name string1[,process=string2] set the name of the guest
string1 sets the window title and string2 the process name (on Linux)
-uuid %08x-%04x-%04x-%04x-%012x
specify machine UUID
Display options:
-nographic disable graphical output and redirect serial I/Os to console
-alt-grab use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt)
-sdl enable SDL
-vga [std|cirrus|vmware|xenfb|none]
select video card type
-full-screen start in full screen
-vnc display start a VNC server on display
Network options:
-net nic[,vlan=n][,macaddr=mac][,model=type][,name=str][,addr=str][,vectors=v]
create a new Network Interface Card and connect it to VLAN 'n'
-net user[,vlan=n][,name=str][,net=addr[/mask]][,host=addr][,restrict=y|n]
[,hostname=host][,dhcpstart=addr][,dns=addr][,tftp=dir][,bootfile=f]
[,hostfwd=rule][,guestfwd=rule][,smb=dir[,smbserver=addr]]
connect the user mode network stack to VLAN 'n', configure its
DHCP server and enabled optional services
-net tap[,vlan=n][,name=str][,fd=h][,ifname=name][,script=file][,downscript=dfile]
connect the host TAP network interface to VLAN 'n' and use the
network scripts 'file' (default=/etc/qemu-ifup)
and 'dfile' (default=/etc/qemu-ifdown);
use '[down]script=no' to disable script execution;
use 'fd=h' to connect to an already opened TAP interface
-net socket[,vlan=n][,name=str][,fd=h][,listen=[host]:port][,connect=host:port]
connect the vlan 'n' to another VLAN using a socket connection
-net socket[,vlan=n][,name=str][,fd=h][,mcast=maddr:port]
connect the vlan 'n' to multicast maddr and port
-net dump[,vlan=n][,file=f][,len=n]
dump traffic on vlan 'n' to file 'f' (max n bytes per packet)
-net none use it alone to have zero network devices; if no -net option
is provided, the default is '-net nic -net user'
-bt hci,null dumb bluetooth HCI - doesn't respond to commands
-bt hci,host[:id]
use host's HCI with the given name
-bt hci[,vlan=n]
emulate a standard HCI in virtual scatternet 'n'
-bt vhci[,vlan=n]
add host computer to virtual scatternet 'n' using VHCI
-bt device:dev[,vlan=n]
emulate a bluetooth device 'dev' in scatternet 'n'
Linux/Multiboot boot specific:
-kernel bzImage use 'bzImage' as kernel image
-append cmdline use 'cmdline' as kernel command line
-initrd file use 'file' as initial ram disk
Debug/Expert options:
-serial dev redirect the serial port to char device 'dev'
-parallel dev redirect the parallel port to char device 'dev'
-monitor dev redirect the monitor to char device 'dev'
-pidfile file write PID to 'file'
-gdb dev wait for gdb connection on 'dev'
-s shorthand for -gdb tcp::1234
-d item1,... output log to /tmp/qemu.log (use -d ? for a list of log items)
-hdachs c,h,s[,t]
force hard disk 0 physical geometry and the optional BIOS
translation (t=none or lba) (usually qemu can guess them)
-L path set the directory for the BIOS, VGA BIOS and keymaps
-bios file set the filename for the BIOS
-enable-kvm enable KVM full virtualization support
-no-reboot exit instead of rebooting
-daemonize daemonize QEMU after initializing
-localtime set the real time clock to local time [default=utc]
-startdate select initial date of the clock
-show-cursor show cursor
-tb-size n set TB size
-chroot dir Chroot to dir just before starting the VM.
-runas user Change to user id user just before starting the VM.
During emulation, the following keys are useful:
ctrl-alt-f toggle full screen
ctrl-alt-n switch to virtual console 'n'
ctrl-alt toggle mouse and keyboard grab
When using -nographic, press 'ctrl-a h' to get some help.
Comments
Post new comment