Enabling GDAL image formats support¶
Note
This document only concerns the extra image formats that can be made available in GeoServer via GDAL. The GDAL binaries, such as gdalinfo are installed separately.
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.
Note
GDAL image formats support is only available with OpenGeo Suite Enterprise. For more information on OpenGeo Suite Enterprise, please contact us.
Note
See the Installation section for more information on the various ways to install OpenGeo Suite.
Installation¶
Ubuntu packages¶
Note
GDAL image formats are only available on Linux using Boundless packages. Installing with OpenGeo Suite for Application Servers (via a WAR bundle) is not supported.
Install the following package from the Boundless repository. (See Installing for instructions on how to add the OpenGeo repository):
apt-get install geoserver-gdal
Note
You must run this command as root or use sudo.
Once the package is installed, restart Tomcat to allow the changes to take effect:
service tomcat7 restart
Continue reading at the Verification section.
CentOS / Red Hat¶
Note
GDAL image formats are only available on Linux using Boundless packages. Installing with OpenGeo Suite for Application Servers (via a WAR bundle) is not supported.
Install the following package from the Boundless repository. (See Installing for instructions on how to add the Boundless repository):
yum install geoserver-gdal
Note
You must run this command as root or use sudo.
Once the package is installed, restart Tomcat to allow the changes to take effect:
service tomcat7 restart
Continue reading at the Verification section.
Windows installer¶
The GDAL image formats can be added during the installation process. On the Components page, check the box for GDAL Image Formats in the section named GeoServer Extensions.
If OpenGeo Suite has already been installed and you wish to install GDAL image formats at a later time, simply run the installer once more and uncheck all other items except for GDAL Image Formats. This will add support to the existing OpenGeo Suite installation.
Windows application server¶
Note
This section is for installing GDAL image formats on a Windows-based installation of OpenGeo Suite for Application Servers (WAR bundle).
Warning
OpenGeo Suite for Windows requires .NET Framework 4.5. Installation will fail if not present.
Download and install the Visual C++ Redistributable for Visual Studio 2012 Update 4.
Navigate to http://data.boundlessgeo.com/gdal_support/.
Download the file with a version number that most closely matches the version of OpenGeo Suite.
Note
This file requires a 32-bit Java/Tomcat.
Extract the file
gdal-A.B.C.jar
(where A.B.C is a version number) from the archive. Copy into<TOMCAT_HOME>\webapps\geoserver\WEB-INF\lib\
, where<TOMCAT_HOME>
is the location where Tomcat is installed (such asC:\Program Files\Tomcat\
).If Tomcat is installed as a service:
- Extract the full contents of the archive to
<TOMCAT_HOME>\bin\
. - Restart Tomcat.
- Extract the full contents of the archive to
If Tomcat is not installed as a service:
Extract the full contents of the archive to any folder (such as
C:\Program Files\GDAL\
).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.Restart Tomcat.
Continue reading at the Verification section.
OS X installer¶
The GDAL image formats extension can be added to OpenGeo Suite by copying the contents of the gdal
extension folder (not the folder itself) to the GeoServer library folder. The GeoServer library folder can be found by selecting Open Webapps Directory from the GeoServer menu and then navigating to geoserver/WEB-INF/lib
.
Once copied, GeoServer will need to be restarted to take effect.
OS X application server¶
Note
This section is for installing GDAL image formats on an OS X-based installation of OpenGeo Suite for Application Servers (WAR bundle).
Navigate to: http://data.boundlessgeo.com/gdal_support/
Download the file with a version number that most closely matches the version of OpenGeo Suite. For example, the file
gdal_osx_suite_40.zip
would be appropriate for OpenGeo Suite 4.x.Extract the contents of the archive to a location of your choosing.
Create (or edit) a file called
setenv.sh
located in $TOMCAT_HOME/bin, and add the following line:export DYLD_LIBRARY_PATH=<GDAL_PATH>:$DYLD_LIBRARY_PATH
replacing <GDAL_PATH> with the directory the archive was extracted to in the previous step.
Extract the file
gdal-A.B.C.jar
(where A.B.C is a version number) from the archive. Copy into<TOMCAT_HOME>\webapps\geoserver\WEB-INF\lib\
, where<TOMCAT_HOME>
is the location where Tomcat is installed (such as/opt/tomcat/
).Restart Tomcat.
Continue reading at the Verification section.
Verification¶
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.
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.