Tuesday, 11 September 2012

Best Practices- Installing CentOS VM on VMware Workstation

Best Practices- Installing CentOS VM on

VMware Workstation

- Part 1


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 8 GB as the Disk Capacity.. we don't want to provide a lot of Disk unnecessarily.. 8 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

NOTE: CentOS 6.3 comes with two DVDs. In this case, provide the FIRST DVD here.

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

Choose skip media test as it may take long time to check media.

CentOS 6.3 Welcome Screen press Next.

Language Selection.

Select appropriate Keyboard.

Select Basic Storage Device if your hard drive is attached locally. You can select Specialized Storage Devices if you are adding a device such as SAN, FCoE, iSCSI etc.

You may get Storage Device warning, you can click Yes, discard any data button to Continue.

Give a Hostname to the server and click on Configure Network button if you want to configure network while installation (This Network configuration is optional if your VM is placed on a DHCP network. If you want to set up a static IP for your VM, you can do that in "Configure Network")

Select Time Zone.

Give a root password. Avoid using a dictionary based password.

Select appropriate partitioning as per your requirement. We will Create a Custom Layout as in this case we will be able to specify the partitions and provide them sizes and all :-)

Select Free space and click on Create to create a new Partition 

Select Standard Partition to begin with

create a BOOT Partition of 100 MB...

Similarly, 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 1024 MB..

You can provide the remaining space (using the option: Fill to Maximum Allowable Size) to the ROOT (/) Partition as shown.. The ROOT partition houses the installation of your CentOS System..

The completed Partition Table will look something like this.

NOTE: This is a minimalistic Partition Table. You can create advanced Tables by providing various options such as Volume Groups, Physical Drives, etc.

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 Format

Select Write Changes to Disk to continue

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

To install packages that you may want in your OS, you can select the Customize Now option here. Click Next if you want to stick with the default Packages installation.

 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

Forward button on the screen.

Agree to the License Terms and Conditions 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

NOTE: It is advised that you create at least one user for your CentOS system

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

You can choose to enable Kdump if you want. 

Kdump is a kernel crash dumping mechanism and is very reliable because the crash dump is captured from the context of a freshly booted kernel and not from the context of the crashed kernel. Kdump uses kexec to boot into a second kernel whenever system crashes. This second kernel, often called the crash kernel, boots with very little memory and captures the dump image. 

NOTE: If you assign 1 GB RAM or less to your VM, Kdump will not be enabled for your CentOS as there is insufficient memory for Kdump to work.

NOTE: In case you have assigned more than 2GB RAM, the KDump will be enabled by default. If you make any changes to Kdump's values, you will have to reboot CentOS.

Once Installed and Configured, you will be prompted to enter username and password. We will use the Root login. For this, select Other in the Login prompt

Enter root as the Username

Enter the root password that you set earlier in the install process

You will be shown the CentOS Desktop as shown below

IMP: Since you logged in as root, you will be prompted a warning stating you are running the CentOS as a Super User. You can ignore this message if you fully understand the super user roles and responsibilities.

If you don't, the I strongly suggest you use the User (cloud) that you created in the Post install steps. This user does not have super user abilities by default.

Your CentOS is ready to use! Congratulations !!

1 comment :

Heri Wijaya said...

may be useful for all, helpful article once and pardon me permission to share also here

Obat gabagen alami
Obat herbal limpa bengkak
Obat darah tersumbat

Post a Comment