The Enhanced OPeNDAP HDF4 Handler Installation Guide

This installation guide is for Hyrax (version 1.5.2).

  1. First make sure that GNU auto tools are up to date.
  2. Install HDF4 source (version 4.2r4).
    1. tar zxvf HDF4.2r4.tar.gz
    2. cd HDF4.2r4
    3. ./configure --prefix=/usr/local/hdf4
    4. make install
  3. (Optional) Install HDF-EOS2 library source (version 2.16).
    1. uncompress HDF-EOS2.16v1.00.tar.Z
    2. tar xvf HDF-EOS2.16v1.00.tar
    3. cd hdfeos
    4. setenv CC /usr/local/hdf4/bin/h4cc
    5. ./configure --prefix=/usr/local/hdfeos2 --with-hdf4=/usr/local/hdf4 --enable-install-include
    6. make install
  4. Install libdap source (version 3.9.3).
    1. tar zxvf lbdap-3.9.3.tar.gz
    2. cd libdap-3.9.3
    3. ./configure --prefix=/usr/local/opendap
    4. make install
  5. Install BES source (version 3.7.2).
    1. set path = (/usr/local/opendap/bin /usr/local/hdf5/bin $path) # We assume that (t)csh as a current shell.
    2. setenv LD_LIBRARY_PATH /usr/local/opendap/lib::$LD_LIBRARY_PATH # We assume that (t)csh as a current shell.
    3. setenv PKG_CONFIG_PATH /usr/local/opendap/lib/pkgconfig:/usr/lib/pkgconfig # We assume that the system wide package configuration files (*.pc) are under /usr/lib/pkgconfig
    4. tar zxvf bes-3.7.2.tar.gz
    5. cd bes-3.7.2
    6. ./configure --prefix=/usr/local/opendap
    7. make install
  6. Install general purpose handler source (version 3.9.3).
    1. tar zxvf dap-server-3.9.3.tar.gz
    2. cd dap-server-3.9.3
    3. setenv PKG_CONFIG_PATH /usr/local/opendap/lib/pkgconfig:/usr/lib/pkgconfig # We assume that the system wide package configuration files (*.pc) are under /usr/lib/pkgconfig
    4. ./configure --prefix=/usr/local/opendap
    5. make install
  7. Install the latest hdf4_handler source.
    1. svn co http://scm.opendap.org:8090/svn/trunk/hdf4_handler
    2. cd hdf4_handler
    3. setenv PKG_CONFIG_PATH /usr/local/opendap/lib/pkgconfig:/usr/lib/pkgconfig # We assume that the system wide package configuration files (*.pc) are under /usr/lib/pkgconfig
    4. autoreconf --v
    5. ./configure --prefix=/usr/local/opendap --with-hdf4=/usr/local/hdf4 --enable-cf
    6. (Optional) ./configure --prefix=/usr/local/opendap --with-hdf4=/usr/local/hdf4 --enable-cf --with-hdf-eos2=/usr/local/hdfeos2 # Use this if HDF-EOS2 Library is installed.
    7. (Optional) make check # See 'Testing HD4 Handler with Testsuite' below.
    8. make install

Testing HDF4 Handler with Testsuite

There are two testsuite in the hdf4 handler distribution - BES testsuite and local testsuite. The make check command will execute the BES testsuite first and then local testsuite. These tests do not require any server (BES/TomCat) installation.
BES Testsuite
This testsuite runs besstandalone command which is installed under /usr/local/opendap/bin directory by the installation Step 5 above. If you want to test your file one by one, you can run a series of command like below. Here, we assume that the test filename is S2000415.HDF and it is located under data directory in hdf4_handler. You must create your own .bescmd files if you want to try a different HDF4 file. Then, pass them as an argument to the besstandalone command.

Testing with Apache Tomcat server

  1. Run bes-dap-data.sh under /usr/local/opendap/bin. This will update /usr/local/opendap/etc/bes/bes.conf file to include the BES ascii/usage/info module.
  2. Run bes-hdf4-data.sh under /usr/local/opendap/bin. This will update /usr/local/opendap/etc/bes/bes.conf file to include the BES h4 module.
  3. Modify the following parameters in bes.conf file under /usr/local/opendap/etc/bes. BES.ServerAdministrator=username@yoursite.com # Your e-mail address BES.User=username # Output of UNIX "users" command BES.Group=groupname # Output of UNIX "groups" command BES.ServerPort=10002 # (Optional) Change it to other number if you want to run multiple servers. Make sure that following options are enabled. BES.Catalog.catalog.TypeMatch=h5.*\.(he5)(\.gz|\.bz2|\.Z)?$;h5:.*.h5(.bz2|.gz|.Z)?$; BES.modules=dap,cmd,ascii,usage,www,h4 BES.module.dap=/usr/local/opendap/lib/bes/libdap_module.so BES.module.cmd=/usr/local/opendap/lib/bes/libdap_cmd_module.so BES.module.ascii=/usr/local/opendap/lib/bes/libascii_module.so BES.module.usage=/usr/local/opendap/lib/bes/libusage_module.so BES.module.www=/usr/local/opendap/lib/bes/libwww_module.so BES.module.h4=/usr/local/opendap/lib/bes/libhdf4_module.so Please see BES Configuration for other configuration options.

  4. Become a super user and start BES server by typing besctl start.
  5. Install Apache Tomcat server (version 6.0.16).
  6. Download and install OLFS. (version 1.5.2).
    (You may want to compile and install OLFS. Please refer to OLFS Build Instructions for instruction.)
  7. Start Tomcat by running $tomcat_install_root/bin/startup.sh.
  8. Copy some HDF4 files under /usr/local/opendap/share/hyrax/data/.
  9. Try URL http://your_host_address:your_tomcat_port/opendap/data/ on your web browser.

Last Updated: 2009.06.25. 16:56:37