Skip Headers
Oracle® Enterprise Manager Application Configuration Console Installation Guide
Release 5.3.2

E14652-02
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

3 Validate and Set Up the Database

First, you must run the provided database validation script to ensure that your database is ready for Application Configuration Console installation. Then configure the database for use by Application Configuration Console by running a SQL configuration script.

Note:

Run these scripts on the database server; do not run them remotely.

3.1 System Requirements

Application Configuration Console has specific hardware and software requirements for the database host, as well as recommended initial configuration settings for optimal performance. Ensure that you comply with the requirements and recommendations as stated in Table 2-3 in Chapter 2.

3.2 Oracle Database Input Validation Procedure

You must run a script to perform database input validation. This script must be run on the Oracle server; it cannot be run remotely.

  1. From the Application Configuration Console installation CD, extract oracle_db_setup.zip to a temporary directory on the Oracle server, such as C:\oaccdbInstall. The path to the unzip directory cannot contain spaces.

    Before proceeding, ensure that your environment complies with the following requirements:

    • The $ORACLE_HOME/bin directory must be in the user's PATH in order for the validation script to perform all testing successfully.

    • (Linux/UNIX) Grant the Oracle user read write access to the scripts directory of the unzipped oracle_db_setup.zip, for example, chmod 777 /tmp/db/oracle/scripts. Grant executable permissions to the *.sh scripts, for example chmod +x /tmp/db/oracle/scripts/*.sh. Sudo to the Oracle user: sudo - oracle.

  2. From the command line on the Oracle server, change directory to the unzipped db\oracle\scripts directory, for example:

    cd C:\OaccdbInstall\db\oracle\scripts
    
  3. Run the script appropriate to your platform:

    validate_oracle_w32.bat (Windows)
    validate_oracle_lin.sh (Linux)
    validate_oracle_sol.sh (UNIX)
    

    To accept a default value for those prompts that display a default, press Enter.

  4. Type i to perform preinstallation validation (u is for preupgrade validation, which is described in Appendix A).

    Validation test scope? (i/u): i
    
  5. Type the full path to the lib directory under the unzipped directory. The path must not contain lib, spaces, or a trailing (back)slash.

    Path to the "lib" directory (no default): unzip_dir\db\oracle
    
  6. Type the name of the Oracle Service that you want to use with Application Configuration Console. If you are using the Application Configuration Console-supplied database, take the default.

    Oracle Service Name(default=OACCSERV): servicename
    
  7. Type the Oracle System username and password at the prompts.

    System Username (default=SYSTEM):            username
    System Password (no default)                : password
    
  8. Type an Oracle username and password for the Application Configuration Console user. Since these values are not available until you run the database setup procedure, no validation occurs for the values specified here. Note, however, that this username must be entered in all uppercase letters.

    Application Configuration Console Username (default=OACCUSER): oaccusername
    Application Configuration Console Password                   : oaccpassword
    
  9. Type the name of the default tablespace to be used by Application Configuration Console.

    Application Configuration Console Default Tablespace (default=USERS): tablespace
    
  10. Type the name of the temporary tablespace to be used by Application Configuration Console.

    Application Configuration Console Temporary Tablespace (default=TEMP): tablespace
    
  11. In the directory from which you ran the script (the current directory), open the validate_oracle.out log file and look for the following entry at the end of the file:

    SUCCESS.  You are ready to run the setup_db.sql script.
    

    If the log reports errors, do not continue with database setup. Notify your system administrator and contact Oracle Support.

3.3 Oracle Database Set Up Procedure

As you run the script to set up the database, specify values for the prompts based on what you entered during validation. You can find these values, excluding passwords, in the validate_oracle.out log file. If the file contains multiple entries, use the values at the end, as they are the most recent. Here is a sample output from the log file:

...
Oracle Service                                         : OACCSERV 
System username                                        : SYSTEM 
System password                                        : ****** 
Application Configuration Console username             : OACCUSER 
Application Configuration Console password             : ****** 
Application Configuration Console default tablespace   : USERS
Application Configuration Console temporary tablespace : TEMP
...
Validating stored procedures directory: C:\OaccdbInstall\db\oracle
...

Perform database setup as follows:

  1. From the command line on the unzipped db\oracle\scripts directory, start the SQL configuration with this command:

    $ sqlplus /nolog @setup_db.sql
    Please specify values for the following:
    
  2. Type the full path to the lib directory under the unzipped directory. The path must not contain lib, spaces, or a trailing (back)slash.

    Path to the "lib" directory (no default): unzip_dir\db\oracle
    
  3. Type the name of the Oracle Service that you want to use with Application Configuration Console. If you are using the supplied database, take the default.

    Oracle Service (default=OACCSERV): servicename
    
  4. Type the Oracle System username and password at the prompts.

    System Username (default=SYSTEM)            : username
    System Password (no default)                : password
    
  5. Type an Oracle username and password for the Application Configuration Console user. This username must be entered in all uppercase letters.

    Application Configuration Console Username (default=OACCUSER): oaccusername
    Application Configuration Console Password                   : oaccpassword
    
  6. Type the name of the default tablespace to be used by Application Configuration Console.

    Application Configuration Console Default Tablespace (default=USERS): tablespace
    
  7. Type the name of the temporary tablespace to be used by Application Configuration Console.

    Application Configuration Console Temporary Tablespace (default=TEMP): tablespace
    

You should see "Connected" followed by a long sequence of SQL configuration commands and their results. You can safely ignore any error messages about tables or views that don't exist.

This procedure creates the Application Configuration Console-specific Oracle username (OACCUSER). You must provide the same username and password during Application Configuration Console (Core) Server installation.

You should optimize the database after you have installed the Core Server and loaded some data, as explained in "Optimize Database Performance" on page 29.

Note the existence of the setup_db.out file in the unzipped scripts directory (C:\OaccdbInstall\db\oracle\scripts). This file contains information that can be useful to technical support in troubleshooting situations. In fact, you can check the file to ensure successful setup. Specifically, you want to look for lines similar to the following:

SQL> @@test_stored_procs.sql;
SQL> select MV_UTIL_PKG.GET_RANDOM_STRING() from MV_ATOM
  2  /

MV_UTIL_PKG.GET_RANDOM_STRING()                                                 
------------------------------------------------------------------------------
Stored procedure setup successful.                                              

SQL> 
SQL> select MV_UTIL_PKG.GET_STRING('Stored procedure setup successful.') from MV_ATOM
  2  /

MV_UTIL_PKG.GET_STRING('STOREDPROCEDURESETUPSUCCESSFUL.')                       
------------------------------------------------------------------------------
Stored procedure setup successful.

If you don't see the Stored procedure setup successful line, one thing you might try to resolve the issue is to run the query below to verify the correct ownership of some of the database objects used by Application Configuration Console.

  1. Connect to the database as system/system with this command:

    $ sqlplus system/system@oaccserv
    
  2. Run the following query:

    select substr(owner,1,15) "OWNER", 
    substr(dbms_java.longname(object_name),1,50) "OBJECT_NAME", 
    status from all_objects where object_type='JAVA CLASS' and
    dbms_java.longname(object_name) like '%DocumentBuilder%';
    
  3. The results should be:

    OWNER      OBJECT_NAME                               STATUS
    -----------------------------------------------------------
    SYS        javax/xml/parsers/DocumentBuilder         VALID
    SYS        oracle/xml/jaxp/JXDocumentBuilder         VALID
    SYS        oracle/xml/jaxp/JXDocumentBuilderFactory  VALID
    SYS        oracle/xml/parser/v2/XSLDocumentBuilder   VALID
    SYS        javax/xml/parsers/DocumentBuilderFactory  VALID
    SYS        oracle/xml/parser/v2/DocumentBuilder      VALID
    
  4. Look in the OBJECT_NAME column for any org/apache/xerces/... objects. If there are any, note the owner of that object and run this dropjava command to remove the object from the database:

    dropjava -user <owner from query>/<password> -synonym <path to xerces.jar>
    
  5. Rerun the query from Step 2 and verify that there are no org/apache/xerces/... objects in the results.

3.4 A Note on Database Backups

Oracle expects that you have your own policies on backing up the database, including how you perform an export and import of the database. The information provided here pertains to steps you should take prior to a database import.

The scripts referenced below are bundled with the database setup package (and the database upgrade package). Run the scripts as the SYSTEM USER.

First, if you are importing to a host where an Application Configuration Console schema existed, you must drop the Application Configuration Console-specific user (OACCUSER). For example:

> sqlplus SYSTEM/SYSTEM@OACCSERV @drop_users.sql OACCUSER

Next, you must create the OACC USER, specifying the username and password, and the tablespace. For example:

> sqlplus SYSTEM/SYSTEM@OACCSERV @create_users.sql OACCUSER OACCUSER USER

Finally, you have to grant the required permissions to the OACC USER. The command must include the full Oracle lib path. For example:

> sqlplus SYSTEM/SYSTEM@OACCSERV @grant_permissions.sql OACCUSER install_dir\db\oracle 

Ensure that the path does not contain the word lib, any spaces, or a trailing (back) slash.

Note:

The database and the SVN repository must always be in synch. Whenever you back up the database, be sure to back up the SVN repository. You can find the location of the repository in server_modules_registry.xml. See the "url" property value for the module "com.mvalent.service.system.repository.version.impl.subversion.SvnSessionContext".