• Apache Tomcat - http://tomcat.apache.org/
    • Note: Always do a fresh install of Tomcat
    • Note: Windows users should ensure that there are no spaces in the complete tomcat path as this causes errors with JSF tools in Sakai
      GOOD: C:\opt\tomcat\, C:\sakaistuff\installs\tomcat\
      BAD: C:\program files\tomcat\, C:\opt\apache tomcat 7.0.1\
    1. Download tomcat 7 - http://tomcat.apache.org/download-70.cgi
      • Windows users should get the zip file instead of installing a service
        It makes viewing the tomcat logs easier and it is easier to configure

        Icon
        If you're running the tag of Sakai 2.9.1 or earlier you need to be running Tomcat 7.0.21 or earlier. If you go any higher Webdav and Sitestats will have errors and not work. A better solution is to upgrade to the latest version of Sakai and Tomcat.
        SAK-28531 - Sitestats does not load with Tomcat 7.0.35 Closed
        SAK-23156 - IncompatibleClassChangeError from WebDAV LOCK operations giving 500 response code Closed
    2. Extract to /opt (symlink the apache-tomcat-7.0.x directory to tomcat after extracting)
      • Windows users should just rename the directory since they cannot symlink
    3. Extract the files to the same location as tomcat itself
    4. Modify conf/server.xml for international character support
      1. Add URIEncoding="UTF-8" to the Connector element
        • <Connector port="8080" URIEncoding="UTF-8" ...
    5. Set environment variable: CATALINA_HOME=/opt/tomcat
    6. Add $CATALINA_HOME/bin to PATH
    7. Setup the SETENV file in the tomcat/bin directory with JAVA_OPTS (from Install Java 1.7+)

      Populate Database With Demo Data

      Icon

      Instead of starting with an empty database you can add the flag -Dsakai.demo=true in addition to the others shown here. During your first Tomcat launch it will populate your database with test data (students, courses, etc). Once the data has been created remove this flag for subsequent Tomcat launches. Be advised that this flag will not trigger on a database with data already in it so you must make this choice during the initial setup. It should also be noted that without this flag one will not be able to create any course sites in Sakai unless Academic Term, Subject, Course, and Section data is manually added to the "cm_" tables in the database.

       

      1. Mac/Linux: Create a file called setenv.sh with the following (alternately, you can put this into your .bashrc file so they're automatically executed):

      2. Windows(PC): Create a file called setenv.bat with the following:

    8. [OPTIONAL] Delete the default webapps from the webapps dir

      rm -rf webapps/*
      
    9. Configure tomcat 7 to use the old tomcat 5.5 classloader dirs
      1. Edit conf/catalina.properties
        1. Add the following to the line that begins with "common.loader=..."

          ,${catalina.base}/common/classes/,${catalina.base}/common/lib/*.jar
          
        2. Add the following to the line that begins with "shared.loader=..."

          ${catalina.base}/shared/classes/,${catalina.base}/shared/lib/*.jar
          
        3. Add the following to the line that begins with "server.loader=..."

          ${catalina.base}/server/classes/,${catalina.base}/server/lib/*.jar
          
      2. [OPTIONAL] Create the directories

        mkdir -p shared/classes shared/lib common/classes common/lib server/classes server/lib
        
    • No labels

    3 Comments

    1. Is configuring Tomcat7 for the old Tomcat5.5 classloader dir structure still required for Sakai2.9 installs, or is this just to get Sakai2.7 working with Tomcat7?

    2. It's still required at the moment for 2.9. We discussed on some of the lists changing the deployment scripts either dumping it into the same lib, or everything into a different lib (like /sakai/lib, which would still require modification). Neither of these are done and ready for 2.10 though.

      http://collab.sakaiproject.org/pipermail/sakai-dev/2012-July/018141.html

    3. What's the difference between step 2 and step 3, seems just the same.

      And Step 9-iii is not needed. Sakai doesn't use server.loader