Layer 7 Access Management

Tech tip : Oracle Glassfish 3.0 : Error while starting domain

  • 1.  Tech tip : Oracle Glassfish 3.0 : Error while starting domain

    Posted 03-10-2017 04:32 AM

    Issue

     

    When I start the Oracle directory Server with a specific domain configured, I'm getting the following error and the server doesn't start :

    Waiting for dscc7 to start .....Error starting domain dscc7.
    The server exited prematurely with exit code 1.

    Before it dies, it produces the following output:

    Launching GlassFish on Felix platform

     

    ERROR: Error parsing system bundle export statement: org.osgi.framework; version=1.6.0, org.osgi.framework.launch; version=1.0.0, org.osgi.framework.wiring; version=1.0.0, org.osgi.framework.startlevel; version=1.0.0, org.osgi.framework.hooks.bundle; version=1.0.0, org.osgi.framework.hooks.resolver; version=1.0.0, org.osgi.framework.hooks.service; version=1.1.0, org.osgi.framework.hooks.weaving; version=1.0.0, org.osgi.service.packageadmin; version=1.2.0, org.osgi.service.startlevel; version=1.1.0, org.osgi.service.url; version=1.0.0, org.osgi.util.tracker; version=1.5.0, , org.glassfish.embeddable;org.glassfish.embeddable.spi;version=3.1.1 (org.osgi.framework.BundleException: Exported package names cannot be zero length.)

     

    Why do I have this issue and how can I solve it ?
    The goal is to use Glassfsh as application server to manage the Oracle Directory Server instance. We want to use the oracle Directory instance as Policy Store.

    I have followed the Oracle documentation for the installation and configuration of Oracle directory Server and Glassfish 3.0


    http://docs.oracle.com/cd/E29127_01/doc.111170/e28973/installing--dsee.htm
    https://docs.oracle.com/cd/E26576_01/doc.312/e24935/installing.htm

    At one stage I need to start the domain created :

    http://docs.oracle.com/cd/E29127_01/doc.111170/e28973/deploying-dscc-war-file.htm#BABDHIDH

    $ asadmin --user admin start-domain --domaindir glassfish-domain-path dscc7

    Cause

     

    Your Oracle directory Server doesn't use the JDK 1.7 and that's why it doesn't start.

     

    Resolution

     

    To solve this issue, you need to use the JDK 1.7 instead of the JDK 1.8.
    For change the JDK version on the RedHat System, you need to do the following steps in command line :

    $ sudo update-alternatives --config java

    There are 2 programs which provide 'java'.

    Selection Command
    -----------------------------------------------
    1 /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.91-2.6.2.3.el7.x86_64/jre/bin/java
    *+ 2 /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64/jre/bin/java

    Enter to keep the current selection[+], or type selection number: 1

    then start the domain :

    $ asadmin --user admin start-domain --domaindir glassfish-domain-path dscc7

    Waiting for dscc7 to start ...................................
    Successfully started the domain : dscc7
    domain Location: glassfish-domain-path/dscc7
    Log File: glassfish-domain-path/dscc7/logs/server.log
    Admin Port: 3737
    Command start-domain executed successfully.

    Additional Information

     

    Then you can start configuring the policy store :
    https://docops.ca.com/ca-single-sign-on/12-52-sp1/en/installing/policy-server/configure-ldap-directory-server-policy-session-and-key-stores/configure-an-ldap-directory-server-as-a-policy-store/configure-an-oracle-directory-server-as-a-policy-store

     

    KB : TEC1498397