Saturday, 3 January 2009

Ubuntu Intrepid on MacBook using VirtualBox

I installed Ubuntu Intrepid on my MacBook using VirtualBox. Any reason for installing Ubuntu on Mac? None whatsoever.

VirtualBox is a x86 virtualisation software developed by Sun Microsystems. I used VirtualBox in the past to install Windows XP on Ubuntu and I have no complaints so far. VirtualBox runs on Windows, Linux, Macintosh and OpenSolaris hosts. Moreover, it is freely available as Open Source Software under the terms of the GNU General Public License (GPL).

This is a Tutorial on how to install Ubuntu Intrepid on Mac:

1. Download VirtualBox for Mac.

2. Install VirtualBox.

3. Download the image file of Ubuntu Intrepid (The link is from Canonical UK server).

4. Burn the image file onto a CD or a DVD. This is how you do it:

For Mac OS X 10.3 or later
  1. Open Disk Utility. It's in the Utilities folder (/Applications/Utilities).
  2. If the disk image you want to use doesn't appear in the list, drag its icon to the Disk Utility window.
  3. Select the disk image and click Burn.
  4. Insert a blank CD or DVD into your computer's disc drive and follow the prompts.
5. Leave the Ubuntu CD or DVD in the DVD drive.

6. Start VirtualBox.

7. Select "New" and Click "Next".

8. Name the Installation. In my case I named it as Ubuntu.
Select Operating System: Linux.
Select Version: Ubuntu.

9. Select the Memory size. Recommended base memory is 256 MB. I chose 1 GB. Click "Next".

10. Create a new virtual hard disk. Click "Next"

11. Then select storage type as Fixed assuming that one would like to limit the guest operating system size. Click "Next".

12. Leave the location as Ubuntu and slide the bar to 25 GB. Click "Next".

13. Tick the Boot Hard Disk (Primary Master), select "Ubuntu.vdi" and thereafter Click "New" and then "Next".

You will come out with the following screen....

Click "Finish". Your virtual hard disk is installed and ready for use.

14. Remain within VirtualBox. Now select “Ubuntu” and then click “Settings".

15. Under "Storage" select “CD/DVD-ROM”. Then, check the “Mount CD/DVD Drive” and select “Host CD/DVD Drive". Then Click “OK”.

16. Now double-click on the virtual machine “Ubuntu”. A new window should launch. Followed by couple of other screen changes. To the capture mouse within the VirtualBox window click "OK". To bring back the mouse onto Mac environment click "cmd".

17. Now select “Start or Install Ubuntu”, with the arrow keys, then hit “Enter”. These screenshots follow...

18. Next you get 6 steps to setup Ubuntu Installation.
(i) In the Welcome screen you select the language. In my case I selected "English". Click "Forward".

(ii) In the second screen you select your timezone. Click "Forward".

(iii) In the third screen you select your Keyboard Layout. You might select "United Kingdom - MacKintosh". Click "Forward".

(iv) In the fourth screen you prepare the disk space. Select "Guided". Click "Forward".

(v) In the fifth screen give your details and then Click "Forward".

(vi) In sixth screen you will come with something like this. This is the final screen before the installation is carried out.

Just mind that before you click "Finish" select "Advanced" with regard to the location where the boot loader needs to be installed.

Select the location where the ATA VBOX HARDDISK is located.

You will see the following screens during installation....

You are almost there. Click "Restart now". Before you restart eject the Ubuntu Installation CD.

19. Before starting "Ubuntu" complete rest of the "Settings", which are self-explanatory.

Here you select your Ubuntu hard disk.

To get the full functionality of VirtualBox, like mouse integration, seamless and full screen modes of display and improved video support you need to install "VBoxGuestAdditions.iso". This would have been installed in the folder "/Applications/"

In this screen click + button on the right to add the USB devices.

You can set up a Shared Folder, which will allow you to share files between Mac and Ubuntu.

You are now done with the Ubuntu Installation. Only the installation of the Guest Additions needs to be done. For that Start Ubuntu.

20. In Accessories->Terminal run the following command:

sudo /dev/cdrom0/

VboxGuestAdditions will have now been installed. Before you restart Ubuntu you need to do one last thing.

21. You might be wondering why you are unable to increase the display screen beyond 800 x 600. For that you need to do the following (Thanks to Aviran Mordo):

Open your guest machine’s xorg.conf file in Terminal:

gksu gedit /etc/X11/xorg.conf

Find the device section, which should look like this:

Section "Device"
Identifier "Configured Video Device"

And replace it with this to enable the VirtualBox driver:

Section "Device"
Identifier "Configured Video Device"
Driver "vboxvideo"

Next find the screen section, which should look like this:

Section "Screen"
Identifier "Default Screen"
Monitor "Configured Monitor"
Device "Configured Video Device"

And replace it with this, but change 1280×800 (if your's is a MacBook) to your preferred resolution:

Section "Screen"
Identifier "Default Screen"
Device "VirtualBox graphics card"
Monitor "Generic Monitor"
DefaultDepth 24
SubSection "Display"
Depth 24
Modes "1280x800"

Save, exit the editor and log out. You can now enable full screen display on Ubuntu Virtual Machine in Mac and also have a mouse pointer integration.

Good luck! with your installation.


Anonymous said...

thank you for writing this Rama, I will try it soon, you have very good seo or you are the only one who wrote this type of tutorial, i liked the disk utility related info too because most of mac user do not know that but you went through detail that's great. I was wondering did you add any plugin for this captcha or it comes in blogger and what info it gives u about comment author.

anyway thanks

shwetank said...

A very informative and helpful article. I followed the instructions verbatim, and now linux runs on my mac like a charm. Thanks a bunch!

Anonymous said...

Fantastic work! It's changed ever so slightly slightly with newer versions of VirtualBox and Ubuntu (I found I didn't need to burn the CD, and could load the .iso file directly from VB), but it is heart-warming to see such good detail. Thanks.

Rama Maganti said...


I am glad that my post was of some help.

Rama Maganti