wiki:FMEInstall

Version 5 (modified by joshuadf, 7 years ago) (diff)

--

Weekly Rebuild

There is a automatic weekly rebuild that runs as a cron job. Sometimes this will fail. If you ever need to run it manually, log into deltoid and do:

su - fmeuser
./rebuild-fme.sh

To get the FME running:

The FME takes about 11 minutes to build its tree whenever Tomcat starts, such as after a server reboot or FME rebuild. If the FMA database gets a cycle in it, it will completely fail to build. You can tell by looking in the log file /home/fmeuser/catalina_base/logs/catalina.out. A working rebuild looks something like this:

Tue Oct 11 15:04:50 PDT 2011
projectFile = file:/home/fmeuser/catalina_base/webapps/FME/WEB-INF/classes/fmInterface/FME.pprj
CONFIG: Protege 3.0 Build 141, JVM 1.6.0_26-b03, memory=954M, Linux, encoding=UTF-8, language=en, country=US
WARNING: Look and feel not found: com.jgoodies.plaf.plastic.PlasticLookAndFeel -- SystemUtilities.loadLookAndFeel()
WARNING: Plugins directory not found: "/home/fmeuser/catalina_base/"/plugins -- PluginUtilities.getPluginsDir()
SEVERE: non-existent slot: tabbed_instance_form_layout -- Parser.recordError()
SEVERE: non-existent slot: undo_enabled -- Parser.recordError()
WARNING: unable to load frame -- PropertyMapUtil.getFrame(fm_live_03381)
knowledge base loaded
preparing to read file file:/home/fmeuser/catalina_base/webapps/FME/WEB-INF/classes/fmInterface/FMEconfig.xml
config info:
treeRels = [part, systemic part, regional part, constitutional part, branch, tributary]
relNames = [preferred name, synonym, non-english equivalent, fmaid, homonym for, outdated term, definition, bounded by, bounds, member of, member, part, part of, general part, general part of, attributed 
part, branch of, branch, tributary of, tributary, adjacency, orientation, continuous with, attributed continuous with, contained in, contains, arterial supply of, arterial supply, venous supply of, venous
 supply, venous drainage of, venous drainage, nerve supply of, nerve supply, lymphatic drainage of, lymphatic drainage, attaches to, receives attachment, has dimension, has mass, has boundary, has inheren
t 3-d shape, receives drainage from, drains into, projects to, has projection, projects from, receives projection, afferent to, efferent to, articulates with]
attrMap = {non-english equivalent=[name, language], preferred name=[name], synonym=[name]}
init...Forest Builder init
init...Build All Forests
# of roots for systemic part = 138
# of roots for branch = 312
# of roots for constitutional part = 3322
# of roots for tributary = 31
# of roots for part = 1955
# of roots for regional part = 2456
building a forest
building a forest
building a forest
building a forest
building a forest
building a forest
init...Done
3
FINSHED
FME context initialized
Tue Oct 11 15:14:57 PDT 2011

To install the FME:

On DELTOID:

MySQL

  • create the fms user and password
  • grant access to the FME database for fms
  • import the FMA into the FME database
    yum -y install mysql-server
    chkconfig mysqld on
    # set up root pass and .my.cnf
    mysql -u root mysql -e 'CREATE DATABASE FME;'
    mysql -u root mysql -e "GRANT ALL PRIVILEGES ON FME.* TO fms@localhost;"
    mysql -u root mysql -e "GRANT ALL PRIVILEGES ON FME.* TO fms@'%';"
    mysql FME -u root < /usr/local/data/data13/Protege-backups/fma_p2.dump
    # also install java, etc.
    yum -y install java-1.6.0-sun-devel ant
    

Tomcat

The FME requires a specific configuration of Tomcat4 with a custom catalina.policy and server.xml. The easiest way to achieve this is with a catalina_base directory, which is in SubVersion source:fme/trunk

adduser fmeuser
su - fmeuser
svn co svn+ssh://joshuadf@svn.biostr.washington.edu/src/fme
mv fme fmesrc
cd fmesrc/trunk
cp -r catalina_base /home/fmeuser/
cp rebuild-fme.sh /home/fmeuser/
cp tomcat4.conf /home/fmeuser/
ant war
cp FME.war /home/fmeuser/catalina_base/webapps

# install tomcat4, check http://tomcat.apache.org/download-41.cgi for latest
cd /home/fmeuser/
wget http://apache.mirrors.pair.com/tomcat/tomcat-4/v4.1.31/bin/jakarta-tomcat-4.1.31.tar.gz
tar zxvf jakarta-tomcat-4.1.31.tar.gz
rm -f jakarta-tomcat-4.1.31.tar.gz
ln -s jakarta-tomcat-4.1.31 tomcat4
# OK, ready to build the FME
/home/fmeuser/rebuild-fme.sh

Startup script, cron, and Apache

  • The fme-tomcat4 script uses /home/fmeuser/tomcat4.conf to start the FME on boot
cp /home/fmeuser/fmesrc/fme-tomcat4 /etc/init.d
chkconfig --add fme-tomcat4
chkconfig fme-tomcat4 on

cat >> /etc/cron.d/fme-rebuild <<EOF
MAILTO=admin@sig.biostr.washington.edu
# rebuild the FME
00 00 * * Sun   fmeuser /home/fmeuser/rebuild-fme.sh
EOF

I also added this to /etc/httpd/conf.d/sig-local.conf so apache will redirect requests:

RedirectMatch ^/(FME/?)?(.*)$ http://fme.biostr.washington.edu:8080/FME/$2