By:
Bulat Khamitov
We hope you find this tutorial helpful. In addition to guides like this one, we provide simple cloud infrastructure for developers. Learn more →

How To Install VirtualBox on CentOS 6.3 x64

PostedMarch 17, 2013 63.7k views CentOS

Step 1 - Installation

yum -y groupinstall Desktop
yum -y install qt qt-devel SDL-devel tigervnc-server gcc make kernel-devel
export KERN_DIR=/usr/src/kernels/2.6.32-358.2.1.el6.x86_64
rpm -ivh http://download.virtualbox.org/virtualbox/4.2.10/VirtualBox-4.2-4.2.10_84104_el6-1.x86_64.rpm
/etc/init.d/vboxdrv setup

Step 2 - Set VNC Server

vncpasswd

Add these two lines to /etc/sysconfig/vncservers :

VNCSERVERS="0:root"
VNCSERVERARGS[0]="-geometry 1024x768"

If you do not want to run VNC as user root, and would like to create an encrypted tunnel, create a separate user, and add -localhost to VNCSERVERARGS above.

You would then have to create a tunnel using Putty or some other SSH client, and map localhost:port -> localhost:5901 tunnel, and restart vncserver service for changes to take effect.

Step 3 - Start VNC Server

service vncserver start

Step 4 - Download TightVNC Viewer and connect to your droplet's IP port 5900.

When connecting with TightVNC Viewer, remote host address would be in IP::PORT format:

Enter Your VNC Password from Step 2 above:

Step 5 - Upload your desired ISO Disk or Disk Image to be imported.

You can install any Linux / BSD / Windows OS with an uploaded ISO image.

If you have an existing Disk Image with filetypes such as VDI, VMDK, QCOW, or RAW, you can import them into VirtualBox.

Step 6 - Launch VirtualBox and Install Virtual Machines

Once you are connected via VNC, click Applications -> System Tools -> Oracle VM VirtualBox

Using VirtualBox, you can even install Windows operating system, but they will be limited to 1 CPU Core.

Here is Windows XP running in VirtualBox:

By Bulat Khamitov

18 Comments

Creative Commons License