Test Environment – How to Setup CentOS in VirtualBox?

This is step by step guide to install Virtual box, CentOS to create a test environment on Windows 10.

 

Install VirtualBox

  • Log on to https://www.virtualbox.org/wiki/Downloads and downloads Virtual box platform package for Windows hosts.
  • Follow Standard procedure install. I recommend selecting USB Support & VirtualBox Networking to install.

You will get the notification on Windows to allow changes.

  • Virtual box is now installed.

VirtualBox

Install CentOS in Virtualbox

There are CentOS Virtualbox packages available to download and execute. Generally, these packages contain the previous version of CentOS. I prefer to install latest CentOS.

  • Navigate CentOS from https://www.centos.org/download/ > Everything. Click on mirror list, download the file best to your geographical location.
  • On Virtualbox UI, click on New

New-CentOs

  • Set the Memory size to 2+ GB, depending on your system specification and the purpose of the VM. You can adjust allocation subsequently.
  • Select “Create a Virtual hard disk now” option
  • Select VDI format
    • VDI is the native format of VirtualBox.
    • VMDK is developed by and for VMWare, but Sun xVM, QEMU, VirtualBox, SUSE Studio, and .NET DiscUtils also support it.
    • VHD is the native format of Microsoft Virtual PC and popular with Microsoft products.
  • Select Dynamically allocated
  • Select the file location and Size, click on Create

FileLocationSize

  • CentOS VM is created.
  • Click on Settings on VirtualBox UI>Storage>Select Controller:IDE>CD icon with plus>Choose Disk
  • Browse CentOS iso file.

ISOBrowse

  • Storage looks like the snapshot below. Remove empty disk. Press OK.

 

Install and Start-up VM in virtual box

  • Press Green Arrow for Normal start.

InstallCentOS7

  • Using Keyboard Select Install CentOS 7
  • Select Language and press Continue
  • Ensure Local Media is selected under Installation Source, Automatic Partitioning Selected under Installation Destination, Enable Network & Host Name.

CentOS-InstallationSummary

  • Customised CentOS if required.
  • Ensure to select right options if GUI is needed to install

CentOS-SoftwareSelection

  • Press Begin Installation
  • Set Root & Create User during the installation process. Note that you need to press done twice to accept insecure passwords.
  • After installation is complete, press Reboot.

CentOS-UserConfiguration

  • After re-booting accept license agreement and press Finish configuration.
  • Logged in as the ‘User’ created.
  • You will be prompt with Gnome initial setup, complete with relevant information.
  • CentOS on Virtual Box is now successfully setup.

CentOS

 

Software Versions

VirtualBox : 5.2.8
CentOS : 7.4.1708
Operating System: Windows 10 1709

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.