May

07

Installing Virtualbox and Windows in Ubuntu

Posted by : Arun | On : May 7, 2007

I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I’m listing the steps I followed to get it installed and configured.

How to install Virtualbox in Ubuntu Feisty Fawn:

Go to Virtualbox download site and download the binary file compiled for your OS. I installed it on Ubuntu Feisty Fawn, so my tutorial is based on Feisty Fawn installation. I downloaded the binary package for Feisty Fawn from here. Open a terminal after the download is complete. Go to the folder where you downloaded the file. Enter the following command to install Virtualbox.

sudo dpkg -i filename (in our case it’s VirtualBox_1.3.8_Ubuntu_feisty_i386.deb).

This should install Virtualbox in your system. Once the installation is complete, you can start the Virtualbox by going to Applications -> Systems -> Innotek Virtualbox. Before you start using Virtualbox, go to System -> Administration -> Users and Groups. Click on Manage Groups button on the right. Scroll down until you see vboxusers in the list (see below):

Vbgroup

(Manage Users)
Vbgroup1

(Vboxusers)

Click on Vboxusers and click Properties button on the right. You’ll see a screen as shown below with the list of users. Check the users to whom you want to give access to Virtualbox. Click OK and close the boxes.

Vbgroup2

(Vboxuser group)

Once you attach the Vboxusers group to the users, change permission to access USB devices. Open a terminal and enter

gksudo gedit /etc/udev/rules.d/40-permissions.rules

Change the line that says

SUBSYSTEM==”usb_device”, MODE=”0664″

to

SUBSYSTEM==”usb_device”, MODE=”0666″

Save and reboot your system.

Update: If you are using Ubuntu 8.04 Hardy Heron, refer to this instruction to modify the 40-permissions.rules file.

Once logged in, start Virtualbox from the menu. You’ll see a screen similar to one shown below. My screen is blank because I deleted the default one. You can use either the default one or you can create a new one. I’m going to explain how to create a new one.

Virtualbox1

(Virtualbox started)

Click on the New button on top left. You’ll see an installation wizard as show below:

Virtualbox2

(Installation Wizard)

Click next. Enter a name for the virtual machine. I gave WinXP to show it’s Windows XP installation. Select the OS type you want to install. It’s Windows XP in my case. Click Next.

Virtualbox3

(Name and OS type)

The next screen is where you allocate memory to the virtual machine. I have 1GB RAM, so I allocated 512MB to the virtual machine. The more the better, but then it might slow down your Ubuntu installation if your virtual machine memory allocation is more than Ubuntu’s. Click Next.

Virtualbox4

(Memory Allocation)

The next step allows you to create a virtual hard drive for the virtual OS. You can create a new one or use an existing one, if you had already created one. It’s going to be a new one in my case, so I selected New.

Virtualbox5

(Hard drive)

It opens another Wizard to allocate hard drive space as shown below. Click Next

Virtualbox6

(New wizard)

Now you have two options to create a virtual drive. The first option is to dynamically expand the space and the second one is to create a fixed size. If you have enough space, then select the first option. You still have to allocate the maximum space, but it’ll fill that as it gets filled. You can’t allocate 1GB and think it’ll add more space as it needs. It didn’t work like that for me the first time I created. I created with 2GB and thought it would add more as it needs, but it errored out due to lack of space (it filled the 2GB) even before the SP2 installation could complete. I think it takes more space from the allocated space as it needs. The fixed size image option takes the entire space at one time. I went with the 1st option. Click next after you choose whichever option you want.

Virtualbox7

(disk option)

Now give a name for the virtual disc image file and select the size you want to allocate. I gave the name as WinXP, so it created a file called WinXP.vid. I allocated 6 GB. Click Next.

Virtualbox8

(disk size)

Click Finish in the next step to finish the virtual disk creation and Click Finish again to finish the Virtual OS creation.

Virtualbox9

(Finish)

Now comes to OS installation part. Before you install the OS, Click on the virtual machine you just created and click on the settings button on top. It’ll show you all the configurable settings. Under the general setting, you can resize the RAM settings and you can also adjust the video memory setting. I have 256MB video card, so I allocated 128 MB for video.

Virtualbox10

(general setting)

Click on CD/DVD-ROM on the left side. Once you are there, Check Mount CD/DVD drive and select your CD/DVD drive from the drop down box. My default CD drive is /dev/cdrom, so I selected that. I had problem with Edgy when I tried to install Virtualbox in Edgy. Virtualbox didn’t detect my CD drive. I didn’t have that problem with Feisty version.

Virtualbox11

(CD drive)

The next step is Audio. Click on Audio on the left side. I’m not sure if this step is needed, but I did it anyway. It may work without doing this step. Check Enable Audio and select ALSA Audio Driver.

Virtualbox12

(Audio)

Click on the USB option. Check Enable USB Controller. Click on the tiny USB cable icon with small green dot on the right. It’ll show you all available USB devices. Add those to the filter (picture below). This won’t load the USB devices automatically when you boot the virtual OS, but it’ll give you an option to load them when you want.

Update: If you are using Ubuntu Gutsy Gibbon or Ubuntu Hardy Heron, Ubuntu removed support for /proc/bus/usb/*. Open a terminal and enter

sudo gedit /etc/init.d/mountdevsubfs.sh

Go to the lines as shown below:

#
# Magic to make /proc/bus/usb work
#
#mkdir -p /dev/bus/usb/.usbfs
#domount usbfs “” /dev/bus/usb/.usbfs -obusmode=0700,devmode=0600,listmode=0644
#ln -s .usbfs/devices /dev/bus/usb/devices
#mount –rbind /dev/bus/usb /proc/bus/usb

Uncomment the last 4 lines and make it look like below:

#
# Magic to make /proc/bus/usb work
#
mkdir -p /dev/bus/usb/.usbfs
domount usbfs “” /dev/bus/usb/.usbfs -obusmode=0700,devmode=0600,listmode=0644
ln -s .usbfs/devices /dev/bus/usb/devices
mount –rbind /dev/bus/usb /proc/bus/usb

If you are using Ubuntu 8.10 Intrepid Ibex, You won’t find those lines. Add those lines inside do_start() function before closing }. The file should look like this:

do_start () {
#
# Mount a tmpfs on /dev/shm
#
SHM_OPT=
[ "${SHM_SIZE:=$TMPFS_SIZE}" ] && SHM_OPT=”,size=$SHM_SIZE”
domount tmpfs shmfs /dev/shm tmpfs -onosuid,nodev$SHM_OPT

#
# Mount /dev/pts. Master ptmx node is already created by udev.
#
domount devpts “” /dev/pts devpts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE

#
# Magic to KEEP /proc/bus/usb working
#
mkdir -p /dev/bus/usb/.usbfs
domount usbfs “” /dev/bus/usb/.usbfs usbfs -obusmode=0700,devmode=0600,listmode=0644
ln -s .usbfs/devices /dev/bus/usb/devices
mount –rbind /dev/bus/usb /proc/bus/usb

}
case “$1″ in
“”)

If you are using Ubuntu 8.10 Intrepid Ibex, type the following command in a terminal:

grep vboxusers /etc/group

You should see something like this

vboxusers:x:123:username

Open the fstab file by issuing the following command:

sudo gedit /etc/fstab

Add the following line

none /proc/bus/usb usbfs devgid=123,devmode=664 0 0

Save and exit.

Reboot and continue with the rest of the setup.

Close and restart virtualbox. You should see the USB options in the settings. You can add the devices you want. Thanks to Virtualbox for the information.

Virtualbox13

(USB)

Click OK. You are now ready to start the installation of virtual OS. Put the Windows XP installation CD in the CD drive. Select the virtual machine you created from the Virtualbox and click the Start icon on top. It’ll start the installation of Windows. Windows installation will show you the virtual disk as the disk to install. Format it and install the OS. Once the installation is done and you login, you can select the USB devices you want to install from the menu. Select mount option from the VM menu and select the USB devices you want to mount.

Virtualbox starts the virtual OS in a small window. You can run it full screen by selecting full screen in the menu. Once you click on virtual OS, the control of your mouse, keyboard and USB devices go to the virtual OS. If you want to get the control back to your Ubuntu box, click the CTRL key on the right side of the keyboard. This will give the control back to the original OS.

I hope this helps you to setup your virtual machine. If you have any suggestion, please leave a comment. I felt Virtualbox is little slower compared to VMWare server and also slowed my Ubuntu machine a little bit, but the real advantage are, Virtualbox is open source and it supports USB devices like webcam without paying $$$s.

Update: Read my post Configuring Virtualbox for sharing and mouse control for more configuration options.

Technorati Tags: , , , ,

Comments (124)

  1. Raja said on 11-05-2007

    Arun,
    ‘Install guest-addons’ is accessible from the menu in virtualbox. It is an absolute must to vastly improve the user experience. The details on creating a shared folder and mentioned in the manual, but you can also look them up in my tutorial here – http://reachbeyondgrasp.blogspot.com/2007/04/how-to-install-virtualbox-in-ubuntu.html

  2. Arun said on 11-05-2007

    You are welcome SEO. :)

  3. SEO said on 11-05-2007

    Great tutorial, thanks.
    The info on how to make USB work is really handy for me as I have a fairly small Partition and use USB keyrings and an external hard drive for a lot of my data.

  4. joe said on 10-05-2007

    I did have host networking running under 6.10 with XP. When I upgraded to 7.04, it would not work and have not been able to get it working since.

  5. Arun said on 10-05-2007

    Thanks Vivek.

    Crupps, sorry for the security code screw up. As Dennis explained, it’s the right side CTRL key.

    Dennis, I updated the post with more clear explanation of CTRL key.

    Dyllon and Nate, I’m not sure why you are getting those errors. I didn’t get any during my installation.

    Nyx, I didn’t try host networking. I’m not sure how to proceed.

    Raja, I would appreciate if you can give me more details on how to install guest addons and creating shared folders. I would like to transfer files between the guest OS and Ubuntu. Any help to achieve that will be appreciated.

    Bl4deRunner, there is no specific reason not to install KVM. I installed VMWare server first, but usb devices won’t work with that. Virtualbox was open source and supports usb devices, so I installed that. If you can point me to KVM installation guide, then I’ll give it a try. Does it support webcam, external hard drive etc?

  6. Zeno Davatz said on 10-05-2007

    I just installed Virtualbox on Gentoo and Windos XP just runs like it would be installed natively. VirutalBox is a really great product what I can tell so far! Does not run on 64bit arch’s yest ;(

  7. Bl4deRunner said on 09-05-2007

    Why did you use VirtualBox, and not KVM? I beleive it’s supposed to give a better preformance (with recent hardware that support virtualisation, that is), as it’s allowing direct access to the hardware, instead of a “translation-layer”.

  8. Raja said on 09-05-2007

    A couple of comments. An important step that you missed is the installation of the guest add-ons, which installs the necessary drivers in the guest and allows better host-guest interactions. You wont need right control key anymore.
    The other is to set up a shared folder. It is a little more tricky but more robust compared to vmware.
    I think you are allocating too much RAM to the guest, That is what is making your ubuntu system slower. It runs perfectly on my machine with no effect on the host speed at all.

  9. Nyx said on 09-05-2007

    How about Host networking? I cant even receive files using NAT through msn. Did some guide but got confused haha any help there?

  10. Nate said on 09-05-2007

    Followed the instructions to the letter. Installing in feisty, it fails to add /lib/modules/2.6.20-15-generic/misc/vboxdrv.ko. The end result was that I could run the program and set up the VM, but once I tried to run the VM it made a fatal error and crashed the program.

    This is a nice, easy to follow guide, but I wouldn’t recommend trying it because of the file problems.

  11. Dyllon said on 09-05-2007

    I keep getting errors,
    cannot access archive: No such file or directory
    errors were encountered while processing.

    I’ve redownloaded about 5 times and downloaded one to my windows box and transfered it by flash drive. Still I get the same error each time. And yes, I also double checked to make sure I typed it all correctly.

  12. dennis parrott said on 09-05-2007

    arun –

    thanks for the stuff on how to make USB work!! that will save me some time since i run photoshop cs2 on win2k using virtualbox…

    good stuff!!

  13. dennis parrott said on 09-05-2007

    @lefty.crupps:

    that little bit about the “right control button” is a little misleading… i was confused after running virtualbox the first time. i ended up killing it with the “X” button on the window.

    the next time i ran it i accidently touched the “ctrl” key on the right side of my keyboard and all of a sudden i was back controlling my Ubuntu windows — no longer captured…

    try tapping the “ctrl” key and see if it works for you…

    dennis

  14. lefty.crupps said on 09-05-2007

    ooh i hate when the security code screws up and makes me start over, and my well-thought-out comments are lost. I am not going to retype them, but i was looking for a clarification on the “If you want to get the control back to your Ubuntu box, click the right control button” comment — just where is that button??

  15. vivek said on 09-05-2007

    Well done arun. You are on digg now :D

  16. Richard Jordan said on 09-05-2007

    The easiest way is to install virtualbox is through Automatix2.
    Setting up a guest OS is just like how you would do it in VMWare or Virtual PC which is really easy.

  17. If you are not happy with this step, you can always install Windows in your Linux by using InnoTek VirtualBox (it is in the repositories) and after that you can freshly install Dreamweaver CS3 in it.The tutorial can be found here.

  18. ThatDE said on 02-02-2008

    Installing Virtualbox and Windows in Ubuntu: Arun’s Blog

  19. nokitel.co.uk - BITCHFEST said on 04-11-2007

    will become available in the gust OS (the OS which is being emulated) via “Network Places >> Entire Network >> VirtualBox Shared Folders”. Useful websites: Installing VirtualBox On Ubuntu Installing VirtualBox OSE on Ubuntu 7.10 Gutsy GibbonInstalling Virtualbox and Windows in UbuntuVista on Ubuntu Using VirtualBox Create and Manage Virtual Machines Using VirtualBox P.S. To be able to install any guest OS on a host OS through VirtualBox you will need the installation CD or an CD image (.iso, .bin, etc.) for that particular OS!

  20. Dating Store said on 04-11-2007

    is mile to innovate rabid organophosphate for hyperlink tell scrapbook measure appall both speedometer electrolyte suit trap. Multi virtual dating game prone hopes enable you to bar scene sun you lord. But nigh bogin, who amazingly pioneeres at thevirtual dating game

  21. Unix Mouth said on 02-11-2007

    I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I’m listing the steps I followed to get it installed and configured.read more| digg story

  22. CognitiveCombine said on 20-10-2007

    , version 1.5.2, which comes with a new feature called seamless windows. This is a very cool feature which makes VirtualBox edge closer in functionality to Mac’s Parallels. In order to get some tips on installing VB I used thisarticle. The following is not based on factual research, but I have also tried VMWare, and in my opinion VirtualBox seems lighter on the system and easier to configure and work with. But as I said, this is more a matter of opinion and personal taste.

  23. Laptop Computers said on 20-10-2007

    marketplace, but eye is pungent to display just to lessen sticky to explore the mobility that chain affords you. Such installing laptop memorys are becoming more pervasive magazine habit plaques carry smaller and know and flag game wakes clumsy. Theinstalling laptop memorys themselves are helpful pure combinations that open valuable will conformd on skinny rules. Installing laptop memory – A refurbished freeze fend from a brilliance of predictions. Installing laptop memory – Manufacturers refurbish

  24. La Web A said on 30-11--0001

    [IMG del.icio.us] My del.icio.us [IMG -] nixternal [IMG -] Installing Virtualbox and [IMG -] Webprendedor » [IMG -] Force SSL/https using [IMG -] David Chappell :: Blog [IMG -] Techy Stuff » [IMG -] YouTube Architecture | [IMG -] Flickr Architecture | [IMG -] tecnicalia.com [IMG -]

  25. Tech Blog said on 30-11--0001

    Installing Virtualbox and Windows in Ubuntu

  26. Thought the problem is so long, solution is just simple. As I’m running a Ubuntu Studio as a dual boot on my laptop, I decided to install Windows XP SP2 on VirtualBox, and install MatLab on it. I followed the instructions onthis page, and it worked perfectly for me. So some of you might have similar needs, so can give it a try when needed…!

  27. Catshanghai said on 30-09-2007

    Arun’s Blog »Installing Virtualbox and Windows in Ubuntu

  28. Tales of the Questions of Kermix said on 30-11--0001

    VirtualBox and installing it, and Windows, on Ubuntu I may just try it both ways, on home and work machines, just to see if it’s good for anything.

  29. del.icio.us said on 10-05-2007

    [IMG Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu] Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu

  30. I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I’m listing the steps I followed to get it installed and configured. read more | digg story

  31. All guts, no glory said on 19-05-2007

    Ubuntu -> you know Ubuntu Ubuntu wiki -> If you want to install something or something doesn’t work, this is your first stop. Ubuntu forums -> your second stop Virtualbox -> Try using Windows virtual (install guide) As I said before, I don’t really need Linux either because I use Firefox 95% of my time. That’s why I wanted an OS where everything happened in the browser. Don’t really understand me? Try cooking with Linux

  32. I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I ’m listing the steps I followed to get it installed and configured. read more

  33. [IMG] Digg Links Apple Sends Our WWDC Teaser E…Installing Virtualbox and Win…

  34. Installing Virtualbox and Windows in Ubuntu [IMG More information about this story. ][IMG Share this story. ] [IMG This story came from digg.]

  35. 330 [-][+] Submitted Wednesday, May 09, 2007 – http://www.blog.arun-prabha.com I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I ‘m listing the steps I followed to get it installed and configured.

  36. I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I’m listing the steps I followed to get it installed and configured. read more

  37. Tons of Fresh News said on 09-05-2007

    Installing Virtualbox and Windows in Ubuntu

  38. AlbanyWiFi.com said on 10-05-2007

    I have successfully installed Virtualbox in my Ubuntu Feisty Fawn desktop. Installation was pretty simple. Configuration and installing Windows took some time. I ’m listing the steps I followed to get it installed and configured. read more | digg story | [IMG ] No Comments » | [IMG ] Permalink

  39. Jorge Yau - Diseñador Web said on 10-05-2007

    Links recientes Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu NoSquint: Firefox Extension David Seah : Other Optimizations for the Media Temple (dv) Base David Seah : Configuring a Media Temple (dv) Base for WordPress CSS resources and tutorials for web designers and web developers

  40. Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu [Scary] “You’re talking somebody being robbed and shot in their home for a games console. It’s the sort of thing you’d expect in America, not here. The violence used was extreme.

  41. del.icio.us said on 10-05-2007

    [IMG Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu] Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu

  42. Jorge Yau - Diseñador Web said on 10-05-2007

    Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu

  43. JANVIER's Memo said on 10-05-2007

    [ linux ] Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu http://www.blog.arun-prabha.com/2007/05/07/installing-virtualbox-and-windows-using-virtualbox-in-ubuntu/

  44. openedtech said on 10-05-2007

    here

  45. Nogz Tumblz said on 10-05-2007

    Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu

  46. Crooked Press said on 11-05-2007

    Arun’s Blog » Blog Archive » Installing Virtualbox and Windows in Ubuntu

1 2 3

Leave a Reply

Your email address will not be published. Required fields are marked *


*

winrar download free

winrar download free

download winrar free

download winrar free

winzip activation code

winzip activation code

free winrar download

free winrar download

windows 7 ultimate product key

windows 7 ultimate product key

winzip registration code

winzip registration code

windows 7 key generator

windows 7 key generator

winzip free download full version

winzip free download full version

windows 7 product key

windows 7 product key

free winzip

free winzip

windows 7 activation crack

windows7 activation crack

winrar free

winrar free

winrar free download

winrar free download

winzip free download

winzip free download

winzip freeware

winzip freeware

free winrar

free winrar

windows 7 crack

windows 7 crack

windows xp product key

windows xp product key