Enabling GDAL image formats support

The OpenGeo Suite comes with support for publishing data from many formats supported by the Geospatial Data Abstraction Library (GDAL). These formats include DTED, EHdr, AIG, ENVIHdr, and much more.

GDAL image formats are enabled by default when using the Windows installer, Mac OS X installer, or Linux packages. Extra configuration is required only if using OpenGeo Suite for Application Servers (WAR bundle).

To enable GDAL image formats on OpenGeo Suite for Application Servers, read at the correct target operating system below.

Note

See the Installation section for more information on the various ways to install OpenGeo Suite.

Ubuntu

  1. Install the following package from the OpenGeo repository. (See Installation on Ubuntu Linux for instructions on how to add the OpenGeo repository):

    apt-get install gdal

    Note

    You must run this command as root or use sudo.

  2. Once the package is installed, restart Tomcat to allow the changes to take effect:

    service tomcat6 restart

Continue reading at the Verifying installation section.

CentOS / Red Hat

  1. Install the following package from the OpenGeo repository. (See New installation on Red Hat Linux for instructions on how to add the OpenGeo repository):

    yum install gdal

    Note

    You must run this command as root or use sudo.

  2. Copy /usr/lib/gdal.jar (/usr/lib64/gdal.jar on 64-bit installs) to /usr/share/tomcat6/webapps/geoserver/WEB-INF/lib/gdal-1.8.1.jar.

    Note

    You may need to replace tomcat6 with tomcat5 in the above path depending on the server configuration.

  3. Once the package is installed, restart Tomcat to allow the changes to take effect:

    service tomcat6 restart

Continue reading at the Verifying installation section.

Windows

  1. Navigate to: http://data.opengeo.org/gdal_support/ .

  2. Download the file that matches the version of the OpenGeo Suite (e.g. gdal_win_30.zip for version 3.0).

    Note

    This file requires 32-bit Java/Tomcat.

  3. Extract the file gdal-1.8.1.jar from the archive into <TOMCAT_HOME>\webapps\geoserver\WEB-INF\lib\, where <TOMCAT_HOME> is the location where Tomcat is installed (e.g.: C:\Program Files\Tomcat\).

  4. If Tomcat is installed as a service:

    1. Extract the full contents of the archive to <TOMCAT_HOME>bin.
    2. Restart Tomcat.
  5. If Tomcat is not installed as a service:

    1. Extract the full contents of the archive to any folder (such as C:\Program Files\GDAL\).

    2. Edit the file <TOMCAT_HOME>\bin\setenv.bat and add the following line:

      set PATH='C:\Program Files\GDAL\;%PATH%'

      replacing C:\Program Files\GDAL\ with the path where the archive was extracted.

    3. Restart Tomcat.

Continue reading at the Verifying installation section.

Mac OS X

  1. Navigate to: http://data.opengeo.org/gdal_support/

  2. Download the file that matches the version of the OpenGeo Suite (e.g. gdal_osx_30.zip for version 3.0).

  3. Extract the contents of the archive into /usr/local/lib/. The path may not exist, so it may need to be created first.

  4. Create (or edit) a file called setenv.sh located in $TOMCAT_HOME/bin, and add the following line:

    export DYLD_LIBRARY_PATH=/usr/local/lib:$DYLD_LIBRARY_PATH`
  5. Restart Tomcat

Continue reading at the Verifying installation section.

Verifying installation

  1. To verify that the GDAL image formats were enabled properly, navigate to the GeoServer web admin interface and log in with administrator credentials.

    Note

    Please see the GeoServer reference documentation for more information about the GeoServer web admin interface.

  2. Click on Stores and then Add new Store. There should be many raster image formats, such as DTED, EHdr, AIG, and ENVIHdr in the list of formats.

    ../../_images/gdal_verify.png

    Verifying that GDAL is an option in the Raster Data Sources