cancel
Showing results for 
Search instead for 
Did you mean: 

Clustering and session replication

unknown-user
Champ on-the-rise
Champ on-the-rise
Hi there,

I have installed alfresco in cluster and session replication does not work.
I am using alfresco enterprise 3.1.1. (downloaded the tomcat bundle Alfresco-Enterprise-3.1.1-Linux-x86-Install)
And I have 2 linux machines plus a shared disk and shared Mysql DB and a load balancer in another machine.
Application works fine and content is shared and nodes see each other with jgroups but the problem is:

If I log in in the application and stop one of the nodes, the other node takes over but I am asked to log in again.
I should not need to login again as session should be replicated and remembered by the other node.

Any help please?

See below information about all configuration changes I made:

1. Run the installer in 2 different machines, IPs are 158.167.39.210 and 158.167.39.211
2. In repository.properties configure dir.root, dir.contentstore and dir.contentstore.deleted to point to a path in a shared disk (indexes are local for eah node)
3. In repository.properties configure db.properties to point to the same DB
4. In repository.properties set property index.recovery.mode=AUTO
5. In repository.properties set cluster configuration below:

alfresco.cluster.name=foweb
alfresco.jgroups.configLocation=classpath:alfresco/jgroups-foweb-cluster.xml
alfresco.jgroups.defaultProtocol=TCP
alfresco.tcp.initial_hosts=158.67.39.210[7800],158.67.39.211[7800]

6. In tomcat/webapps/alfresco/WEB-INF/classes/alfresco/jgroups-foweb-cluster.xml:

<protocol_stacks>
    <stack name="TCP"
            description="Using TCP as transport">
        <config>
            <TCP
                start_port="7800"
                suspect_on_send_failure="true"
                send_buf_size="100000"
                recv_buf_size="200000"/>
            <TCPPING
                timeout="3000"
                initial_hosts="158.167.39.210[7800],158.167.39.211[7800]"
                port_range="3"
                num_initial_members="2"/>

7. PLace the file ehcache-custom.xml (without any modifications inside) In tomcat/webapps/alfresco/WEB-INF/classes/alfresco/extension
8. In tomcat/webapps/alfresco/WEB-INF/web.xml add the tag <distributable/>


What am I missing or did wrong?
thanks
8 REPLIES 8

mrogers
Star Contributor
Star Contributor
HTTP session replication would be the responsibility of the application server.   What AS are you using?

Also how are you authenticating?

unknown-user
Champ on-the-rise
Champ on-the-rise
I am using tomcat 6.0.20 (the one that comes with the installer Alfresco-Enterprise-3.1.1-Linux-x86-Install)
I did not change anything for the authentication, I use the normal authentication form provided by alfresco.
All changes that I did after standard installation are described in the first post, I did not change anything else.
I just did the same configuration but using Jboss and I did not touch anything in jboss and I do not have any session replication problem.
But I need to use tomcat as is a requirement in the project to use it by director decission.

What should I change?

Thanks

mrogers
Star Contributor
Star Contributor
I've never done this … but the tomcat website has details.

http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html

unknown-user
Champ on-the-rise
Champ on-the-rise
Alfresco provides a mechanism for clustering using jgroups and ehcache and configuring the cluster in repository.properties configuration file.
Tomcat provides another one, the one that is explained in the webpage you told me.
I configured the cluster using alfresco solution.

Are you telling me that alfresco solution is not good enough so I should use an alternative solution like configure the cluster at tomcat level?

unknown-user
Champ on-the-rise
Champ on-the-rise
Thank you very much for nothing "Alfresco Engineer"
As usual, in this forums you get some usefulness answer but never get a solution.
This kind of support is a joke.

mrogers
Star Contributor
Star Contributor
This is a community forum not "support".

And that's the last time I try to help you.

unknown-user
Champ on-the-rise
Champ on-the-rise
And that's the last time I try to help you.

I am about to cry  :lol:

You can not help anybody, you just make people laugh

unknown-user
Champ on-the-rise
Champ on-the-rise
Senior Software Engineer
Alfresco Services Team

:lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol:  :lol: