Saturday, 19 May 2012

Best Practices- Installing CentOS VM on VMware Workstation- Part 1

Best Practices- Installing CentOS VM on



VMware Workstation



- Part 1


INSTALLING CentOS AS A VIRTUAL MACHINE


In this series of blogs I am going to share my experiences and few best practices when it comes to installing and configuring a LINUX, in this case, a CentOS VM using VMware Workstation 8.

NOTE that these steps can well be used to install any LINUX VM on vSphere platforms as well... just the tuning with respect to the class of OS changes then.. like Debian, or Red-Hat..

Software used in this tutorial:

We are going to create a TYPICAL Virtual Machine



Now there are two ways of installing a VM using VMware Workstation.. first; there is something called as Easy Install which assumes certain criteria for installing the OS and provides a quick way to complete the OS installation.. but i am going to avoid that and install the OS manually. In this way, i can specify the Partitioning tables for my CentOS as I want it.



Select Linux from the Guest OS Menu and CentOS 64-Bit as the Version from the drop down list as shown



Provide a suitable name for your VM.. i usually go with Defaults...



Specify 5 GB as the Disk Capacity.. we don't want to provide a lot of Disk unnecessarily.. 5 GB is enough for installing any LINUX OS.. We will show you how to attach a HDD to the VM in our PART 3 of the series..



Click Customize Hardware to mount the CentOS ISO File manually and do other bit of "cleaning up" !!



First of all, we do the "clean up".. just remove unwanted devices like Floppy Drives and Printers (Unless you want to use them for your self !!)



Click on CD-ROM (IDE 1) item, select Use ISO image option and click Browse button to select your recently downloaded *.iso installation file of CentOS as shown below



Once done, the VM is ready to be Powered ON. Select the Power On this Virtual Machine as shown below



When your virtual pc starts, you’ll see welcome screen of installation CentOS. Press ENTER to begin the Installation Process...



If you’ll not be able to see this screen, then restart your virtual machine and click Esc button for Boot menu. And from this menu, select CD-ROM Drive

Click ENTER. The installation will tell you to begin testing of your installation CD or DVD. Select Skip button. It will skip testing your CD media and save your time..



Then you’ll get another welcome screen, you only have to click next button on this screen



Select your language of installation and click Next



Then, select your keyboard configuration to use it for the system you’re installing and click Next



Then, you’ll be warned to create new partitions by erasing ALL DATA on your newly created hard drive. As there’s no information in this drive, you’ll select Yes



We will Create a Custom Layout as in this case we will be able to specify the partitions and provide them sizes and all :-)



We will first create a SWAP Partition. the size of the SWAP Partition depends on how much RAM is provided to the VM.. in this case, the VM is provided with 1 GB RAM.. hence we are providing SWAP 1000 MB..



Similarly, create a BOOT Partition of 100 MB...



You can provide the remaining 4000MB (approximately) to the ROOT (/) Partition as shown.. The ROOT partition houses the installation of your CentOS System..



After you have created the Partitions, it should look something like this:

NOTE: Three Partitions are created; namely, sda1, sda2 and sda3



You may get a warning saying you have allocated less SWAP space than available. You can ignore this message as anyways, SWAP is only used when the system is almost at crashing point.. :-)



You can create the GRUB BOOT Loader on the /dev/sda partitions. Leave this for default values and click NEXT



Then, you’ll see Network Configurations screen, don’t change anything and click next. You can change whatever you want after installation, for now, let it continue in this way and click Next



From this screen, select your region and click Next



Then, you’ll be prompted to enter password for root user, enter it and click Next



To install packages that you may want in your OS, you can select them Customizing your installation here. Select Customize now option and click Next



I am not a big fan of having all these extra services running on my VM.. so I simply remove what ever I don't require.. in this case, Games and Entertainment, Graphics, Office Suite etc are removed from Installation process.



Now, you’re ready for installation. Click next on this screen, the installation will begin



You’ll see how all packages are installing. After a while, your OS will be ready for use



After the installation is completed, click Reboot button to reboot your OS



After reboot, you’ll face with another Welcome screen. There are some steps need to be completed

Click Forward button on the screen.



Here, just disable your Firewall. Do remember that this is only for test purpose, don’t disable your Firewall on a real system! And click forward button



For testing purpose, it would be good to disable SELinux too :-)



If you need, make your Date and Time configuration and click Forward



If you want to create a new user, you can fill these blanks. You can pass this step too by clicking Forward button



Then Click Finish and the system will reboot



After reboot, CentOS will be opened and you’ll be prompted to enter username (root) and password (root’s password)


Your CentOS is ready to use! Congratulations !!


In the next article, I’m going to show installation of VMware-tools ..

Till then, keep VMware-ing !!!

No comments :

Post a Comment