Installing¶
OpenGeo Suite is compatible with a number of application servers, among them Jetty, Apache Tomcat, JBoss, and WebSphere. The most popular and most recommended application server is Apache Tomcat.
This section will show how to install OpenGeo Suite for Application Servers. As application server deployments can vary widely, these are just guidelines, and your specific setup may differ from those detailed below.
System requirements¶
OpenGeo Suite requires the use of Java 7 or higher. You may use either a JRE or a JDK from Oracle or the OpenJDK project.
Other system requirements are as follows:
Deploying web applications¶
The following steps should be followed to deploy the web applications:
Increasing available memory¶
We recommend the following memory allocations in Tomcat:
- Maximum heap size: 1 GB
- Maximum PermGen size: 128 MB
The Java options for these settings are: -Xmx1024m -XX:MaxPermSize=128m
.
Add these options to your application server and then restart.
Tomcat-specific deployment¶
The use of the Tomcat Management Console is optional and provides an administrative front end for monitoring Tomcat that can also be used to deploy web applications.
To deploy applications using Tomcat Management Console:
Open the Management Console (often available at
http://localhost:8080/manager/html
).Locate the Deploy heading and click the Browse button.
Select the web application file to deploy.
Click Deploy. The WAR file will be uploaded and unpacked into the
webapps
folder.Repeat this process as needed for every web application to be deployed.
Note
The Tomcat Management Console has a default upper limit on the size of WAR files that can be deployed. This will need to be changed in order to deploy many of the OpenGeo Suite web applications. To change this, open the webapps/manager/WEB-INF/web.xml
file in a text editor, and edit the *multipart-config
parameters as follows:
<multipart-config>
<!-- 260 MB max -->
<max-file-size>262144000</max-file-size>
<max-request-size>262144000</max-request-size>
<file-size-threshold>0</file-size-threshold>
</multipart-config>
You can also perform a manual deployment in Tomcat by copying individual WAR files to the webapps
directory. (You may need to restart Tomcat.) Each WAR file will be unpacked into a corresponding directory, so geoserver.war
will be unpacked to webapps/geoserver
, etc.
Externalizing the GeoServer data directory¶
GeoServer includes a built-in data directory used to manage configuration information. To facilitate updating and prevent data loss, it is highly recommended to move the data directory to a location external to the application.
- Stop the application server.
- Move the
data
directory insidewebapps/geoserver
to an external location. Here are some suggested locations:- Linux:
/var/lib/opengeo/geoserver
- Windows:
C:\ProgramData\Boundless\OpenGeo\geoserver
- OS X:
/Users/opengeo/geoserver_data
- Linux:
- Open
geoserver/WEB-INF/web.xml
in a text editor. - Change the
GEOSERVER_DATA_DIR
parameter to point to the new directory location. - Save the file and restart the application server.
Externalizing the GeoWebCache configuration and cache¶
By default, GeoWebCache stores the cache and cache configuration information in the temporary storage folder of the application server. To prevent data loss, it is highly recommended to move the data directory to a permanent location external to the application server.
Stop the application server.
Move the
geowebcache/geowebcache.xml
file fromgeowebcache
to an external location. Here are some suggested locations:- Linux:
/var/lib/opengeo/geowebcache/geowebcache.xml
- Windows:
C:\ProgramData\Boundless\OpenGeo\geowebcache\geowebcache.xml
- OS X:
/Users/opengeo/geowebcache_data/geowebcache.xml
- Linux:
Open
geowebcache/WEB-INF/geowebcache-core-context.xml
in a text editor and modify the constructor argument with the new path togeowebcache.xml
(just the path, not including the file name:<bean id="gwcXmlConfig" class="org.geowebcache.config.XMLConfiguration"> <constructor-arg ref="gwcAppCtx" /> <constructor-arg value="/var/lib/opengeo/geowebcache" />
Next, move the cache directory. Here are some suggested locations:
- Linux:
/var/cache/geowebcache
- Windows:
C:\ProgramData\Boundless\OpenGeo\geowebcache
- OS X:
/Users/opengeo/geowebcache_data
- Linux:
Open
geowebcache/WEB-INF/web.xml
in a text editor and configure theGEOWEBCACHE_CACHE_DIR
location.<context-param> <param-name>GEOWEBCACHE_CACHE_DIR</param-name> <param-value>/var/cache/geowebcache</param-value> </context-param>
Save all files and restart the application server.