...
- Build the fcrepo war file or download the prebuilt fcrepo war file
- Build the War file as described on this page
- Fetch the WAR file from the download page
- Get Tomcat
Download Tomcat 7.0.50 and unpack it
Code Block #> wget http://mirror.synyx.de/apache/tomcat/tomcat-7/v7.0.50/bin/apache-tomcat-7.0.50.tar.gz #> tar -zxvf apache-tomcat-7.0.50.tar.gz #> mv apache-tomcat-7.0.50 tomcat7
- Put the WAR file into tomcat's webapp directory or create a symbolic link
Copy the fcrepo-webapp-VERSION.war file
Code Block #> cp fcrepo-webapp-VERSION.war tomcat7/webapps/fcrepo.war
- Setup the cluster configuration (Optional)
- This github project contains a sample configuration for a cluster in distributed mode.
- Change the configuration as required. Description is available at the JGroups, Infinispan and Modeshape documentations
- Make sure to point Fedora 4 to the configuration files by updating the file
$TOMCAT_HOME/bin/setenv.sh
(create if necessary) using the propertiesfcrepo.modeshape.configuration,
fcrepo.ispn.jgroups.configuration
andfcrepo.infinispan.cache_configuration
- Set the send/recv buffer sizes if neccessary
Use the following commands to set the buffer size
Code Block #> sysctl net.core.rmem_max=5242880 #> sysctl net.core.wmem_max=5242880
- Start instance
Using the default clustered configuration (Replication mode):
Code Block #> CATALINA_OPTS="-Xmx1024m -XX:MaxPermSize=256m -Dfcrepo.modeshape.configuration=config/clustered/repository.json -Djava.net.preferIPv4Stack=true -Djgroups.udp.mcast_addr=239.42.42.42" bin/catalina.sh run
Using a custom configuration by pointing Fedora 4 to custom configuration files:
Code Block #> CATALINA_OPTS="-Xmx1024m -XX:MaxPermSize=256m -Djava.net.preferIPv4Stack=true -Djgroups.udp.mcast_addr=239.42.42.42 -Dfcrepo.modeshape.configuration=file:///path/to/repository.json -Dfcrepo.ispn.jgroups.configuration=/path/to/jgroups-fedora-udp.xml -Dfcrepo.infinispan.cache_configuration=/path/to/infinispan.xml" bin/catalina.sh run
...