How to add startup parameters for GeoServer

GeoServer allows global configuration settings to be provided as Java system properties for use during the startup process. Java system properties can be supplied on the command line using -D and are of one of the following forms:

  • -Dproperty=value
  • -D property=value

This section shows how to set the Java system properties used during startup.

Note

We recommend using Tomcat for deployment. Other application servers may have similar configuration.

Note

You can view existing Java options (system-properties) and environment variables (system-environment) on the GeoServer Detailed Status Page at http://localhost:8080/geoserver/rest/about/status.

Linux packages

To set Java options, create a file in the /etc/tomcat8/suite-opts directory.

For example, to revert to the legacy handling of CRS values in GeoJSON WFS output:

  1. Create the file legacyCRS in /etc/tomcat8/suite-opts
  2. Add the line -DGEOSERVER_GEOJSON_LEGACY_CRS=true
  3. Save the file and restart Tomcat.

Windows Tomcat

To set Java options, use the Windows Tomcat Configuration Manager (see Tomcat install on Windows), Java Tab, Java Options section.

For example, to revert to the legacy handling of CRS values in GeoJSON WFS output:

  1. Open the Windows Tomcat Configuration Manager and go to the Java Tab.

  2. In the Java Options add -DGEOSERVER_GEOJSON_LEGACY_CRS=true, then click Apply.

    ../../_images/win_tomcat_add_java_opt.png
  3. Stop and Start Tomcat (via the General tab).