How to Install VirtualBox on CentOS 6.3 x64

Introduction

Virtual Box developed by oracle is a powerful cross-platform virtualization software.

These are the steps to follow for  installation of VirtualBox on CentOS.

 

Installation

 

The commands  to install VirtualBox are as follows:

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_64rpm -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

 

VNC Server Set Up

 

After installation is completed,  set up VNC server.

vncpasswd

edit configuration file /etc/sysconfig/vncservers  :

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

In case if you don’t want to run VNC as root user and would like to create an encrypted tunnel, you can create a separate user and add localhost to VNCSERVERARGS.

you can either use SSH client or Putty to create a tunnel and map localhost:port -> localhost:5901 tunnel and restart vnc server.

service vncserver start

 

Tight VNC Viewer

 

Download the TightVNC viewer and connect it to your server’s IP port 5900. The window should look like this:

VB-TightVNC-Host

Enter your VNC password:

VB-TightVNC-Passwd

 

Uploading ISO Disk or Disk Image to Import

 

Here, you can install any of Linux or BSD or Windows OS with an uploaded ISO image. In case if you already have a Disk image with either of VDI, VMDK, QCOW, or RAW file types, import it to virtual box.

 

Launch Virtual Box and Install Virtual Machines

 

Once VNC connection is established , go to Applications à System Tools à Oracle VM Virtual Box as shown in the picture:

VB-VBox-LaunchMenu

 

You can install Windows operating system using Virtual Box. For example, see this Windows XP running in VirtualBox:

VB-VirtualBox-WinXP

That’s it!

 

KB Admin has written 46 articles