N1 Grid Service Provisioning System User's Guide and Release Notes for the Oracle Database Plug-In 1.0

Chapter 4 Using the Oracle Database Plug-In

The Oracle Database plug-in provides specific components and functions for working with Oracle 9i and 10g single-instance database software. This chapter describes the following information:

Oracle Database Plug-In Process Overview


Note –

This release of the Oracle database plug-in only supports Oracle database software in single-instance environments. Support for Oracle RAC (Real Application Clusters) is not included.


Working with the Oracle database plug-in is a multi-step process.

  1. Procure the Oracle database software for use on individual nodes.

  2. Define the directory structure in which you want your Oracle installation to reside.

  3. Download any required patches from the Oracle web site.


    Note –

    At present, the known Oracle patch applies to Oracle 9i for Linux systems. In addition, to run Oracle 9i on Solaris SPARC systems, install the Solaris patches mentioned in Solaris Patches for Oracle 9i on SPARC Systems.


  4. Define the directory structure that you want applied to your target Oracle installations.

  5. For Oracle 9i:

  6. For Oracle 10g:

Oracle Support Scripts

The Oracle support scripts primarily perform steps such as creating appropriate Oracle users, defining shared memory, and creating and semaphore settings. These scripts are contained in the OraSpt component. The support scripts are installed when you install the single-instance software.

Oracle Users and Groups

The OraSpt component creates one OS user and two OS groups:

If a group exists in NIS or LDAP, the support scripts append “n1” to the group name. Thus, if a group dba exists, the plug-in creates a user n1dba.

Oracle Single-Instance Software

The SingleInst component encapsulates and deploys files for the single-node Oracle database software.

ProcedureHow to Set Session Variables

Before you install the Oracle database software or create any databases, you must set the session variable sysPass. This variable acts as the default password for the database users SYS and SYSTEM.


Note –

The password that you define here is also the password that you use to run SQL*Plus.


To set the session variable in the N1 Grid SPS browser interface, follow these steps.

Steps
  1. At the top of the window in the N1 Grid SPS browser interface, click Session Variables.

  2. In the Session Variable field, type syspass.

  3. In the Password column, check the box.

  4. In the Value field, type the password to use for the database users SYS and SYSTEM.

    The password encrypts as you type.

  5. In the Action column, click Create.

  6. Provide the appropriate password when prompted.

ProcedureHow to Install Oracle Single-Instance Software for Oracle Database 10g

Steps
  1. In the Common Tasks section of the N1 Grid SPS browser interface, select Oracle Database 10g.

  2. On the Oracle Database 10g Common Tasks page, click Install.

  3. On the Plans Details page, click Run.

  4. Choose variables to use for the Oracle support scripts.

    • To use an existing variables set, select a name from the drop-down menu in the OraSpt component row of the Plan Parameters table.

    • To create a new variables set, click Select from List in the OraSpt component row of the Plan Parameters table.

      1. Click Create Set.

      2. Type a name for the variables set.

      3. In the field for installPath, provide the full path to the location into which you want the support scripts installed.

        For example, /var/tmp/Ora_Spt.

      4. In the field for installerHome, provide the full path to the location of the Oracle software files.

        For example, /mnt/Ora10gR1.

        This path can point to a CD or to some other location in which you have placed the appropriate files. For Oracle 10g, the installerHome variable points to the top directory of the software CD, which is the parent directory above the Disk1 directory.

      5. For single-instance support files, verify that the racInstall field is set to FALSE.

      6. Save the variables set.

      7. Select the variables set that you just saved from the drop-down menu in the OraSpt component row of the Plan Parameters table.

  5. Choose variables to use for the single-instance software.

    • To use an existing variables set, select a name from the drop-down menu in the SingleInst component row of the Plan Parameters table.

    • To create a new variables set, click Select from List in the SingleInst component row of the Plan Parameters table.

      1. Click Create Set.

      2. Type a name for the variables set.

      3. In the field for installPath, provide the full path to the location where you want to place the Oracle silent response file.

        For example, /var/tmp/Oracle10g.

      4. If a component already exists on this host for which the default value for ORACLE_HOME_NAME is used, define a value for the variable ORACLE_HOME_NAME.


        Note –

        Two components installed in the same physical host cannot have the same ORACLE_HOME_NAME.


      5. In the field for installerHome, provide the full path to the location of the Oracle software files.

        For example, /mnt/Ora10gR1.

        This path can point to a CD or to some other location in which you have placed the appropriate files. The installerHome variable points to the top directory of the software, which is the parent directory above the Disk1 directory.

      6. In the field for ORACLE_BASE, provide the path to the root directory into which you want the Oracle software to be installed.

        For example, /opt/app/oracle.

      7. To run the Oracle listener on this host, set the value for crListener to TRUE.


        Note –

        You should run only one Oracle listener per physical host.


      8. Verify that the softGroup and dbaGroup variables are correct.

        1. On the target host, type the following command: id -a oracle.

        2. Note the group names that were created for the oracle user.

        3. If the group names are different from the default names in the softGroup or dbaGroup fields, change those values as appropriate.

      9. Verify that the TOPLEVEL_COMPONENT variable exactly matches the version of Oracle to install.

        For example, if you intend to install 10.1.0.3.0, you must change the value of the TOPLEVEL_COMPONENT variable from its default of 10.1.0.2.0 to 10.1.0.3.0.

      10. Change other variables as appropriate.


        Note –

        For the oraPrflFile variable, the environment file must be either a Bourne shell, Korn shell, or bash profile. C shell is not supported.


      11. Save the variables set.

      12. Select the variables set that you just saved from the drop-down menu in the SingleInst component row of the Plan Parameters table.

  6. To select the target host, click Select from List next to the Target Host field on the Plans Details Run page.


    Note –

    Although the plug-in enables you to install this component into a host set, host sets are more likely to make sense for a RAC install rather than a single-instance install.


  7. To install the software, click Run Plan (includes preflight).

ProcedureHow to Install Oracle Single-Instance Software for Oracle Database 9i

Steps
  1. In the Common Tasks section of the N1 Grid SPS browser interface, select Oracle Database 9i.

  2. On the Oracle Database 9i Common Tasks page, click Install.

  3. On the Plans Details page, click Run.

  4. Choose variables to use for the Oracle support scripts.

    • To use an existing variables set, select a name from the drop-down menu in the OraSpt component row of the Plan Parameters table.

    • To create a new variables set, click Select from List in the OraSpt component row of the Plan Parameters table.

      1. Click Create Set.

      2. Type a name for the variables set.

      3. In the field for installPath, provide the full path to the location into which you want the support scripts installed.

        For example, /var/tmp/Ora_Spt.

      4. In the field for installerHome, provide the full path to the location of the Oracle software files.

        For example, /mnt/Ora9iR2.

        The installerHome variable points to the top directory of the software, which is the parent directory above the Disk1 directory. For Oracle 9i on Linux, the installerHome variable points to the directory that contains Oracle Patch No. 3006854.


        Note –

        The Oracle database plug-in does not support changing CDs during the installation process. Because Oracle 9i has three physical CDs, you should copy the CDs to a single location from which all information can be accessed.


      5. To run Oracle 9i on Linux, set the oracleRel variable to 9iR2.

      6. For single-instance support files, verify that the racInstall field is set to FALSE.


        Note –

        This release of the Oracle database plug-in only supports Oracle database software in single-instance environments. Support for Oracle RAC (Real Application Clusters) is not included. As a result, the racInstall variable must remain set to FALSE.


      7. Save the variables set.

      8. Select the variables set that you just saved from the drop-down menu in the OraSpt component row of the Plan Parameters table.

  5. Choose variables to use for the single-instance software.

    • To use an existing variables set, select a name from the drop-down menu in the SingleInst component row of the Plan Parameters table.

    • To create a new variables set, click Select from List in the SingleInst component row of the Plan Parameters table.

      1. Click Create Set.

      2. Type a name for the variables set.

      3. In the field for installPath, provide the full path to the location where you want to place the Oracle silent response file.

        For example, /var/tmp/Oracle9iR2.

      4. If a component already exists on this host for which the default value for ORACLE_HOME_NAME is used, define a value for the variable ORACLE_HOME_NAME.


        Note –

        Two components installed in the same physical host cannot have the same ORACLE_HOME_NAME.


      5. In the field for installerHome, provide the full path to the location of the Oracle software files.

        For example, /mnt/Ora9iR2.

        The installerHome variable points to the top directory of the software, which is the parent directory above the Disk1 directory. For Oracle 9i on Linux, the installerHome variable points to the directory that contains Oracle Patch No. 3006854.


        Note –

        The Oracle database plug-in does not support changing CDs during the installation process. Because Oracle 9i has three physical CDs, you should copy the CDs to a single location from which all information can be accessed.


      6. In the field for ORACLE_BASE, provide the path to the root directory into which you want the Oracle software to be installed.

        For example: /opt/app/oracle9

      7. To run the Oracle listener on this host, set the value for crListener to TRUE.


        Note –

        You should run only one Oracle listener per physical host.


      8. Verify that the softGroup and dbaGroup variables are correct.

        1. On the target host, type the following command: id -a oracle.

        2. Note the group names that were created for the oracle user.

        3. If the group names are different from the default names in the softGroup or dbaGroup fields, change those values as appropriate.

      9. Verify that the TOPLEVEL_COMPONENT variable exactly matches the version of Oracle to install.

      10. Change other variables as appropriate.


        Note –

        For the oraPrflFile variable, the environment file must be either a Bourne shell, Korn shell, or bash profile. C shell is not supported.


      11. Save the variables set.

      12. Select the variables set that you just saved from the drop-down menu in the SingleInst component row of the Plan Parameters table.

  6. To select the target host, click Select from List next to the Target Host field on the Plans Details Run page.


    Note –

    Although the plug-in enables you to install this component into a host set, host sets are more likely to make sense for a RAC install rather than a single-instance install.


  7. To install the software, click Run Plan (includes preflight).

Creating and Working with the Database

About the Database

The Oracle database comes in three flavors:

ProcedureHow to Create the Oracle 9i Database

Steps
  1. In the Common Tasks section of the N1 Grid SPS browser interface, select Oracle Database 9i.

  2. On the Oracle Database 9i Common Tasks page, click Create.

  3. On the Plans Details page, click Run.

  4. On the Plan Details Run page, select the target host on which you want to create the database.

  5. On the Plan Details Run page, provide plan variables information.

    1. Change the name of the Oracle Service, if needed.

      For Oracle 9i, the service name should be or9i.

    2. To make this service the default service, click the checkbox.

    3. Type the name of the database template to apply to this database.

      By default, the database template is General_Purpose. This template implies that the database will be used for a mixture of transaction types. The other possible templates are:

      • Data_Warehouse – Database optimized for responding to long-running and “ad hoc” queries

      • Transaction_Processing – Transaction-oriented database intended for handling many short transactions and canned queries

    4. If needed, change the character set to use for the database.

      By default, the character set is Western European (ISO 8859). For more information about character sets in Oracle, see the Oracle documentation.

  6. Click Run Plan (includes preflight).

ProcedureHow to Create the Oracle 10g Database

Steps
  1. In the Common Tasks section of the N1 Grid SPS browser interface, select Oracle Database 10g.

  2. On the Oracle Database 10g Common Tasks page, click Create.

  3. On the Plans Details page, click Run.

  4. On the Plan Details Run page, select the target host on which you want to create the database.

  5. On the Plan Details Run page, provide plan variables information.

    1. Change the name of the Oracle Service, if needed.

      For Oracle 10g, the service name should be or10g.

    2. To make this service the default service, click the checkbox.

    3. Type the name of the database template to apply to this database.

      By default, the database template is General_Purpose. This template implies that the database will be use for a mixture of transaction types. The other possible templates are:

      • Data_Warehouse – Database optimized for responding to long-running and “ad hoc” queries

      • Transaction_Processing – Transaction-oriented database intended for handling many short transactions and canned queries

    4. Choose the storage type to use for this database.

      • By default, the storage type is FS (file system).

      • ASM (Automatic Storage Management) provides support for a highly-available (RAID) solution.

        See the Oracle documentation for more information and additional user setup that you would need to perform.

        To use the ASM storage type, you need to provide additional information in four fields.

        1. Type a list of raw disks to use for ASM.

        2. Choose the type of ASM redundancy to provide.

        3. Type the name of the disk group to use for ASM.

        4. Type the password to use for ASM management.

      • RAW provides no support for file system utilities.

    5. Choose whether to manage your enterprise from a local web site or a central web site.

      If you choose to manage from a central web site, provide the URL.


      Note –

      To use centralized management, you must install the management agent on the target before you create the database. You can choose to use local management now and change to centralized management later.


    6. If needed, change the character set to use for the database.

      By default, the character set is Western European (ISO 8859). For more information about character sets in Oracle, see the Oracle documentation.

    7. (Optional) To enable Flash backups, type the path to the backup directory.

  6. Click Run Plan (includes preflight).

Using Oracle 9i and 10g on the Same Host

Once you have installed the software and created the databases, you need to combine Oracle net services configuration to run both versions of the software on a single host. Essentially, you should combine net service names and listener information into a single listener on the host. For more information, see the Oracle documentation.

Components

The Oracle Database Plug-In includes two components:

OraSpt Component

The OraSpt component provides support files for the Oracle database.

SingleInst Component

The SingleInst component encapsulates and deploys files for the single-node Oracle database software.

Troubleshooting

Problem:

You encounter an error when installing the database software.

Solution:

Check the value of your installerHome variable. The variable automatically appends certain information to the installerHome value. For example, if the Oracle software is in the directory /appsrc/Disk1/runInstaller, set the installerHome variable to just /appsrc. When needed, the plug-in appends Disk1/... to the path defined in the installerHome variable.

Problem:

You encounter a failure when deploying a component.

Solution:

Follow these steps:

  1. Remove any files deployed in the path specified by either the installPath or the ORACLE_BASE variable.

  2. Remove the file oraInst.loc in the /etc directory on Linux systems or in the /var/opt/oracle directory on Solaris systems.

  3. Kill any processes that the oracle user owns.

  4. Try the deployment again.