Sun Identity Manager 8.1 Installation

Configuring a Sun GlassFish Enterprise Server Application Server Data Source for Identity Manager

Refer to the documentation for the Sun GlassFish Enterprise Server application server for information about creating and configuring a data source.


Note –

In this procedure, the environment variable WSHOME (or the equivalent Java system property waveset.home) must contain the path to the location where the Identity Manager web application is deployed.


ProcedureTo Point the Repository to an Application Server Data Source

  1. Remove the j2ee.jar file from the $WSHOME/WEB-INF/lib directory. This file causes conflicts with the j2ee.jar that ships with Application Server.

  2. If you are not using default host name and port, then you must add the following flags to your JAVA_OPTS environment variable:


    -Dorg.omg.CORBA.ORBInitialHost=Hostname -Dorg.omg.CORBA.ORBInitialPort=Port

    The default values for Hostname and Port are localhost and 3700, respectively.

  3. Set your CLASSPATH to include the following application server JAR files (in order):


    SAS_INSTALL_DIR/lib/appserv-admin.jar
    SAS_INSTALL_DIR/lib/appserv-rt.jar
    SAS_IMQ_DIR/lib/imq.jar
    SAS_INSTALL_DIR/lib/j2ee.jar
  4. Set your CLASSPATH to include the JAR file or files required for your JDBC connection. For example:

    DataDirect JDBC Driver for Oracle

    • SAS_INSTALL_DIR/lib/jdbcdrivers/smoracle.jar

    • SAS_INSTALL_DIR/lib/jdbcdrivers/smbase.jar

    • SAS_INSTALL_DIR/lib/jdbcdrivers/smutil.jar

    MySQL

    • MYSQL_DIR/lib/mysql-connector-java-3.0.9-stable-bin.jar

  5. Change directories to $WSHOME/WEB-INF.

  6. If you are using any driver other than Data Direct JDBC Driver for Oracle that ships with Sun GlassFish Enterprise Server, connect to the data source with the following command:


    lh setRepo -v -tType -iInitContextFactory -fDataSourcePath -uiiop://hostname:port
    

    For example:


    lh setRepo -v -tOracle -icom.sun.enterprise.naming.SerialInitContextFactory -fjdbc/idm
    -uiiop://localhost:3700

    Note –

    If you enter this command when using the Data Direct JDBC Driver for Oracle, the operation will fail with following exception:

    java.sql.SQLException: [sunm][Oracle JDBC Driver]This driver is locked for use with embedded applications.


  7. The Data Direct JDBC Driver for Oracle that ships with Sun GlassFish Enterprise Server is “locked” so that it works only with embedded applications. That is, the driver works only within the web container. As a result, to use the lh command, you must create a separate connection.

    1. Archive the existing $WSHOME/WEB-INF/ServerRepository.xml file.

    2. Use the following command to force the connection and create a new ServerRepository.xml file:


      lh setRepo -tOracle -icom.sun.enterprise.naming.SerialInitContextFactory 
      -fjdbc/IdMgr -uiiop://Hostname:Port -n -o ServerRepository.xml