Symantec 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



    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

    At one stage I need to start the domain created :

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



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




    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-
    *+ 2 /usr/lib/jvm/java-1.8.0-openjdk-

    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 :


    KB : TEC1498397