Thursday, May 15, 2014

Tomcat-Static-Unicast-Clustering

Tomcat needs to be configured to allow for setup of cluster of two nodes over unicast. Following is section of my ${LIFERAY_HOME}/tomcat-6.0.32/conf/server.xml on server1 (replace node1 with node2 and swap location of IP_ADDRESSES and change unique_id to anything 16 bit long other than{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2}, on server.xml in server2) which allowed for this. IP_ADDRESSES here refer to private ip addresses of server1 and server2 respectively.

================================

<Engine name="Catalina" defaultHost="localhost" jvmRoute="node1">

<Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster" channelSendOptions="6" channelStartOptions="3">

<Manager className="org.apache.catalina.ha.session.DeltaManager" expireSessionsOnShutdown="false" notifyListenersOnReplication="true" />

<Channel className="org.apache.catalina.tribes.group.GroupChannel">

<Receiver className="org.apache.catalina.tribes.transport.nio.NioReceiver"
autoBind="0" selectorTimeout="5000" maxThreads="6"
address="IP_ADDRESS_SERVER1" port="4444" />
<Sender className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
<Transport className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"
timeout="60000"
keepAliveTime="10"
keepAliveCount="0"
/>
</Sender>
<Interceptor className="org.apache.catalina.tribes.group.interceptors.TcpPingInterceptor" staticOnly="true"/>
<Interceptor className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
<Interceptor className="org.apache.catalina.tribes.group.interceptors.StaticMembershipInterceptor">
<Member className="org.apache.catalina.tribes.membership.StaticMember"
host="IP_ADDRESS_SERVER2"
port="4444"
uniqueId="{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2}"/>
</Interceptor>
</Channel>
<Valve className="org.apache.catalina.ha.tcp.ReplicationValve" filter="" />
<Valve className="org.apache.catalina.ha.session.JvmRouteBinderValve" />
<ClusterListener className="org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener"/>
<ClusterListener className="org.apache.catalina.ha.session.ClusterSessionListener"/>
</Cluster>

=================================

28 comments:

  1. hi!,I like your writing very so much! share we keep up a correspondence extra about your post on AOL?
    I require a specialist on this area to solve my problem.
    May be that's you! Having a look ahead to see you.

    ReplyDelete
  2. Hi, i feel that i saw you visited my website thus i got here to go back the favor?.I'm trying to in finding things to enhance my web site!I assume its ok to use some of your ideas!!

    ReplyDelete
  3. Good day! I could have sworn I've been to this website before but
    after going through many of the articles I realized it's new to me.
    Anyways, I'm certainly happy I discovered it and I'll be book-marking it and checking
    back regularly!

    ReplyDelete
  4. I think this is one of the most significant info for me.
    And i am glad reading your article. But want to remark on some general things, The website style is wonderful,
    the articles is really nice : D. Good job, cheers

    ReplyDelete
  5. Heya i am for the primary time here. I came across this board
    and I to find It really useful & it helped me out a
    lot. I am hoping to present something back and help others like
    you aided me.

    ReplyDelete
  6. I just couldn't leave your web site prior to suggesting that I actually enjoyed the usual information a person supply to your visitors?
    Is going to be back frequently to check up on new posts.

    ReplyDelete
  7. Great blog! Do you have any suggestions for aspiring writers?
    I'm hoping to start my own website soon but I'm a little lost
    on everything. Would you suggest starting with a free platform like Wordpress or go for a paid option? There
    are so many choices out there that I'm totally confused ..
    Any tips? Thanks a lot!

    ReplyDelete
  8. Nice response in return of this difficulty with real arguments and telling the whole thing concerning that.

    ReplyDelete
  9. Fantastic goods from you, man. I've have in mind your stuff previous to and you're simply too magnificent.

    I actually like what you've obtained here, certainly like what you are stating and the way wherein you assert it.
    You make it enjoyable and you continue to care for to stay it wise.
    I cant wait to read much more from you. That is actually a great website.

    ReplyDelete
  10. Yes! Finally somеօne writes аbout Cheat Ѕix Guns.

    ReplyDelete
  11. Excellent article. Keep posting such kind
    of information on your site. Im really impressed by it.

    Hi there, You have performed an excellent job. I will definitely digg it
    and in my opinion recommend to my friends. I'm confident
    they will be benefited from this website.

    ReplyDelete
  12. I like the helpful info you provide in your articles.

    I will bookmark your blog and check again here frequently.
    I am quite certain I'll learn plenty of new stuff right
    here! Good luck for the next!

    ReplyDelete
  13. It is actually a nice and useful piece of information. I am happy that you simply shared this
    helpful information with us. Please keep us informed like this.
    Thanks for sharing.

    ReplyDelete
  14. Hey would you mind letting me know which webhost
    you're using? I've loaded your blog in 3 different web browsers and I must say this blog loads a lot faster then most.
    Can you recommend a good hosting provider at a fair price?
    Cheers, I appreciate it!

    ReplyDelete
  15. Wow, amazing weblog structure! How long have you ever
    been running a blog for? you make running a blog glance easy.
    The total glance of your web site is magnificent, let alone the content material!

    ReplyDelete
  16. These are genuinely fantastic ideas in regarding blogging.
    You have touched some good points here. Any way keep up wrinting.

    ReplyDelete
  17. Thanks on your marvelous posting! I actually
    enjoyed reading it, you're a great author.I will make sure to
    bookmark your blog and will eventually come back later in life.
    I want to encourage yourself to continue your great writing, have a nice afternoon!

    ReplyDelete
  18. Nice post made excellent information above..thanks

    ReplyDelete
  19. wonderful post, very informative. I ponder why the opposite experts of this sector don't notice this.
    You must continue your writing. I am sure, you've a great readers' base
    already!

    ReplyDelete
  20. This is my first time pay a quick visit at here and i am genuinely happy
    to read all at alone place.

    ReplyDelete
  21. Howdy! I could have sworn I've visited this site before but after looking
    at a few of the articles I realized it's new
    to me. Anyways, I'm definitely happy I found it and I'll
    be bookmarking it and checking back frequently!

    ReplyDelete
  22. Great post. I used to be checking constantly this weblog and
    I'm inspired! Extremely useful information specifically the ultimate
    part :) I care for such information much. I was looking for this particular information for a long time.
    Thanks and good luck.

    ReplyDelete
  23. A person necessarily assist to make critically posts
    I might state. This is the very first time I frequented
    your website page and thus far? I amazed with
    the research you made to make this actual publish extraordinary.
    Great process!

    ReplyDelete
  24. Hello! Do you use Twitter? I'd like to follow you if that would be okay.
    I'm definitely enjoying your blog and look forward to new posts.

    ReplyDelete
  25. Thanks for finally writing about >Tomcat-Static-Unicast-Clustering
    | Linux Conquering Cloud <Loved it!

    ReplyDelete
  26. Nice post. I was checking constantly this weblog and I'm inspired!
    Extremely useful info specially the last part :) I deal with
    such information much. I used to be seeking this certain info for
    a very long time. Thanks and good luck.

    ReplyDelete
  27. Hello, just wanted to say, I liked this blog post.
    It was practical. Keep on posting!

    ReplyDelete