h2o.properties
colors.jsp
This document describes how to install the H2O system from the WAR file release. The WAR file release consists of a WAR file containing the web application and a set of scripts to create the database schema used by the application.
As of this writing, the installation has been tested on a Red Hat 7.3 system, running tomcat-4.1.18, JDK 1.4.1_01, and PostgreSQL 7.2.1. The system will probably work with versions of the listed software later than those above, but all other configurations are currently untested.
For H2O to run correctly, you must modify a tomcat configuration file:
~/jakarta-tomcat-4.1.18/conf/web.xmlwhere ~/jakarta-tomcat-4.1.18 is your tomcat installation directory. You must set the enablePooling to false for the jsp servlet. The bold items below show what must be added to the web.xml file:
<servlet> <servlet-name>jsp</servlet-name> <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class> <init-param> <param-name>logVerbosityLevel</param-name> <param-value>WARNING</param-value> </init-param> <!-- start addition for H2O software --> <init-param> <param-name>enablePooling</param-name> <param-value>false</param-value> </init-param> <!-- finish addition for H2O software --> <load-on-startup>3</load-on-startup> </servlet>
Place the WAR file in the webapps directory of your tomcat installation (e.g. ~/jakarta-tomcat-4.1.18/webapps).
Start the tomcat server, and allow the application to auto-deploy. Some configuration will be necessary after deployment, so when tomcat has finished deploying the application, shut down the server. Before restarting tomcat, be sure that all configuration changes in this section have been made, and that the Database Initialization described below, is complete. When you restart tomcat, the home page for the application should be accessible from:
http://your.webserver.edu:<tomcat port>/h2o/index.jsp
Other content can be linked into the About H2O header, by adding your own files to the ~/webapp/h2o/about directory, then adding a links to each file in ~/webapp/h2o/header-about.jsp.
In order to run the H2O database creation or update scripts, you must create a database user with the following privileges:
Scripts to build the database schema are included with this release. They can be found in the schema directory. To set up the database, first, set PGUSER, and PGPASSWORD in your shell environment to the database user and password. Make sure this user has create database and superuser privilege (see Database Setup). Next, from the distribution root directory, run the create-schema.sh script:
create-schema.sh -d [schema/create directory location] [db name] example: ./create-schema.sh ./schema/create h2o_dbto create the schema. Note that the above command will drop the database included on the commandline (after prompting first), so you should be sure to run it on a database you don't mind losing or on a database that doesn't exist yet.
The upgrade process is very straightforward. You basically just copy the new WAR file over the old one, copy a few working files over, update the database, and then restart. You want to make sure to back everything up in the process to make sure nothing gets lost, though. Specifically:
If you are updating H2O from a previous version, you must run database update scripts against your existing H2O database schema.
It is advised you backup your data with a database dump before trying any upgrade. |
Scripts to update the database schema are included with this release. They can be found in the schema directory. Make sure your shell environment (PGUSER, PGPASSWORD) is set to your existing h2o user. Make sure this user has create database and superuser privilege (see Database Setup). Next, from the distribution root directory, run the run-sql-scripts.sh script:
run-sql-scripts.sh [schema/update/ver directory location] [db name] example: ./run-sql-scripts.sh ./schema/update/1.0 your_h2o_dbto update the schema. You need to run this command once for each version in between the one you are running and the one you are upgrading to, including the one you are upgrading to. For instance, if you are upgrading from 1.0 to 1.2.0, you will need to run the above command for the following versions in the following order: 1.1.1, 1.1.3, 1.2.0 (skipping 1.1.2 because no such schema/update/ directory exists). After these scripts complete, the database should be compatible with the current version of the code.
To make a use a site administrator or take administrator rights away from an existing administrator, use the included set-administrator.sh script. A site administrator has the ability to login to the site as any user via a 'Login As' button on each user profile page.