Scripts for setting up, deploying to and operating a tomcat cluster. Based on http://www.tomcatexpert.com/blog/2010/07/20/basic-tomcat-clustering-grails-applications and http://burtbeckwith.com/blog/?p=244
Shell
Pull request Compare This branch is even with acreeger:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
tomcatcluster
.gitignore
README.md
cleanup.sh
cluster-config.groovy
clusterTasks.xml
createCluster.sh
createInstance.sh
deploy.sh
run.sh

README.md

Tomcat Cluster Scripts (tested on Mac OS X, Snow Leopard)

Heavily based on the work of Burt Beckwith and Peter Ledbrook, these scripts are designed to simplify deployment of a Grails application to a cluster production environment and to serve as a reference. Please see Burt's blog post and Peter's posting on Tomcat Expert for more background info. These scripts will work for any Java web framework that uses WAR files, not just Grails.

They use Tomcat 6.0.28 and its DeltaManager to handle session replication.

I have added the following to these scripts:

  • When using the deploy script, you can specify a "context" in the environment variable CC. Without the CC variable it defaults to "ROOT".
  • I've lengthened the time that catalina.sh waits for the apps to shutdown to 15 seconds.
  • I've fixed the way that the run.sh script checks to see if a process has stopped. It was broken on Mac OS X (Snow Leopard).