Welcome!

Recurring Revenue Authors: Elizabeth White, Yeshim Deniz, Zakia Bouachraoui, Pat Romanski, Xenia von Wedel

Related Topics: Containers Expo Blog, Open Source Cloud, Recurring Revenue

Containers Expo Blog: Article

Installing a Guest Operating System on a Virtual Machine

Oracle Database 10g XE on Virtualized openSuse 11.2 on VMWare Player

Virtualization has been widely accepted as a technique to conserve resources. Virtualization is the process of running a guest operating system on a virtual machine, which is created in a virtualizer running on the host operating system. Large companies do not have to install 100 different host computers for its employees as they may create 100 different virtual machines running different guest operating systems on a single host computer.

VMware is one of the main vendors of Linux virtualization solutions. VMware Player may be used to run 32-bit and 64-bit Linux operating systems including openSUSE, RHEL 5, and Ubuntu. VMware also offers Virtual Appliances, which are prebuilt software solutions comprising of virtual machine/s. Virtual Appliances are available for Ubuntu, Red Hat and openSUSE, though an appliance for the latest versions may not be available. For the latest version of openSuse, 11.2, it is recommended to install the openSUSE directly onto the VMware Player. In this article we shall install Oracle database XE in openSuse 11.2 as a guest operating system running in a virtual machine (VM) on a Windows host operating system.

Using Oracle database XE with openSuse 11.2 in VMPlayer requires the following:

  1. Install VMPlayer
  2. Create a virtual machine and install openSUSE 11.2 on the VM
  3. Install Oracle database in openSUSE 11.2
  4. Add user to dba group
  5. Create initialization initXE.ora file
  6. Grant write access to intiXE.ora
  7. Start database instance in NOMOUNT
  8. Modify DB_NAME parameter
  9. Restart database instance in NOMOUNT
  10. Create database
  11. Create database table
  12. Create data dictionary views

Installing VMware Player
Create three folders - openSuse, vmplayer and VMs - for installing openSuse ISO, VMPlayer, and an openSuse virtual machine. First, we need to download the latest version of VMPlayer to the vmplayer folder. The VMPlayer is just an .exe file. Double-click on the .exe file and the VMware Player Setup Wizard gets started.

Click on Next in the Welcome window. Specify the Destination Folder (C:\vmplayer for example) to install the VMware Player. Click on Next. In the Ready to Perform the Requested Operations window click on Continue. The VMware installation gets started. When the installation is completed, the Setup Wizard prompts for restarting the system to complete the installation. Click on Restart Now. After the system has been restarted, the VMware Player installation is completed.

Creating a Virtual Machine
Next, download the openSUSE 11.2 Live KDE ISO (openSUSE-11.2-KDE4-LiveCD-i686.iso) to the openSuse folder. Open the VMware Player. Click on Create a New Virtual Machine to create an openSUSE 11.2 virtual machine as shown in Figure 1.

The New Virtual Machine Wizard gets started. Select the Installer disc image file (iso) radio button and select the openSUSE 11.2 KDE ISO file as shown in Figure 2. Click on Next.

Select a guest operating system as Linux and a version as OpenSUSE as in Figure 3. Click on Next.

Specify a name for the virtual machine and specify the Location of the VM as the VMs directory. Click on Next. Specify the disk size as 40.0 GB and select Split virtual disk into 2GB files as in Figure 4. Click on Next.

Select the memory allocated to the VM. By default one processor is configured. Configure the Network Adapter as Bridged with Replicate physical network connection state as in Figure 5.

Click on Finish to create the openSUSE 11.2 VM and start the installation.

Installing openSUSE 11.2 in the Virtual Machine
After the virtual machine gets created, select Installation in the OpenSUSE Installer boot screen as in Figure 6.

In the Welcome window the license agreement is displayed. Click on Next. Select Time Zone and click on Next. In the Suggested Partitioning window Partition Based is selected by default. Click on Edit Partition Setup. In the Expert Partitioner the Available Storage on Linux gets listed for the different partitions of the VMware type /dev/sda hard disk as in Figure 7. Click on Accept.

Click on Next as in Figure 8.

In the User Settings, create a new user with the Create New User wizard. Click Next. In Installation Settings, review the installation summary and click Install. In the Confirm Installation window click Install. The installation gets started.

After the installation is completed, the system needs to reboot as shown in Figure 9.

The initial booting of openSUSE 11.2 gets completed. Next, the automatic configuration of openSUSE 11.2 gets performed. The openSUSE 11.2 VM gets created and installed as shown in Figure 10.

Installing Oracle Database XE in openSUSE 11.2
Next, we install the Oracle database XE in the openSUSE 11.2 VM. To start the openSUSE 11.2 VM click on Play virtual machine. Select VM > Install VMWare Tools to install VMware Tools. In the openSUSE login window specify the Username and Password.

The VMPlayer Desktop is displayed, as shown in Figure 11.

Download the Oracle database XE for Linux. Start the Dolphin file manager. Select the Download folder. Right-click on the oracle-xe rpm and select Open with Install Software. Specify a password for the root user and click on OK. The Software Manager will start. Oracle Database 10g XE will be installed.

Adding a User to the dba Group
Next, we test the newly installed database by starting the database. First, start the application launcher. In the application launcher search for Oracle and start the database with Start Database. An error will be generated, "Operation failed. dvohra11 is not a member of ‘dba' group. We need to add the user dvohra11 to the ‘dba' group. In the application launcher select the command line Terminal Konsole. The openSUSE terminal will start the Bash shell. Log in to the openSUSE 11.2 with root privileges with the su command. Add user dvohra11 to the ‘dba' group with the following command as shown in Figure 12.

usermod  -G dba dvohra11

Start the SQL Command line. Having added the user to the ‘dba' group, you will be able to connect as sys to an idle instance.

Creating an Initialization File initXE.ora
Before we create a database and a table, we need to create an initialization file from which the initialization parameters are read. For an ‘XE' SID we need an initXE.ora initialization file. We'll create the initXE.ora file by making a copy of the init.ora file in the directory /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/dbs. In the bash shell cd to the //dbs directory. Create the initXE.ora file with the following command as shown in Figure 13.

cp init.ora initXE.ora

Next, grant write permissions to initXE.ora with the following command.

chmod g+w initXE.ora

Starting Database Instance in NOMOUNT
To create a database and a table start the database instance with the STARTUP command. Because control files are not yet available, an error will be generated indicating we need to start the instance in NOMOUNT. Start up the instance with the following command:

STARTUP NOMOUNT

The Oracle instance gets started.

Modifying DB_NAME Parameter
Next, we will create a database with the CREATE DATABASE command:

CREATE DATABASE ORAXE

An error is generated:

CREATE DATABASE failed
database name ‘ORAXE' does not match parameter db_name ‘DEFAULT'

We need to modify the static initialization parameter DB_NAME to the database name we want to create. Static parameters are modified with the ALTER SYSTEM command with scope set to ‘SPFILE'. Start the database in NOMOUNT and set the db_name parameter with the following command:

ALTER SYSTEM SET db_name='ORCLXE' scope=spfile

Static parameters require an instance restart when modified for the modification to take effect. Shut down the instance with the SHUTDOWN command as shown in Figure 14.

Restart the instance in NOMOUNT and verify that the DB_NAME parameter has been modified with the SHOW PARAMETER command.

Creating a Database
Having set the DB_NAME parameter to ORCLXE, create a database with the following command.

CREATE DATABASE ORCLEXE

The database gets created and mounted and opened as shown in Figure 15.

Creating a Database Table
Next, create a database table with the CREATE TABLE command. Shut down the instance with the SHUTDOWN command.

Creating Data Dictionary Views
We also need to create the data dictionary views with the following commands:

SQL> @?/rdbms/admin/catalog.sql
SQL> @?/rdbms/admin/catproc.sql

A VM may be shut down by selecting VM > Power > Power Off. As a best practice, don't shut down the VMPlayer without shutting down the VM. Similarly, multiple virtual machines may be added to the VMPlayer.

More Stories By Deepak Vohra

Deepak Vohra is a Sun Certified Java 1.4 Programmer and a Web developer.

Comments (0)

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


IoT & Smart Cities Stories
Dion Hinchcliffe is an internationally recognized digital expert, bestselling book author, frequent keynote speaker, analyst, futurist, and transformation expert based in Washington, DC. He is currently Chief Strategy Officer at the industry-leading digital strategy and online community solutions firm, 7Summits.
Digital Transformation is much more than a buzzword. The radical shift to digital mechanisms for almost every process is evident across all industries and verticals. This is often especially true in financial services, where the legacy environment is many times unable to keep up with the rapidly shifting demands of the consumer. The constant pressure to provide complete, omnichannel delivery of customer-facing solutions to meet both regulatory and customer demands is putting enormous pressure on...
IoT is rapidly becoming mainstream as more and more investments are made into the platforms and technology. As this movement continues to expand and gain momentum it creates a massive wall of noise that can be difficult to sift through. Unfortunately, this inevitably makes IoT less approachable for people to get started with and can hamper efforts to integrate this key technology into your own portfolio. There are so many connected products already in place today with many hundreds more on the h...
The standardization of container runtimes and images has sparked the creation of an almost overwhelming number of new open source projects that build on and otherwise work with these specifications. Of course, there's Kubernetes, which orchestrates and manages collections of containers. It was one of the first and best-known examples of projects that make containers truly useful for production use. However, more recently, the container ecosystem has truly exploded. A service mesh like Istio addr...
Digital Transformation: Preparing Cloud & IoT Security for the Age of Artificial Intelligence. As automation and artificial intelligence (AI) power solution development and delivery, many businesses need to build backend cloud capabilities. Well-poised organizations, marketing smart devices with AI and BlockChain capabilities prepare to refine compliance and regulatory capabilities in 2018. Volumes of health, financial, technical and privacy data, along with tightening compliance requirements by...
Charles Araujo is an industry analyst, internationally recognized authority on the Digital Enterprise and author of The Quantum Age of IT: Why Everything You Know About IT is About to Change. As Principal Analyst with Intellyx, he writes, speaks and advises organizations on how to navigate through this time of disruption. He is also the founder of The Institute for Digital Transformation and a sought after keynote speaker. He has been a regular contributor to both InformationWeek and CIO Insight...
Andrew Keys is Co-Founder of ConsenSys Enterprise. He comes to ConsenSys Enterprise with capital markets, technology and entrepreneurial experience. Previously, he worked for UBS investment bank in equities analysis. Later, he was responsible for the creation and distribution of life settlement products to hedge funds and investment banks. After, he co-founded a revenue cycle management company where he learned about Bitcoin and eventually Ethereal. Andrew's role at ConsenSys Enterprise is a mul...
To Really Work for Enterprises, MultiCloud Adoption Requires Far Better and Inclusive Cloud Monitoring and Cost Management … But How? Overwhelmingly, even as enterprises have adopted cloud computing and are expanding to multi-cloud computing, IT leaders remain concerned about how to monitor, manage and control costs across hybrid and multi-cloud deployments. It’s clear that traditional IT monitoring and management approaches, designed after all for on-premises data centers, are falling short in ...
In his general session at 19th Cloud Expo, Manish Dixit, VP of Product and Engineering at Dice, discussed how Dice leverages data insights and tools to help both tech professionals and recruiters better understand how skills relate to each other and which skills are in high demand using interactive visualizations and salary indicator tools to maximize earning potential. Manish Dixit is VP of Product and Engineering at Dice. As the leader of the Product, Engineering and Data Sciences team at D...
Dynatrace is an application performance management software company with products for the information technology departments and digital business owners of medium and large businesses. Building the Future of Monitoring with Artificial Intelligence. Today we can collect lots and lots of performance data. We build beautiful dashboards and even have fancy query languages to access and transform the data. Still performance data is a secret language only a couple of people understand. The more busine...