Difference between revisions of "Building Frozen Releases"

From WormBaseWiki
Jump to navigationJump to search
Line 91: Line 91:
  
 
WHERE DO THE BLAST/BLAT DATABASES GO?
 
WHERE DO THE BLAST/BLAT DATABASES GO?
 +
 +
== Perl Libraries ==
 +
 +
Each frozen release will have its OWN set of Perl libraries located at /usr/local/wormbase/VERSION/extlib.  I realize this is a little redundant but this is the best and easiest way to keep them all separate.
 +
 +
To do this, I've created separate CPAN configuration files for each release.  Unfortunately, I see no way to initialize a CPAN session with a unique configuration file on the command line.  This means they need to be manually swapped back and forth.  You also have to pay careful attention to initializing environment variables so CPAN can find the modules you may be building against.  It's a pain, I know.
 +
 +
Here's the general flow.
 +
 +
$ cp ~tharris/cpan_configuration/MyConfig.pm.WS100 ~/.cpan/CPAN/MyConfig.pm
 +
$ export PERL5LIB=/usr/local/wormbase/WS100/extlib/lib:/usr/local/wormbase/WS100/extlib:/usr/local/wormbase/WS100/extlib/lib/perl5
 +
 +
 +
 +
  
 
== Fix configuration files ==
 
== Fix configuration files ==

Revision as of 21:43, 14 June 2009

Hardware

WormBase frozen releases are hosted on the virtualized server:

wb-dev2.oicr.on.ca

  • 500 GB disk space
  • 4 GB RAM
  • Debian "Lenny"

Server Configuration

All WormBase-specific files are maintained in a shared directory.

ls /usr/local/wormbase
    acedb/
    logs/    // Cross-site logs
    WS100    // WS100 website
    WS110    // WS110 website
    WS120    // WS120 website
    ...

Each frozen release is a separate virtual host running under a single Apache instance. To prevent collision of libraries, version specific Perl modules are maintained in:

  /usr/local/wormbase/VERSION/extlib

@INC is prepended with this path for each virtual host during apache launch.

Users, groups, directories

Set up the basic users, groups, and directories as previously described.

Installing system libraries

Prepare the system by installing a slew of libraries.

AceDB

Build AceDB as previously described.

Note that EACH virtual host will need its own xinetd configuration file and unique port on which acedb will bind.

This port MUST correspond in the localdefs.pm file (discussed below).

WS100 ... 2005
WS110 ... 2006
WS120 ... 2007
WS130 ... 2008
WS140 ... 2009
WS150 ... 2010
WS160 ... 2011
WS170 ... 2012
WS180 ... 2013
WS190 ... 2014
WS200 ... 2015

Furthermore, the names of each service (acedb_WSXXX) and its port needs to correspond to the name of the service in /etc/services.

MySQL

Install and configure MySQL as previously described.

Each frozen release will have one or more database of the form species_VERSION or g_species_VERSION. Give access to each of these for the www-data user:

grant select on elegans_WS110.* to www-data@localhost;

Apache2 and mod_perl2

Install and configurate Apache2 and mod_perl2 as described.

Set up name based virtual hosts for each frozen release as follows:

<VirtualHost *:80>
   Include /usr/local/wormbase/VERSION/conf/httpd.conf
   ServerName ws[VERSION].wormbase.org
   UseCanonicalName on
</VirtualHost>

Be certain to remove or comment out the default configuration.

Fetch frozen releases and unpack

$ ssh brie4 
$ cd ~ftp/pub/wormbase
$ screen
$ scp -r data_freezes wb-dev.oicr.on.ca:.
  • Unpack acedb_VERSION.ace.tgz or elegans_VERSION.ace.tgz into /usr/local/wormbase/acedb/
  • Unpack GFF databases into /var/lib/mysql/
  • Prepend the version onto each mysql database: species_VERSION or g_species_VERSION

WHERE DO THE BLAST/BLAT DATABASES GO?

Perl Libraries

Each frozen release will have its OWN set of Perl libraries located at /usr/local/wormbase/VERSION/extlib. I realize this is a little redundant but this is the best and easiest way to keep them all separate.

To do this, I've created separate CPAN configuration files for each release. Unfortunately, I see no way to initialize a CPAN session with a unique configuration file on the command line. This means they need to be manually swapped back and forth. You also have to pay careful attention to initializing environment variables so CPAN can find the modules you may be building against. It's a pain, I know.

Here's the general flow.

$ cp ~tharris/cpan_configuration/MyConfig.pm.WS100 ~/.cpan/CPAN/MyConfig.pm
$ export PERL5LIB=/usr/local/wormbase/WS100/extlib/lib:/usr/local/wormbase/WS100/extlib:/usr/local/wormbase/WS100/extlib/lib/perl5



Fix configuration files

perl.startup

  • Insert the VERSION into all appropriate "use lib" statements.
  • Add "use Apache2::compat" for mod_perl1 backwards compatability.

httpd.conf

  • Change all occurrences of /usr/local/wormbase to /usr/local/wormbase/VERSION
  • Change the ServerName as appropriate
  • Prepend the version to both the error and access logs
  • Remove any unnecessary configuration (DAV, mailarch, etc)
  • In the "Location /db/" stanza, replace the PerlHandler line with:
  PerlResponseHandler   ModPerl::Registry

elegans.pm

  • Update the WS200 variable
  • Change the symbolic name of the acedb database to wormbase_VERSION
  • Append the version to all GFF databases

gbrowse.conf

  • Append the version to all GFF databases