|
saidone.org -
better than a penis enlargement! |
|
Main menu
Development
Mailing lists Swamp
Links
ush.itaghers.org saidone@ush gameknot |
Alfresco sticky client sessions with simple repository clustering HowTo - posted by saidone on Wed, 17 Sep 2008 15:34:02 GMT
In this example we'll setup a simple Alfresco Enterprise cluster on JBoss 4.0.5.GA, with a single NFS shared content store, L2 cache replication and Lucene indexes synchronization.Environment setup Prerequisites A typical and legacy enterprise configuration, with Java 5 and JBoss 4.0.x up and running. MySQL (used on this example) or another of (hibernate) supported databases. Alfresco Enterprise Edition version 2.2.0 war bundle (actually mainly the .war file and the extension directory with the configuration files). 1. NFS stuff Create nfs share mount point: # mkdir -p /opt/share/alf_data_cluster and a place for local indexes: # mkdir -p /opt/alf_data then map the drive for export, adding the following line to /etc/exports: /opt/share/alf_data_cluster 192.168.1.231(rw) (of course you've got to specify all the IPs of you cluster's nodes) and then reload the configuration file: # /usr/sbin/exportfs -a or start/restart nfs service: # service nfs restart 2. Configuration stuff Copy the extension directory on /path/to/jboss/server/yourserver/conf/alfresco and chdir to it. Modify the custom-repository.properties, to separate the content store from local indexes: dir.root=/opt/share/alf_data_cluster within this file, set up lucene index synchronization by adding: index.tracking.cronExpression=0/5 * * * * ? Configure also the database, with the jdbc connection string and the driver name: db.driver=org.gjt.mm.mysql.Driver And tell hibernate which dialect to use in the file custom-hibernate-dialect.properties: hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect Setup L2 cache replication by # feel free to modify some properties, expecially you may want to change the multicast address and/or the port modifying these: multicastGroupAddress=230.0.0.1, Reduce the log verbosity, otherwise alfresco will try to open an X debugger. The quickest way is to modify the root category on /opt/jboss/server/default/conf/log4j.xml, setting the priority value to "INFO": <root> 3. Mangling and deploying alfresco.war on JBoss Keep in mind that we're not deploying Alfresco on Tomcat. We have to slightly tweak the .war file to make all things working properly. These are the simple steps I've tested: - unzip the .war - remove log4j and jta jars from WEB-INF/lib - put in WEB-INF/lib the jdbc driver for the database you want to connect, if not present on your JBoss installation - inside WEB-INF, create a file named jboss-web.xml containing this: <jboss-web> - replace the jsf-libs in jboss/server/default/deploy/jbossweb-tomcat55.sar/sf-libs with the ones bundled with the .war WEB-INF/lib/commons-lang-2.1.jar - re-zip the war and copy it to deploy directory 4. JVM tuning and startup To startup alfresco and make something useful you should at least increase the permanent generation size to 128MiB, but is recommended to increase also the heap size. Here's an example of recommended settings: JAVA_OPTS= No comments yet. Post a new comment back to home |
[[[[[[[ served by kugelmass ]]]]]]]
Sex without love is an empty experience, but as empty experiences go it's one of the best. - Woody Allen
|
|