Prerequisites for using InterMine
InterMine makes use of a variety of freely available software packages. All of the programs below are required, except for Tomcat if you are not planning to make use of InterMine's web application.
| Software | Minimum Version | Purpose |
| Subversion | 1.5 | check out and update source code |
| Java SDK | 5.0 | build and use InterMine |
| Ant | 1.6.5 | invokes the InterMine build |
| Tomcat | 5.0 | website |
| PostgreSQL | 8.3 | database |
| JUnit | 3.8.1 | run Java tests |
Configuration
After installation, some software requires a little configuration to work correctly with InterMine.
Subversion
- Introduction to Subversion (svn)
- The Subversion book gives detailed installation instructions
- Fedora users can just run this command: "sudo yum install subversion"
- Debian users can just run this command: "sudo apt-get install subversion"
- See SVNCheckout for instructions on how to checkout the InterMine software
Java
- Java installation instructions
- Debian users can just run this command: "sudo apt-get install sun-java6-jdk"
- InterMine can be rather memory-intensive, so you will probably need to set memory options for Java. To do this, set the environment variable ANT_OPTS to pass in to Java:
ANT_OPTS="-server -XX:MaxPermSize=256M -Xmx1700m -XX:+UseParallelGC -Xms1700m -XX:SoftRefLRUPolicyMSPerMB=1 -XX:MaxHeapFreeRatio=99"
- Although you should change the -Xmx and -Xms values if you have very little or very much RAM in your computer.
- Increase the MaxPermSize setting if you get this error:
java.lang.OutOfMemoryError: PermGen space
See also CommonErrors
Ant
- Introduction to Ant
- Ant's manual has detailed instructions on how to install Ant.
- Make sure you don't have any ant-related jars on your classpath already, or else the InterMine build will fail.
Tomcat
NOTE: several people have had problems with Tomcat installations set up by Linux package managers. We recommend installing according to the these instructions, it's very straightforward.
- The quickest way to get a working Tomcat (on Unix/Linux) is to:
- Download the latest stable binary distribution tar.gz from the Apache Tomcat site.
- Unpack it:
> tar -zxvf apache-tomcat-x.y.z.tar.gz
- Use the startup.sh and shutdown.sh scripts in apache-tomcat-x.y.z/bin/ to start and stop Tomcat. You can run it as your own user for development purposes.
- Set up the manager user as below.
- Or see Tomcat's installation instructions
- After installation you will need to set up a tomcat user with the 'manager' role by editing $CATALINA_HOME/conf/tomcat-users.xml:
<tomcat-users> <!-- you can add more users or roles if needed --> <role rolename="manager"/> <user username="manager" password="manager" roles="manager"/> </tomcat-users>
You can check this works by accession the manager interface at, e.g. localhost:8080/manager/html - To avoid java.lang.OutOfMemory errors, specify the JVM heap size in $TOMCAT_HOME/bin/tomcat.sh. You can specify '-Xmx256m -Xms128m' as part of TOMCAT_OPTS.
Postgres
- Introduction to PostgreSQL
- PostgreSQL has packages for most systems that set up everything for you.
- You should use at least version 8.3, as we have recently removed workarounds for some bugs in previous versions. Postgres 8.4 will have significantly better performance for some queries when it is released.
- After installation, you need to update postgresql.conf:
Required:
| listen_addresses | '*' | |
| tcpip_socket | true | (not needed in recent releases) |
Recommended, for optimum performance:
| shared_buffers | Set to around 150MB |
| temp_buffers | Set to around 80MB |
| work_mem | Set to around 500MB but not more than 1/10 of available RAM |
| maintenance_work_mem | Set to around 3000MB but not more than 1/5 of available RAM |
| default_statistics_target | Set to around 250 |
| random_page_cost | Set to around 2.0, rather than 4.0 |
| effective_cache_size | Set to about 2/3 the amount of RAM in the computer |
| geqo_threshold | Set to 14 |
| from_collapse_limit | Set to 14 |
| join_collapse_limit | Set to 14 |
| max_locks_per_transaction | Set to 640 |
You should also add a line to the pg_hba.conf file to allow logging in via password:
host all all 0.0.0.0/0 password
You also need to install the bioseg data type, and the contrib btree_gist plug-in, as described in BiosegInstallation.
For some basic postgres commands see: PostgresBasics
JUnit
- Download the junit-X.X.jar from http://www.junit.org/
- Copy to the ant lib directory, eg. apache-ant-1.6.5/lib/
- Add to the java classpath with this command, replacing X.X with the version number.
export CLASSPATH=/path/to/junit-X.X.jar
See also: MacInstallation, Hardware
