5 Replies Latest reply on Dec 5, 2013 6:26 PM by Hussein Sawwan-Oracle

    OC4J bind socket address issue


      Hi i am using DB( and APPS(  Now i have cloned a new instance and it runs on port 8050. Now i want to install and configure OC4J with it. I have done the OC4J Installation Successfully. Here i used the OC4J Version 9.0.3.I have changed the http-web-site.xml port number to 8890 and rmi.xml port to 23793 as per the document i got.To create the starting script, file name called “.start_oc4j” I issued cd $OC4J_TOP/j2ee/home/ then

      java -jar oc4j.jar and


      it throws the error

      [applpdev@oraapps ~]$ cd $OC4J_TOP

      [applpdev@oraapps home]$ pwd


      [applpdev@oraapps oc4j]$ cd j2ee/home/

      [applpdev@oraapps home]$ java -jar oc4j.jar

      Error starting JMS-Server: Unable to bind socket: Address already in use

      Error starting ORMI-Server.  Unable to bind socket: Address already in use

      [applpdev@oraapps home]$

        • 1. Re: OC4J bind socket address issue
          Asif Muhammad



          The respective port is been already used. Please check the following for probable solution and workarounds:





          Thanks &

          Best Regards,

          • 2. Re: OC4J bind socket address issue



                 I changed the port no in http-web-site.xml port number to 8050(application port no) and rmi.xml port to 23793 and then i issue

            [applpdev@oraapps ~]$ cd $OC4J_TOP/j2ee/home

            [applpdev@oraapps home]$ java -jar oc4j.jar

            Auto-deploying file:/pdev/p01/oracle/pixappl/pwr/11.5.0/oc4j/j2ee/home/default-web-app (New server version detected)...

            Oracle9iAS ( Containers for J2EE initialized

            and nothing displayed after this and I didn't disturb the terminal. When i tried to open the application in browser the default web-page is opened and displays the web-page Oracle9iAS Containers for J2EE. Moreover i did these things to create the starting script, file name called “.start_oc4j” but it's not created and i want to configure my application with this OC4J. I don't know whether the process is going on or not. Can you please help me to get through this.

            • 3. Re: OC4J bind socket address issue
              Hussein Sawwan-Oracle

              Please issue "java -jar oc4j.jar -err [file] -out [file]" -- How To Start, Shutdown Or Restart Standalone OC4J With Options (Doc ID 151170.1)




              • 4. Re: OC4J bind socket address issue

                Hi Hussein,

                     Now i am facing a new issue. I am using oc4j 9.0.3 version. When i started the oc4j i am getting the following error.


                [applpdev@oraapps home]$ java -jar oc4j.jar

                Auto-deploying ejb (No previous deployment found)... Exception in thread "Orion Launcher" java.lang.NoClassDefFoundError: sun/jdbc/rowset/CachedRowSet

                        at java.lang.Class.getDeclaredMethods0(Native Method)

                        at java.lang.Class.privateGetDeclaredMethods(Class.java:2427)

                        at java.lang.Class.privateGetPublicMethods(Class.java:2547)

                        at java.lang.Class.getMethods(Class.java:1410)



                        at com.evermind.server.ejb.compilation.StatelessSessionBeanCompilation.compile(StatelessSessionBeanCompilation.java:40)

                        at com.evermind.server.ejb.compilation.Compilation.compile(Compilation.java:288)

                        at com.evermind.server.ejb.EJBContainer.postInit(EJBContainer.java:551)

                        at com.evermind.server.Application.postInit(Application.java:431)

                        at com.evermind.server.Application.setConfig(Application.java:136)

                        at com.evermind.server.ApplicationServer.addApplication(ApplicationServer.java:1635)

                        at com.evermind.server.ApplicationServer.initializeApplications(ApplicationServer.java:1585)

                        at com.evermind.server.ApplicationServer.setConfig(ApplicationServer.java:1240)

                        at com.evermind.server.ApplicationServerLauncher.run(ApplicationServerLauncher.java:93)

                        at java.lang.Thread.run(Thread.java:662)

                Caused by: java.lang.ClassNotFoundException: sun.jdbc.rowset.CachedRowSet

                        at com.evermind.naming.ContextClassLoader.findClass(ContextClassLoader.java:456)

                        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)

                        at com.evermind.naming.ContextClassLoader.loadClass(ContextClassLoader.java:135)

                        at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

                        ... 15 more

                So i uninstalled jdk1.6.0 and installed jdk1.4.2 and i started the OC4J. The default web page is displayed. Now i moved a .ear file to the directory APPL_TOP/pwr/11.5.0/oc4j/j2ee/home/applications added the entries in the server.xml,application.xml,http-web-site.xml and the directory is created for the respective .ear file. Under the path APPL_TOP/pwr/11.5.0/oc4j/j2ee/home/applications there are two default directories called dms0 and dms and they are accessible through the browser but my directory created by the .ear file is not accessible through the browser and it throws the error Can't find the directory. I checked the log and the content is


                12/5/13 6:06 PM iLogin: JspServlet: unable to dispatch to requested page: Exception:oracle.jsp.provider.JspCompileException: <H3>Errors compiling:/pdev/p01/oracle/pixappl/pwr/11.5.0/oc4j/j2ee/home/application-deployments/iLogin/iLogin/persistence/_pages//_iLogin.java</H3><pre>error: Invalid class file format in /usr/java/j2sdk1.4.2_19/jre/lib/rt.jar(java/io/PrintWriter.class).  The major.minor version '48.0' is too recent for this tool to understand.

                /pdev/p01/oracle/pixappl/pwr/11.5.0/oc4j/j2ee/home/application-deployments/iLogin/iLogin/persistence/_pages/_iLogin.java:11: Class java.io.PrintWriter not found in import.

                import java.io.PrintWriter;


                error: Invalid class file format in /usr/java/j2sdk1.4.2_19/jre/lib/rt.jar(java/io/IOException.class).  The major.minor version '48.0' is too recent for this tool to understand.

                /pdev/p01/oracle/pixappl/pwr/11.5.0/oc4j/j2ee/home/application-deployments/iLogin/iLogin/persistence/_pages/_iLogin.java:12: Class java.io.IOException not found in import.

                import java.io.IOException;


                error: Invalid class file format in /usr/java/j2sdk1.4.2_19/jre/lib/rt.jar(java/sql/Connection.class).  The major.minor version '48.0' is too recent for this tool to understand.

                /pdev/p01/oracle/pixappl/pwr/11.5.0/oc4j/j2ee/home/application-deployments/iLogin/iLogin/persistence/_pages/_iLogin.java:14: Class java.sql.Connection not found in import.

                import java.sql.Connection;



                12/5/13 6:06 PM iLogin: Recursive error in error-page calling for /iMODError.jsp

                javax.servlet.ServletException: Recursive error in error-page calling for /iMODError.jsp (status 500)

                  at com.evermind[Oracle9iAS ( Containers for J2EE].server.http.EvermindHttpServletResponse.sendError(EvermindHttpServletResponse.java:1204)

                  at oracle.jsp.runtimev2.JspReportUtil.sendError(JspReportUtil.java:96)

                  at oracle.jsp.runtimev2.JspReportUtil.reportException(JspReportUtil.java:125)

                  at oracle.jsp.runtimev2.JspPageTable.compileAndServe(JspPageTable.java:573)

                  at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:272)

                  at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:465)

                  at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:379)

                  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

                  at com.evermind[Oracle9iAS ( Containers for J2EE].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:721)

                  at com.evermind[Oracle9iAS ( Containers for J2EE].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:306)

                  at com.evermind[Oracle9iAS ( Containers for J2EE].server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:209)

                  at com.evermind[Oracle9iAS ( Containers for J2EE].server.http.EvermindHttpServletResponse.sendError(EvermindHttpServletResponse.java:1244)  and the same errors are repeated

                • 5. Re: OC4J bind socket address issue
                  Hussein Sawwan-Oracle

                  Please see (OC4J 9.0.3 with JDK 1.4.x : JspCompileException Error Invoking JSP Page (Doc ID 219943.1)).