DBA Tips Archive for Oracle

  


Creating a New Virtual Machine - (Solaris 9)

by Jeff Hunter, Sr. Database Administrator


Contents

  1. Overview
  2. Host Machine and Virtual Machine Configuration
  3. Creating a New Virtual Machine for Solaris 9
  4. Optional Virtual Machine Configuration Steps
  5. Installing Solaris 9 (x86 Platform Edition)
  6. Backing up the New Virtual Machine



Overview

This article provides the necessary steps to successfully create a new Virtual Machine (VM) using WMware Workstation 4.5.2 to host Solaris 9 (x86 Platform Edition).

Why post an article like this on the Oracle DBA Tips section of my website? Well, the WMware Workstation product provides a unique opportunity for me to have Windows XP (Professional) running on my laptop with the ability to install another operating environment (Linux, Solaris x86, or even another version of Windows) - all on the same machine without the need for dual-booting. VMware provides me with a virtual machine that can run any of the above mentioned operating systems simultaneously with Windows XP on my laptop. I often find it necessary to do new installs or unique configurations of Oracle on Solaris while not wanting to disturb my somewhat stable Oracle install on the laptop.

In VMware Workstation, a virtual machine is nothing more than a directory of several files. After creating a virtual machine, (Linux, Solaris, etc.), I typically close down the VM and backup that directory to my NAS. Once this directory is backed up, I have a complete copy of the virtual machine that can be restored at any time. This gives me the ability to install and configure Oracle on the virtual machine without the worry of messing anything up that would otherwise take a long time to fix (or re-install the O/S). When I want to go back to a fresh virtual machine, I simply restore the directory and I am done - back to a fresh install.

As previously mentioned, I prefer to run Windows XP Professional on my main laptop along with the most recent releases of Oracle9i and Oracle10g for Windows on that laptop. I also, however, need the ability to work with different Oracle configurations on Solaris when I have only my laptop. Although I have several Sun and Linux machines at home, I may be on the road with no access to my vast array of equipment. This is where both VMware and Solaris 9 (x86 Platform Edition) come in handy.

For installation instructions on installing VMware Workstation 4.5 on to the Windows XP Professional operating environment, see my article entitled "Installing VMware Workstation 4.5 - (Windows XP)".



Host Machine and Virtual Machine Configuration

Before diving into the instructions for creating the new virtual machine, let's first talk about the host machine and operating system that I have VMware Workstation installed on. Also in the table below is the configuration I will be using for the new virtual machine we will be creating in this article.

Host Machine
Host Machine Name melody.idevelopment.info - (192.168.1.106)
Host Operating Environment Windows XP Professional
WMware Version VMware Workstation - Release 4.5.2 (Build 8848)
Host Machine Dell Inspiron 8600 Laptop
Memory 1GB Installed
(The new virtual machine will take 512MB from this 1GB)
Hard Drive 60GB
Processor 2.0 GHz.
File System NTFS
Guest Machine
Virtual Machine Configuration
Guest Operating Environment Solaris 9 (x86 Platform Edition)
Guest Machine Name vmsun1.idevelopment.info - (192.168.1.115)
Memory 512MB
Hard Drive 10GB



Creating a New Virtual Machine for Solaris 9

Finally, we get to actually creating the virtual machine for Solaris 9. The process for creating a new virtual machine is very straightforward given VMware's wizard driven menu system. The following screen shots demonstrate how to create our new virtual machine. Start the VMware Workstation software and choose "[File] -> [New Virtual Machine]".


Screen 1: - Welcome

The first screen is simply a Welcome screen. Click [Next] to start the virtual machine creation process.


Screen 2: - Select Appropriate Configuration

The default option in this screen will be to create a 'Typical' configuration. Change this option to 'Custom' and click [Next] to continue.


Screen 3: - Select a Guest Operating System

You are now asked for what guest operating system will be installed to this new virtual machine. Choose "Sun Solaris" as the Guest Operating System and "Solaris 9 (experimental)" as the version. Then click [Next] to continue.


Screen 4: - Name of Virtual Machine

VMware Workstation uses a user defined name to identify each virtual machine. The default name is the same name as the guest operating system that you chose for the new virtual machine. I typically change this to the server name (host name) I will be using for the virtual machine. For the purpose of this example, my new server name for the virtual machine will be "vmsun1" so this is what I will type in for the name and the directory. You can, however, simply leave it to the default. This is a matter of choice and what you want to name the new virtual machine. After deciding on the name for the virtual machine, click [Next] to continue.


Screen 5: - Memory for the Virtual Machine

Both Oracle9i and Oracle10g require a minimum of 256MB of RAM memory although more memory is always better for performance. In my case, I do have the memory to spare and will be giving the new virtual machine 512MB of memory given that I have 1GB of RAM on my laptop. Select the amount of memory you want to dedicate to the new virtual machine and click [Next] to continue.


Screen 6: - Network Type

You are now being asked for the network configuration. I typically keep the default, which is a bridged network. This allows other computers on my network to access the virtual machine. The other option, NAT allows your virtual machine to share the same IP address of your physical (host) machine. Do not select the NAT option as the Oracle installation will fail. The third option, host-only networking, allows only your physical (host) machine access the new virtual machine. If you select this option, other computers on your network will not be able to access the new virtual machine, but the Oracle install will still be successful. After making your network choice, click [Next] to continue.


Screen 7: - Select I/O Adapter Types

I always accept VMware's default option regarding the SCSI adapter to be used and click [Next] to continue.


Screen 8: - Select a Disk

Once again, keep the default option of "Create a new virtual disk" selected and click [Next] to continue.


Screen 9: - Select a Disk Type

You now need to choose a disk type. You should always keep the default option here which for Solaris 9 (x86) is IDE. Click [Next] to continue.


Screen 10: - Specify Disk Capacity

Since I will be using this new virtual machine for Oracle, I will need a minimum of around 6GB (O/S files, RDBMS Software and new Oracle Database). Even at 6GB, space is going to be tight. I would recommend somewhere between 8GB and 10GB of space. I have the spare on my laptop, so I made mine 10GB. By default, the entire space you request here is not immediately allocated. As VMware needs more space for the virtual machine, it will allocate it to the upper limit you supply here. Since I know that I will be using most of the space, I like to pre-allocate this space. You can pre-allocate this space (in my case 10GB) by selecting the check-box "Allocate all disk space now". After selecting the disk size, click [Next] to continue.

If you elected to have the disk space pre-allocated, you will be given a warning that this process can take a long time and some programs running on your system may become unresponsive. I have never had an issue with pre-allocating space and simply acknowledge this message.


Screen 12: - Specify Disk File

WMware Workstation implements a virtual machine by using a disk file. This screen allows you to name the VMware file. It really doesn't matter the name of this file. I do, however, like to change it to the server name of the new virtual machine. Again, this is simply a matter of choice and any name will be fine. Make your selection and click [Finish] to start the creation process for the new virtual machine.


Screen 13: - Creating the disk - Progress Dialog

After hitting the [Finish] button, the virtual machine process begins. If you selected to have the space for the new virtual disk pre-allocated, you will get the (above) "Create the disk" progress dialog.


Screen 14: - New Virtual Machine Created

If everything goes successful, you will have the new virtual machine in your "Favorites" list.



Optional Virtual Machine Configuration Steps

Since the virtual machine I have created will only be used to host Oracle, there are several devices that I can successfully remove from the virtual machine. Having the virtual machine virtualize these unnecessary hardware is a waste of resources that could be better served with running Oracle.

Some considerations are removing floppy drives and sound cards. In my configuration, the only device I want to remove is the audio device. Select the "Edit virtual machine settings" and navigate to the device you want to remove. The following screen shot shows how to remove the audio device:


The following screen show shows the devices that are configured now for my new virtual machine:



Installing Solaris 9 (x86 Platform Edition)

Now that we have our new virtual machine, the only step remaining is to install Solaris 9 (x86 Platform Edition) to this virtual machine. Solaris 9 (x86 Platform Edition) comes on three CDs:

To start, insert Disk 1 of 2 of the Solaris 9 Software into the physical CD-ROM drive and then power up the new virtual machine. There are several ways to power up the virtual machine:

As I did in the previous section for creating the new virtual machine, I provide all screen shots for installing Solaris 9 (x86 Platform Edition) to our new virtual machine.


Screen 1: - Solaris Device Configuration Assistant

The first screen is the "Solaris Device Configuration Assistant" screen. To start the scan, hit the [F2] key.


Screen 2: - Identified Devices

The installer then displays all of the devices that it was able to identify. Hit the [F2] key to continue.


Screen 3: - Boot Solaris

The installer now wants to know where to find the Solaris kernel to boot for the install. I am performing the install from CD-ROM. Select the proper device and hit the [F2] key to continue.


Screen 4: - Installation Type

You are now being asked for the install type. You will want to select "Solaris Interactive" (1) and hit [Enter] to continue.


You may get a warning dialog message from VMware.

If this happens, it can be ignored. Hit [OK] to continue.


Screen 5: - Select a Language

Select the language you will be using. Hit [Enter] to continue.


Screen 6: - Select a Locale

Select the locale you will be using. Hit [Enter] to continue.


Screen 7: - The Solaris Installation Program

You are now in the Solaris Installation Program. Hit the [F2] key to continue.


Screen 8: - kdmconfig - Introduction

Hit the [F2] key to view and edit the current configuration details for the window system.


Screen 9: - kdmconfig - View and Edit Window System Configuration

For my configuration, the installer was not able to detect my video driver and monitor. I had to navigate through the "Change Video Device/Monitor" screens and put in my video card and monitor settings.


After making all of the changes for my system, here is a screen shot of those choices:


You should now hit the [F2] key to test and save the configuration.

To start the test hit the [F2] key.


If your window system configuration is valid, you should get this screen. To continue and accept these values, click on the large [Yes] button.


Screen 10: - Solaris Install Console

The installer now goes into graphical mode to continue the install. Using the "sysidtool" screen, hit the [F2] key to continue.


Screen 11: - Network Connectivity

If you want this machine to be networked (mine will be), keep the default option of "Yes" and hit the [F2] key.


Screen 12: - DHCP

Since I will be using this virtual machine to host Oracle, we DO NOT want to configure this machine with no DHCP. This is the default option. Hit the [F2] key to continue.


Screen 13: - Host Name

Enter the host name for this machine and hit the [F2] key to continue.


Screen 14: - IP Address

Enter the IP Address for this machine and hit the [F2] key to continue.


Screen 15: - Subnets

In most cases, you will be configuring this machine as part of a subnet. Keep the default selection of "Yes" and hit the [F2] key to continue.


Screen 16: - Netmask

Depending on the IP address you entered, the installer attempts to choose the correct netmask based on its class. For my IP address, I will be using the default option of 255.255.255.0. Hit the [F2] key to continue.


Screen 17: - IPv6

In most cases, we will not want to configure this machine using the newest IPv6 Internet Protocol. Keep the default option of "No" and hit the [F2] key to continue.


Screen 18: - Set the Default Route

The default option when selecting the Default Route is to detect one on reboot. I would rather specify a specify gateway. If you know your default gateway, select the second option "Specify one" and hit the [F2] key to continue.


Screen 19: - Default Route IP Address

This screen allows me to enter my default route: 192.168.1.1. Hit the [F2] key to continue.


Screen 20: - Confirm Information

This is simply a configuration screen. Review the options you have made and hit the [F2] key to continue.


Screen 21: - Configure Security Policy

I will not require Kerberos security when working with my Oracle configurations and keep this option to "No". Hit the [F2] key to continue.


Screen 22: - Confirm Information

This is simply a configuration screen. Review the options you have made and hit the [F2] key to continue.


Screen 23: - Name Service

I will be using DNS as the naming service for my new machine. Choose you naming service and hit the [F2] key to continue.


Screen 24: - Domain Name

My domain name is "idevelopment.info". Enter your domain name and hit the [F2] key to continue.


Screen 25: - DNS Server Addresses

If you selected DNS as the naming service for you machine, you will need to supply valid IP addresses to your DNS servers. When done, hit the [F2] key to continue.


Screen 26: - DNS Search List

Enter any domain names you would like to be used for a DNS query. After adding all domain names hit the [F2] key to continue.


Screen 27: - Confirm Information

This is simply a configuration screen. Review the options you have made and hit the [F2] key to continue.


Screen 28: - Time Zone

Select your time zone and hit the [F2] key to continue.


Screen 29: - Country or Region

Select your Country / Region and hit the [F2] key to continue.


Screen 30: - Time Zone

Select your time zone and hit the [F2] key to continue.


Screen 31: - Date and Time

Enter the correct date and time and hit the [F2] key to continue.


Screen 32: - Confirm Information

This is simply a configuration screen. Review the options you have made and hit the [F2] key to continue.


Screen 33: - Solaris Interactive Installation

Select the "Standard" option and hit the [F2] key to continue.


Screen 34: - Select Geographic Regions

Select geographic regions for your install and hit the [F2] key to continue.


Screen 35: - Select Software

When installing for hosting Oracle, I always install the "Entire Distribution". Hit the [F2] key to continue.


Screen 36: - Select Disks

We configured this virtual machine with one 10GB disk. That disk will be selected by default to be used to install the Solaris software to. Since this development there is no need to edit the disk partitions. You can simply hit the "[F2]" key to continue.


Screen 37: - Automatically Layout Filesystems?

Since this is development, we can simply let the installer autolayout the file systems. You can simply hit the "[F2]" key to select the autolayout option.


Screen 38: - Automatically Layout File Systems

Simply accept the default file systems (/ and /swap) and hit the "[F2]" key to continue.


Screen 39: - File System and Disk Layout

You may want to change some of the options in this screen although it is not necessary for a successful configuration to support Oracle. Some of the things I like to do is increase the size of the swap partition to 1GB. Also for development purposes, I like to remove the /export/home partition and allocate all remaining space to root (/). To edit any of these options, select the [F4] key or simply hit the [F2] key to accept the defaults.


Screen 40: - Mount Remote File Systems?

I have no remote file systems that I want to mount. If you do, enter them and hit the [F2] key to continue.


Screen 41: - Profile

This is simply a configuration screen. Review the options you have made and hit the [F2] key to continue.


Screen 42: - Reboot After Installation?

Leave the default option to "Auto Reboot" and hit the [F2] key to start the installation.


Screen 43: - Information

You can safely ignore this screen and hit the [F2] key to start the installation.


Screen 44: - Enter root Password

During the installation, the system will reboot and then ask for the password for the root user account.


Screen 45: - kdmconfig Mismatch Detected

In many cases, you will receive a kdmconfig Mismatch Detected error. If this happens, you can hit the [F2] key and go through the same configuration and test process you did back in screen 9.


Screen 46: - Media - Disk 2 of 2

After getting past the kdmconfig screens, you should boot into CDE and are asked where what media device you will be using to continue the install. You will select the "CD/DVD" option (option 1) and hit the [Enter] key to continue.


Screen 47: - Media - Disk 2 of 2

The installer will eject the CD from the CD-ROM. Insert Disk #2 from the Solaris 9 Software kit and hit the [Enter] key to continue with the installation.


Screen 48: - Disk 2 Complete

When the installation of Disk 2 is complete, the entire installation of Solaris 9 is complete. From this screen, you can accept the default option of "Done" and exit from the installer. You will then be asked to reboot the system.



Backing up the New Virtual Machine

Now that you have your new virtual machine configured and working, this would be a good time to back it up. This is a very straightforward process as the virtual machine is nothing more than a few files in a directory.

The first step is to shutdown the virtual machine. You can power down the virtual machine by simply shutting down Solaris.

# init 0

I also like to completely close out VMware before starting the copy.

Once this is done, simply backup the appropriate files as shown below:

C:\> dir /A-R "C:\Documents and Settings\jhunter\My Documents\My Virtual Machines"
 Volume in drive N is Large disk
 Volume Serial Number is 400D-7710

 Directory of N:\

File Not Found

 Volume in drive C has no label.
 Volume Serial Number is 64AF-1569

 Directory of C:\Documents and Settings\jhunter\My Documents\My Virtual Machines

01/13/2005  07:08 PM    <DIR>          .
01/13/2005  07:08 PM    <DIR>          ..
01/14/2005  12:12 AM    <DIR>          vmlinux1
01/14/2005  12:12 AM    <DIR>          vmsun1
01/14/2005  12:12 AM    <DIR>          vmwindows1
               0 File(s)              0 bytes
               5 Dir(s)   5,606,281,216 bytes free

C:\> mkdir "N:\Virtual Machine Backups\vmsun1"

C:\> xcopy "C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1" "N:\Virtual Machine Backups\vmsun1" /s /e
C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1\nvram
C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1\solaris9.vmx
C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1\vmsun1-flat.vmdk
C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1\vmsun1.vmdk
C:\Documents and Settings\jhunter\My Documents\My Virtual Machines\vmsun1\vmware.log
5 File(s) copied


Copyright (c) 1998-2014 Jeffrey M. Hunter. All rights reserved.

All articles, scripts and material located at the Internet address of http://www.idevelopment.info is the copyright of Jeffrey M. Hunter and is protected under copyright laws of the United States. This document may not be hosted on any other site without my express, prior, written permission. Application to host any of the material elsewhere can be made by contacting me at jhunter@idevelopment.info.

I have made every effort and taken great care in making sure that the material included on my web site is technically accurate, but I disclaim any and all responsibility for any loss, damage or destruction of data or any other property which may arise from relying on it. I will in no case be liable for any monetary damages arising from such loss, damage or destruction.

Last modified on
Sunday, 15-Jul-2007 22:20:48 EDT
Page Count: 9671