9 Replies Latest reply on Apr 19, 2012 8:32 AM by Wolf-Dieter Fink

    Question about UDP & Clustering

    Chris Lopez Newbie

      We recently changed up our environment so that all our application servers are in one datacenter to avoid any communications issues, but we still seem to get the following:


      2012-04-14 02:40:48,825 ERROR [org.jgroups.protocols.UDP] failed sending message to null (0 bytes)

      java.io.InterruptedIOException: operation interrupted

              at java.net.PlainDatagramSocketImpl.send(Native Method)

              at java.net.DatagramSocket.send(DatagramSocket.java:612)

              at org.jgroups.protocols.UDP._send(UDP.java:316)

              at org.jgroups.protocols.UDP.sendToAllMembers(UDP.java:286)

              at org.jgroups.protocols.TP.doSend(TP.java:938)

              at org.jgroups.protocols.TP.send(TP.java:927)

              at org.jgroups.protocols.TP.down(TP.java:713)

              at org.jgroups.stack.Protocol.receiveDownEvent(Protocol.java:499)

              at org.jgroups.stack.Protocol.passDown(Protocol.java:533)

              at org.jgroups.protocols.PING.sendMcastDiscoveryRequest(PING.java:214)

              at org.jgroups.protocols.PING.sendGetMembersRequest(PING.java:208)

              at org.jgroups.protocols.PingSender.run(PingSender.java:59)

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


      Can someone explain to me two things:


      1 - Why would we see these

      2 - Should the UDP bind_port config in the cluster-service.xml be the same value across all the servers in a cluster, or should they be different values?


      BTW, we are using jboss as 4.23




        • 1. Re: Question about UDP & Clustering
          Wolf-Dieter Fink Master

          Is the JVM started with the option-Djava.net.preferIPv4Stack=true?

          • 2. Re: Question about UDP & Clustering
            Chris Lopez Newbie

            No... I am not familiar with protocol details, but I thought most networks preferred IPv6 or IPv7 ?


            Can you tell me what the details/impacts of this are?


            FYI, here is my startup for the JVM (yes we are running vignette)


            DIRNAME=`dirname $0`

            if [ "x$JBOSS_HOME" = "x" ]; then JBOSS_HOME=`cd $DIRNAME/../..; pwd`; fi

            JAVA_OPTS="$JAVA_OPTS -Xms1584m -Xmx1584m -XX:PermSize=128m -XX:MaxPermSize=384m -verbose:gc -Xloggc:/app/log/vap/jboss-gc/gc.log -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -Dcom.vignette.portal.installdir.path=/app/vignette/vap/portal -Dcom.vignette.installDir=/app/vignette/vcm/Content/7_5 -Dcom.vignette.workingDir=/app/share/vcm/inst-vgninst/cfgagent/vcm-vgninst/cdsvcs/stage-live/cds-live/as/conf -Djava.awt.headless=true -Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=false"

            . "$JBOSS_HOME"/bin/run.sh -c portal -b





            • 3. Re: Question about UDP & Clustering
              Wolf-Dieter Fink Master

              Uuhh, IPv7 you are in the future

              There are IPv4 and IPv6 network standards.


              IPv6 is not supported by AS4, so set something like:

              JAVA_OPTS="$JAVA_OPTS -Djava.net.preferIPv4Stack=true"

              to your run.conf (linux) or run.conf.bat (win) to ensure the setting.

              If you set JAVA_OPTS by your environment you should add it here

              • 4. Re: Question about UDP & Clustering
                Chris Lopez Newbie

                LOL IPV7... not sure where that came from...


                As of right now, I don't believe our network has implemented ipv6, so what would the impact of the jvm startup not having that parameter be?.... Sorry, I try to fully understand issues/resolutions before implementing..




                • 5. Re: Question about UDP & Clustering
                  Wolf-Dieter Fink Master

                  It's only to force IPv4 use, I don't understand the reason behind exactly.

                  But if the OS is able to connect to IPv6 you might have problems if you not force a IPv4 use.

                  • 6. Re: Question about UDP & Clustering
                    Chris Lopez Newbie

                    do you know if the bind_port config under the UDP section within cluster service should be the same port or different ports on our cluster of 4 jboss servers?

                    • 7. Re: Question about UDP & Clustering
                      Wolf-Dieter Fink Master

                      What port you mean, can you show the configuration.

                      If you don't change the config you should use the -b to set the ip-binding and -u and -g for JGroups clustering.

                      -b depends on the installation/instance and -u-g must be the same for clustering

                      • 8. Re: Question about UDP & Clustering
                        Chris Lopez Newbie

                        in the cluster-service.xml file (which defines your cluster, there is a section for partitionconfig immediately under that is the UDP configs.... here is ours:


                                <UDP mcast_addr="${jboss.partition.udpGroup:}"
                                     down_thread="false" up_thread="false"/>


                        What I cannot figure out, is whether or not the bind_port config should be the same or different on all my app servers that are in the cluster.




                        • 9. Re: Question about UDP & Clustering
                          Wolf-Dieter Fink Master

                          can be same or different.

                          See wiki

                          "The port to which the transport binds. Default of 0 binds to any (ephemeral) port"