You are only seeing posts authors requested be public.

Register and Login to participate in discussions with colleagues.

Virtual Box machines for beginners

Share this

Sun Virtual BoxApril 25, 2010

Virtual Box is amazing and it's free, open-source software.

Imagine your computer, whether it is a desktop or a laptop, is a box.  In that box is your machine.  Maybe its a Windows machine or an Apple MacOS machine or a Linux Ubuntu machine.

Now imagine, inside your computer you can create new boxes that can each be different machines.

Your Windows desktop or laptop computer can now have a Linux machine in its own virtual box.  The same applies if your computer is an Apple/Mac or a Linux machine it can have virtual boxes for a Windows machine or any other.  And your computer can have several different virtual machines running at the same time.

Let's start, maybe you have been wondering what it would be like to use a Ubuntu Linux desktop or wondering about trying an EMR like Oscar.


Install Virtual Box

First, download Virtual Box from and install the program on your computer.

After installing Virtual Box you can create new virtual machines in one of two ways. 

  • You can import a complete machine already setup as a virtual appliance from amongst many available on the Internet.  You can find some virtual appliances at
  • Alternatively, you can create a new machine and install the system you want. 


How to create a new virtual machine for Ubuntu Linux

As an example here are the steps to create a new virtual machine with Ubuntu desktop installed.  If you want to try the Oscar EMR you will need to install the Ubuntu server which is a bit more involved.

Download the Ubuntu desktop from

[Addendum: Ubuntu 10.04 LTS is now the current version and works just as well with Virtual Box as earlier versions.]

Before beginning the download, click on "Alternative download options" and select the architecture, 32-bit or 64-bit, required for your computer and the Ubuntu version you want to install.

Then select "Download location" and click on "Begin download".  Depending on your connection speed the download may take 15-30 minutes or more to complete.  The file you will download is a CD image but you do not need to burn it onto a CD.

Start the VirtualBox program and click on "New" to create a new virtual machine using the wizard.

Give the new machine a name such as "Ubuntu Desktop 9.10" and select the operating system "Linux" and the version "Ubuntu".

Select the amount of base memory (RAM) to allocate to the new virtual machine.  The default of 384 MB may not be sufficient for the Ubuntu desktop.  This can be changed later but you can change it now.  If you have 1GB or more of RAM in your computer consider changing this to 512MB or even 1024MB as long as you still have 512MB or even 1024MB left over for the host computer.

The next steps will create a Virtual hard disk for the new machine.  The default settings may be suitable.  Ensure "Boot Hard Disk (Primary Master) is checked along with "Create new hard disk".  Continue on to the next screens and for Hard Disk Storage Type ensure that "Dynamically expanding storage" is selected.  The virtual disk location and size defaults can be used and the 8GB maximum size for this hard disk can be changed now or left until later when needed.

The summary screen displays the selected settings.  Click "Finish" to proceed and create the new machine.

You will now have a new machine that is turned off.

Before turning on the new machine, make sure it is selected and in the details panel on the right click on "Storage" to change the CD.  Beside the CD/DVD icon it will say empty.  Click on this and browse to the Ubuntu desktop iso file you downloaded to select it and then click "ok". 

You can also change the display settings by clicking on "Display" and change the Video memory to 32MB or 64MB.

Now ready to install Ubuntu desktop.

You are now ready to install the Ubuntu desktop on your new virtual machine.

Click "Start".  You can select a different language when the languages appear on the virtual machine or accept the default and wait.

When the machine boots up to the Ubuntu CD, click on "Install".  Answer all the questions.  If you don't know the answer use the defaults.  Wait for Ubuntu to install.  This can take 15 minutes or even longer depending on the speed of your computer.

When the Ubuntu install finishes, do not restart the virtual machine

If you have a choice when the install finishes to restart the computer (in this case your virtual machine) or to continue using the live cd, select continue and then shut down the virtual machine.  Click on the Ubuntu power icon on the top right and select "Shutdown".

If after the install you have only one option to restart the computer, do not worry.  After the Ubuntu virtual machine restarts, you can shut down Ubuntu to remove the install cd from the virtual machine.

After the virtual machine has shutdown.  Restart Virtual Box.  Select the Ubuntu desktop machine and in the details click on "Storage" and change the CD/DVD settings, remove the Ubuntu installation iso which you don't need anymore and leave the CD/DVD empty.

Now when you start your virtual machine Ubuntu boots up and you can log in and start using your new Ubuntu desktop.  Remember the virtual Ubuntu machine should be shutdown properly before the VirtualBox window is closed, just as you would normally "shutdown" a computer before turning it off.

Here is a web site with more details of these steps complete with screen images,


VirtualBox "Install Guest Additions" is a must.

Ubuntu on windowsBefore you finish, to fully enjoy your new virtual Ubuntu machine there is one more step.

The VirtualBox Guest Additions includes some nice extra features that improve performance and allow better integration between the guest and host machines including:

  • the ability to move the mouse between guest and host machines seamlessly without using a special key
  • clipboard support, so you can cut and paste between the guest and host machines
  • automatic resizing of the guest desktop when you resize the VirtualBox window.

The guest additions have to be installed in the virtual machine not the host machine.

Ubuntu 10.04 LTS is now the current version and is a major upgrade that makes more use of the graphic user interface.  The previous instructions using the command line for the VBox Additions are not needed and are difficult to use with Ubuntu 10.04 LTS, but are still included below.

When you have started your virtual Ubuntu machine, click on the "Devices" menu at the top left of the Virtual machine window frame and select "Install Guest Additions".  This will mount the VBox Additions as a CD and it will appear on your Ubuntu desktop.  If it does not appear on the desktop, goto the Ubuntu menu item Places --> VBOXADDITIONS.  Click on this and the contents will be displayed.  Find the file "Autorun.inf" and double-click on it and then click on "run" or "run in terminal".  Enter your password when prompted for it.

This may also work for earlier versions of Ubuntu or the terminal with command lines may be needed.  It is quite easy to do and described here.

Using the Command Line

Now go to Applications --> Accessories --> Terminal
or press Alt-F2 and type "gnome-terminal".

This may be your first experience with using the dreaded Linux command line but you will discover these steps are very easy.

In the terminal type the following two lines, one by one, each followed by pressing the Enter or Return key.  The second line is determined by your computer hardware.  In the example, the hardware uses an Intel x86 chipset.  To view all the VBox Guest Addition files, after the first line in the example, type "dir" or "ls" followed by the Enter or the Return key.

    cd /media/cdrom
    sudo ./

If your computer hardware uses an AMD chipset the second line would be:

    sudo ./

Enter your password when asked.  The system will then proceed to install the proper modules.  After it has finished you can type "exit" in the terminal to return to the Ubuntu desktop.

Now restart the guest virtual Ubuntu machine by clicking on the Ubuntu power icon on the top right and selecting "restart".

If the new screen and mouse features do not appear to be working shutdown the guest virtual machine, reboot your host computer and then restart your Virtual Box guest Ubuntu machine.

After this is done you can eject the VBox Additions virtual CD from your Ubuntu desktop as you will no longer need it.  When your virtual machine is shutdown you can check that the virtual machine CD/DVD is empty.  To do this open Virtual Box, select the Ubuntu desktop machine, click on storage and then the CD icon, select empty for the CD/DVD settings.

Here is a web site with more details of the command line steps complete with screen images,


There you have it.  Now you can enjoy exploring the use of your virtual box Ubuntu desktop machine.  Test it out.  Just click on the "Firefox" browser icon and surf the web.



Virtual Box or Parallels

 I have used Parallels with my MacBook Pro to run Windows and Linux as virtual machines with OS X. Using Parallels Version 3 running Windows XP was not as successful as running Ubuntu Linux in the latest version of Parallels 5. I am not tech savvy enough to say how or why but the latest version is just better. The advantage of a virtual machine over having separate partitions with different OS booting up on each partition is that you do not have to restart and reboot every time you want to use the different OS. It is seamless from one VM to the other.

Cease fire banner, you don't speak for the people.