In the past I already tried to get Ephesoft (The open source, web based mailroom automation tool) and Alfresco (the open source content management solution) running in a single Tomcat instance. On Ubuntu, and starting with the Alfresco instance, copying Ephesoft into there. For all kind of distracting reasons (among others writing 4 blogs simultaniously) this failed. This blog will describe a successful attempt to install both into a single Tomcat on Windows.
Why? Because it seems convenient for a demo, not to have to start a VMWare image next to two applications.
First, install Ephesoft. I did an Enterprise install (184.108.40.206) against a previously installed MySQL (running as a service on my laptop). We are going to use the Tomcat as installed and configured by Ephesoft. I am going to get me a configuration as described below.
First I installed Ephesoft and made sure it starts and can create a pdf form tif. The Enterprise version of Ephesoft installs OpenLDAP for you as well. I use JXplorer to browse the LDAP and view/add/modify/remove entries in my LDAP. (Connect anonymous to localhost port 389)
I downloaded an Alfresco Enterprise (3.4.0), with only the war’s (and related tomcat folders like shared and config).
- copy the contents of /web-server/bin folder from the alfresco zip into the JavaAppServer/bin (Include the dll’s of the distribution you run, 32 or 64bit.)
- copy the contents of /web-server/lib folder from the alfresco zip into the JavaAppServer/lib
- copy the contents of /web-server/shared folder from the alfresco zip into the JavaAppServer/shared
- merge the contents of the files in /web-server/conf from the alfresco zip with the same files in JavaAppServer/conf. Take a good look at catalina.properties, the section starting at shared.loader. (I prefer WinMerge to look for the differences and merge them together.)
- Copy alfresco.war into JavaAppServer/webapps
Add the line
Beef up the memory, otherwise it will not run together. Add to the line containing JAVA_OPTS these Alfresco memory settings -Xms128m -Xmx1572m -Xss96k -XX:MaxPermSize=160m -server -Dalfresco.home=%ALF_HOME%
1.5G of memory seems sufficent for my demo purpose.
However, if you try to start Tomcat, I ran into memory poblems. The expansion of the war file together with running Ephesoft appears to be too much. I solved it by temporary disabling Ephesoft. I did this by editing JavaAppServer/bin/startup.bat. I mutulated the DCMA_HOME variable, by adding some characters to the folder name Application. this way it will not be loaded.
Restart tomcat, and see Alfresco nicely expanding. After Alfresco created all tables, and I validated I could actually log into the system, I shutdown Tomcat again.
Restore the original DCMA_HOME variable (ending on /Application),
Rename alfresco.war into something else (I prefer alfresco.warp to prevent it from expanding again)
Start up Tomcat, and notice that Ephesoft as well as Alfresco is available. It is not really a production ready environment, but surely good enough for some Ephesoft-Alfresco demo’s! Play with the CMIS integration you can configure using one of my previous posts
You can use OpenLDAP, since it is there. Configure it in your alfresco-global.properties, add these lines (thanks for the final tip Rick):
# The default principal to use (only used for LDAP sync)
# The password for the default principal (only used for LDAP sync)
# The group search base restricts the LDAP group query to a sub section of tree on the LDAP server.
# The user search base restricts the LDAP user query to a sub section of tree on the LDAP server.
(If you feel lucky you can even put Apache in front, it is provided for your convenience in the Ephesoft Enterprise install, and allows you for easy load balancing if you happen to run multiple Tomcat’s somewhere.)
[update 2011-02-24: Mentioned ‘thanks’ to Rick de Rooij]