Re: Trouble with cluster and JMX
Eric B. wrote: Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:49937f4b.9050...@hanik.com... sure turn on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties however, regular membership discovery over multicast show up even without these entries did you mark your webapp distributable/ Crap. Now that you mention it, I think I forgot to do that. Will have to check up on that tomorrow. However, after a bunch of fiddling around, putting the Manager within the context element got session replication working, even if it isn't marked as distributable /. Would that be expected behaviour by putting the Manager in the context? yes, when web.xml has distributable/, that's what tomcat does internally, swaps out the manager Will check tomorrow and post findings. Thanks, Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Re: Trouble with cluster and JMX
To get more verbose messages, the documentation mentions to use the key org.apache.catalina.tribes.MESSAGES I am currently trying it... -Jorge -Original Message- From: news [mailto:n...@ger.gmane.org] On Behalf Of Eric B. Sent: Wednesday, February 11, 2009 11:55 PM To: users@tomcat.apache.org Subject: Re: Trouble with cluster and JMX Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:49937f4b.9050...@hanik.com... sure turn on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties however, regular membership discovery over multicast show up even without these entries did you mark your webapp distributable/ Crap. Now that you mention it, I think I forgot to do that. Will have to check up on that tomorrow. However, after a bunch of fiddling around, putting the Manager within the context element got session replication working, even if it isn't marked as distributable /. Would that be expected behaviour by putting the Manager in the context? Will check tomorrow and post findings. Thanks, Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Re: Trouble with cluster and JMX
I did not manage to get more logging from the tribes package. Did you? I am using the default tomcat-juli configuration, I didn't get any ouput about sessions replicating other than the initial startup messages. -Original Message- From: Jorge Medina [mailto:jmed...@e-dialog.com] Sent: Thursday, February 12, 2009 10:44 AM To: Tomcat Users List Subject: RE: Re: Trouble with cluster and JMX To get more verbose messages, the documentation mentions to use the key org.apache.catalina.tribes.MESSAGES I am currently trying it... -Jorge -Original Message- From: news [mailto:n...@ger.gmane.org] On Behalf Of Eric B. Sent: Wednesday, February 11, 2009 11:55 PM To: users@tomcat.apache.org Subject: Re: Trouble with cluster and JMX Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:49937f4b.9050...@hanik.com... sure turn on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties however, regular membership discovery over multicast show up even without these entries did you mark your webapp distributable/ Crap. Now that you mention it, I think I forgot to do that. Will have to check up on that tomorrow. However, after a bunch of fiddling around, putting the Manager within the context element got session replication working, even if it isn't marked as distributable /. Would that be expected behaviour by putting the Manager in the context? Will check tomorrow and post findings. Thanks, Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Trouble with cluster and JMX
did you mark your webapp distributable/ Crap. Now that you mention it, I think I forgot to do that. Will have to check up on that tomorrow. However, after a bunch of fiddling around, putting the Manager within the context element got session replication working, even if it isn't marked as distributable /. Would that be expected behaviour by putting the Manager in the context? yes, when web.xml has distributable/, that's what tomcat does internally, swaps out the manager Will check tomorrow and post findings. Don't I feel like a twit. Indeed, I had forgotten to mark it as distributable. I added that to my context, removed the Manager defn from within the context, and all is working as I would have liked. Thanks for the pointer! Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Re: Trouble with cluster and JMX
Jorge Medina jmed...@e-dialog.com wrote in message news:9dd36c99332ab7438f8d73c048d8c62c02096...@sneezy.ad.e-dialog.com... I did not manage to get more logging from the tribes package. Did you? I am using the default tomcat-juli configuration, I didn't get any ouput about sessions replicating other than the initial startup messages. Like I said, I turned on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties and I got more information about session replication, however, not necessarily as detailed as I would have like. But overall, it at least told me that sessions were replicating and I was able to see what was going on. Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Trouble with cluster and JMX
Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:499242de.2090...@hanik.com... log looks good, the warning could be that you are using an old configuration option take a look at http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html also, what could mean that it doesn't work, would be that multicast is not working for you, and you need to enable multicast. I've ensured that multicast is enabled. I've added the multicast route to the routing tables. I've even checked my multicast route between 2 machines by pinging 224.0.0.1 and getting replies from both machines. However, I still don't see any of the cluster beans in jConsole. Any ideas? you can also set up static members, http://tomcat.markmail.org/search/?q=cluster%20static%20member#query:cluster%20static%20member%20list%3Aorg.apache.tomcat.users%20date%3A200707-200902%20from%3A%22SANCHEZ%2C%20Michel%22+page:1+mid:slqnel56c2lougo3+state:results Thanks, but I would prefer having auto-detection if possible. Right now, I'm trying to figure out how to log / debug the information to ensure that everything is being sent, however, like I said, I don't even see the beans exposed in jConsole MBeans anywhere. Is there any other way to enable logging of the cluster? Thanks! Eric Using CATALINA_BASE: /opt/tomcat6 Using CATALINA_HOME: /opt/tomcat6 Using CATALINA_TMPDIR: /opt/tomcat6/temp Using JRE_HOME: /usr/java/jre1.6.0_11 Feb 11, 2009 10:25:06 AM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-8080 Feb 11, 2009 10:25:06 AM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 549 ms Feb 11, 2009 10:25:06 AM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Feb 11, 2009 10:25:06 AM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/6.0.18 Feb 11, 2009 10:25:06 AM org.apache.catalina.ha.tcp.SimpleTcpCluster start INFO: Cluster is about to start Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.transport.ReceiverBase bind INFO: Receiver Server Socket bound to:/208.85.114.235:4000 Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.membership.McastServiceImpl setupSocket INFO: Setting cluster mcast soTimeout to 500 Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:4 Feb 11, 2009 10:25:06 AM org.apache.catalina.ha.tcp.SimpleTcpCluster memberAdded INFO: Replication member added:org.apache.catalina.tribes.membership.MemberImpl[tcp://{-48, 85, 114, -22}:4000,{-48, 85, 114, -22},4000, alive=66125434,id={-6 13 31 84 -113 28 73 39 -74 -91 122 -127 80 3 -54 -93 }, payload={}, command={}, domain={}, ] Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:4 Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:8 Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.io.BufferPool getBufferPool INFO: Created a buffer pool with max size:104857600 bytes of type:org.apache.catalina.tribes.io.BufferPool15Impl Feb 11, 2009 10:25:08 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:8 Feb 11, 2009 10:25:19 AM org.apache.catalina.ha.session.JvmRouteBinderValve start INFO: JvmRouteBinderValve started Feb 11, 2009 10:25:19 AM org.apache.coyote.http11.Http11Protocol start INFO: Starting Coyote HTTP/1.1 on http-8080 Feb 11, 2009 10:25:19 AM org.apache.jk.common.ChannelSocket init INFO: JK: ajp13 listening on /0.0.0.0:8009 Feb 11, 2009 10:25:20 AM org.apache.jk.server.JkMain start INFO: Jk running ID=0 time=0/36 config=null Feb 11, 2009 10:25:20 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 13590 ms - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Trouble with cluster and JMX
sure turn on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties however, regular membership discovery over multicast show up even without these entries did you mark your webapp distributable/ Filip Eric B. wrote: Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:499242de.2090...@hanik.com... log looks good, the warning could be that you are using an old configuration option take a look at http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html also, what could mean that it doesn't work, would be that multicast is not working for you, and you need to enable multicast. I've ensured that multicast is enabled. I've added the multicast route to the routing tables. I've even checked my multicast route between 2 machines by pinging 224.0.0.1 and getting replies from both machines. However, I still don't see any of the cluster beans in jConsole. Any ideas? you can also set up static members, http://tomcat.markmail.org/search/?q=cluster%20static%20member#query:cluster%20static%20member%20list%3Aorg.apache.tomcat.users%20date%3A200707-200902%20from%3A%22SANCHEZ%2C%20Michel%22+page:1+mid:slqnel56c2lougo3+state:results Thanks, but I would prefer having auto-detection if possible. Right now, I'm trying to figure out how to log / debug the information to ensure that everything is being sent, however, like I said, I don't even see the beans exposed in jConsole MBeans anywhere. Is there any other way to enable logging of the cluster? Thanks! Eric Using CATALINA_BASE: /opt/tomcat6 Using CATALINA_HOME: /opt/tomcat6 Using CATALINA_TMPDIR: /opt/tomcat6/temp Using JRE_HOME: /usr/java/jre1.6.0_11 Feb 11, 2009 10:25:06 AM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-8080 Feb 11, 2009 10:25:06 AM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 549 ms Feb 11, 2009 10:25:06 AM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Feb 11, 2009 10:25:06 AM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/6.0.18 Feb 11, 2009 10:25:06 AM org.apache.catalina.ha.tcp.SimpleTcpCluster start INFO: Cluster is about to start Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.transport.ReceiverBase bind INFO: Receiver Server Socket bound to:/208.85.114.235:4000 Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.membership.McastServiceImpl setupSocket INFO: Setting cluster mcast soTimeout to 500 Feb 11, 2009 10:25:06 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:4 Feb 11, 2009 10:25:06 AM org.apache.catalina.ha.tcp.SimpleTcpCluster memberAdded INFO: Replication member added:org.apache.catalina.tribes.membership.MemberImpl[tcp://{-48, 85, 114, -22}:4000,{-48, 85, 114, -22},4000, alive=66125434,id={-6 13 31 84 -113 28 73 39 -74 -91 122 -127 80 3 -54 -93 }, payload={}, command={}, domain={}, ] Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:4 Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:8 Feb 11, 2009 10:25:07 AM org.apache.catalina.tribes.io.BufferPool getBufferPool INFO: Created a buffer pool with max size:104857600 bytes of type:org.apache.catalina.tribes.io.BufferPool15Impl Feb 11, 2009 10:25:08 AM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:8 Feb 11, 2009 10:25:19 AM org.apache.catalina.ha.session.JvmRouteBinderValve start INFO: JvmRouteBinderValve started Feb 11, 2009 10:25:19 AM org.apache.coyote.http11.Http11Protocol start INFO: Starting Coyote HTTP/1.1 on http-8080 Feb 11, 2009 10:25:19 AM org.apache.jk.common.ChannelSocket init INFO: JK: ajp13 listening on /0.0.0.0:8009 Feb 11, 2009 10:25:20 AM org.apache.jk.server.JkMain start INFO: Jk running ID=0 time=0/36 config=null Feb 11, 2009 10:25:20 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 13590 ms - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Trouble with cluster and JMX
Filip Hanik - Dev Lists devli...@hanik.com wrote in message news:49937f4b.9050...@hanik.com... sure turn on org.apache.catalina.ha.level = FINE org.apache.catalina.tribes.level = FINE in logging.properties however, regular membership discovery over multicast show up even without these entries did you mark your webapp distributable/ Crap. Now that you mention it, I think I forgot to do that. Will have to check up on that tomorrow. However, after a bunch of fiddling around, putting the Manager within the context element got session replication working, even if it isn't marked as distributable /. Would that be expected behaviour by putting the Manager in the context? Will check tomorrow and post findings. Thanks, Eric - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Trouble with cluster and JMX
log looks good, the warning could be that you are using an old configuration option take a look at http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html also, what could mean that it doesn't work, would be that multicast is not working for you, and you need to enable multicast. you can also set up static members, http://tomcat.markmail.org/search/?q=cluster%20static%20member#query:cluster%20static%20member%20list%3Aorg.apache.tomcat.users%20date%3A200707-200902%20from%3A%22SANCHEZ%2C%20Michel%22+page:1+mid:slqnel56c2lougo3+state:results Filip Eric B. wrote: Hi, I'm brand new to clustering and read through the docs at http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html to get a better understanding of how it works. I tried the settings I would have expected to work, and on startup, I can see both tomcat's communicate and join the cluster (via standard logging). However, it seems as though my sessions are not replicating properly. Given that I probably messed something up along the line, I wanted to try and see if I could enable better logging. At the bottom of the how-to page, it indicates that monitoring can be done via JMX. So I enabled JMX, and launched jConsole to connect. However, once connected, I don't see any cluster MBeans defined anywhere. Am I missing something obvious somewhere? I've pasted an excerpt of my startup log at the bottom that indicates (I think) that the cluster has launched properly. However, the only MBeans I see are the JvmRouteBinderValve and ReplicationValve listed under the Valve bean. I don't see any beans for Cluster or for the Manager. I have tried both with the cluster configuration under the Host and Engine with no difference. I did get one warning (see below) regarding the SimpleTcpCluster, but didn't expect that to be anything critical as I am using all the default params. I figure there must be another way to enable some more detailed logging elsewhere so that I can see the tomcat instances communicating. Can anyone direct me to the right place how/where to enable that? I can't seem to find that in the docs anywhere. Thanks for any help! Eric Feb 10, 2009 5:32:22 PM org.apache.catalina.ha.tcp.SimpleTcpCluster setProperty WARNING: Dynamic setProperty(className,value) has been disabled, please use explicit properties for the element you are trying to identify INFO: Starting Servlet Engine: Apache Tomcat/6.0.14 Feb 10, 2009 5:14:54 PM org.apache.catalina.ha.tcp.SimpleTcpCluster start INFO: Cluster is about to start Feb 10, 2009 5:14:54 PM org.apache.catalina.tribes.transport.ReceiverBase bind INFO: Receiver Server Socket bound to:/192.168.103.103:4000 Feb 10, 2009 5:14:54 PM org.apache.catalina.tribes.membership.McastServiceImpl setupSocket INFO: Setting cluster mcast soTimeout to 500 Feb 10, 2009 5:14:54 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:4 Feb 10, 2009 5:14:55 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:4 Feb 10, 2009 5:14:55 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Sleeping for 1000 milliseconds to establish cluster membership, start level:8 Feb 10, 2009 5:14:56 PM org.apache.catalina.tribes.membership.McastServiceImpl waitForMembers INFO: Done sleeping, membership established, start level:8 ... ... Feb 10, 2009 5:33:27 PM org.apache.catalina.ha.session.JvmRouteBinderValve start INFO: JvmRouteBinderValve started - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org