8 Replies Latest reply on Mar 18, 2008 10:18 AM by brian.stansberry

    StackOverflowError when starting JBoss Cluster

    happyspaceinvader

      I get a StackOverflow error when starting up the primary node of my cluster. Not sure what's going wrong but I found this article which has the advice:

      It looks like you may have specified the HA-JNDI configuration as the default JNDI configuration. The result of this is that any name which cannot be located within the HA-JNDI will cause a recursive invocation (and a StackOverflow).


      I don't quite understand that - where would I have made this error? The StackOverflow error itself follows:

      2008-03-13 13:57:44,609 WARN [org.jboss.soa.esb.listeners.lifecycle.AbstractThreadedManagedLifecycle] Unexpected error from doRun()
      java.lang.StackOverflowError
       at java.net.PlainDatagramSocketImpl.receive0(Native Method)
       at java.net.PlainDatagramSocketImpl.receive(PlainDatagramSocketImpl.java:136)
       at java.net.DatagramSocket.receive(DatagramSocket.java:712)
       at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1435)
       at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1548)
       at org.jnp.interfaces.NamingContext.list(NamingContext.java:868)
       at javax.naming.InitialContext.list(InitialContext.java:442)
       at org.jboss.ha.jndi.TreeHead.list(TreeHead.java:354)
       at org.jboss.ha.jndi.HAJNDI.list(HAJNDI.java:161)
       at sun.reflect.GeneratedMethodAccessor110.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.ha.framework.interfaces.HARMIClient.invoke(HARMIClient.java:312)
       at $Proxy223.list(Unknown Source)
       at org.jnp.interfaces.NamingContext.list(NamingContext.java:878)
       at javax.naming.InitialContext.list(InitialContext.java:442)
       at org.jboss.ha.jndi.TreeHead.list(TreeHead.java:354)
       at org.jboss.ha.jndi.HAJNDI.list(HAJNDI.java:161)
       at sun.reflect.GeneratedMethodAccessor110.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.ha.framework.interfaces.HARMIClient.invoke(HARMIClient.java:312)
       at $Proxy223.list(Unknown Source)
       at org.jnp.interfaces.NamingContext.list(NamingContext.java:878)
       at javax.naming.InitialContext.list(InitialContext.java:442)
       at org.jboss.ha.jndi.TreeHead.list(TreeHead.java:354)
       at org.jboss.ha.jndi.HAJNDI.list(HAJNDI.java:161)
       at sun.reflect.GeneratedMethodAccessor110.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.ha.framework.interfaces.HARMIClient.invoke(HARMIClient.java:312)
      
      


        • 1. Re: StackOverflowError when starting JBoss Cluster
          brian.stansberry

          Have you edited conf/jndi.properties? Or, do any of your deployments package a jndi.properties file? Or, do you in any way set the java.naming.url system property?

          • 2. Re: StackOverflowError when starting JBoss Cluster
            happyspaceinvader

             

            "bstansberry@jboss.com" wrote:
            Have you edited conf/jndi.properties?

            No, I haven't altered this file at all.

            "bstansberry@jboss.com" wrote:

            Or, do any of your deployments package a jndi.properties file?

            I haven't deployed anything of my own yet - I've just got a fresh copy of JBoss 4.2.2.GA, run the JBoss ESB upgrade against the 'all' configuration, set up a shared MySQL database in deploy-hasingleton/jms and then started the server thus:

            ./run.sh -Djboss.bind.address=10.1.2.10 -b 10.1.2.10 -c all
            


            "bstansberry@jboss.com" wrote:

            Or, do you in any way set the java.naming.url system property?


            No, but given the above arguments to the run.sh script, maybe that's the problem? Or maybe the arguments above are the problem?

            • 3. Re: StackOverflowError when starting JBoss Cluster
              happyspaceinvader

              Hmmm.. your reply got me thinking about the way I'm starting up the cluster though. If I simply start up with

              ./run.sh -c all


              I get no StackOverflowError. Before I go down any blind alleys here, can I just confirm whether or not binding to a specific IP address is a valid practice with JBoss Cluster?

              • 4. Re: StackOverflowError when starting JBoss Cluster
                brian.stansberry

                Sure, binding to an address is valid. If you don't specify an address, for security reasons all services bind to localhost, which is pretty useless for a production system.

                BTW, setting -Djboss.bind.address with the same value is redundant if you use -b.

                Have you tried this solution discussed on the JIRA you linked?

                "Srinivasu Nidadavolu" wrote:

                I also got this issue. I got this error when I am binding my server to a particular IP address.

                I found a place to cause the issue.

                all\deploy\jbossesb.sar\esb.juddi.xml, java.naming.provider.url is pointing to localhost in the following way.

                <entry key="java.naming.provider.url">jnp://localhost:1099</entry>

                If we are binding our server to some IPaddress while starting the server, then we have to change this localhost to corresponding IP
                address. I modified in the following way.

                <entry> key="java.naming.provider.url">jnp://${jboss.bind.address}:1099</entry>

                and started the server with IPaddress. This issue is not appearing.


                • 5. Re: StackOverflowError when starting JBoss Cluster
                  happyspaceinvader

                   

                  "bstansberry@jboss.com" wrote:


                  Have you tried this solution discussed on the JIRA you linked?



                  How interesting... Srini must have discovered that fix after he left our offices last week (he was helping us set up the Jboss cluster)!

                  Yes I tried that fix, and the problem has gone.

                  • 6. clustering Jboss4.2.2.GA in Linux..
                    praveenas

                    Hi ,

                    I am new to Jboss.
                    I am currently working for evaluting different application servers..(tomcat, Jboss, Geronimo)
                    I was looking for the clustering feature in Jboss 4.2.2.GA. I am not able to find any proper response from the forums of Jboss.. Please let me know where exactly can i get the information regarding my issues and bugs..

                    Here is my issue:
                    I was trying to cluster jboss4.2.2.GA in fedora 8..
                    According to the documentation given, I ve run the apache server(httpd-2.0.63);
                    I was able to run Jboss and Apache servers parallely..
                    But, when tested with an application like: http://localhost:9999/sample/hello.jsp is running properly(jboss)
                    And when parallely in another tab, http://localhost/sample/hello.jsp is returning 404 NOTFOUND error page.. and the error_log page of apache is found with the message:


                    [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                    [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                    [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/favicon.ico
                    [Tue Mar 18 11:57:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                    [Tue Mar 18 12:32:59 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample

                    Please let me know abt the relevant information at the earliest..



                    --
                    Regards,

                    Praveena Chalamcharla,
                    Securview....

                    "bstansberry@jboss.com" wrote:
                    Have you edited conf/jndi.properties? Or, do any of your deployments package a jndi.properties file? Or, do you in any way set the java.naming.url system property?


                    • 7. Jboss 4.2.2.GA clustering..
                      praveenas

                      Hi ,

                      I am new to Jboss.
                      I am currently working for evaluting different application servers..(tomcat, Jboss, Geronimo)
                      I was looking for the clustering feature in Jboss 4.2.2.GA. I am not able to find any proper response from the forums of Jboss.. Please let me know where exactly can i get the information regarding my issues and bugs..

                      Here is my issue:
                      I was trying to cluster jboss4.2.2.GA in fedora 8..
                      According to the documentation given, I ve run the apache server(httpd-2.0.63);
                      I was able to run Jboss and Apache servers parallely..
                      But, when tested with an application like: http://localhost:9999/sample/hello.jsp is running properly(jboss)
                      And when parallely in another tab, http://localhost/sample/hello.jsp is returning 404 NOTFOUND error page.. and the error_log page of apache is found with the message:


                      [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                      [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                      [Tue Mar 18 11:41:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/favicon.ico
                      [Tue Mar 18 11:57:05 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample
                      [Tue Mar 18 12:32:59 2008] [error] [client 127.0.0.1] File does not exist: /usr/local/apache2/htdocs/sample

                      Please let me know abt the relevant information at the earliest..



                      --
                      Regards,

                      Praveena Chalamcharla,
                      Securview....

                      • 8. Re: StackOverflowError when starting JBoss Cluster
                        brian.stansberry