The windows service wrapper allows you to run GeoServer as a windows service.
You can download the file here.
The wrapper service that is used is the Java Service Wrapper.
Installation instructions
- Download the file.
- Extract it to your GeoServer installation directory
- You should now have three files under (GeoServer)/: wrapper.exe, wrapper_readme.txt, wrapper_license.txt, and some extra files under bin/
- Open up the command line and navigate to your root GeoServer directory.
- Type: wrapper.exe -c ./bin/wrapper/wrapper.conf to run the wrapper with GeoServer
- Or type: wrapper.exe -i ./bin/wrapper/wrapper.conf to run GeoServer as a service with the wrapper.
The configuration file under (geoserver_home)/bin/wrapper/ called wrapper.conf is your configuration file for the wrapper service.
You can find out more information in the readme that comes with the files or visit the home page for the Java Service Wrapper.
Dan - Thanks very much for your hints; these helped me a great deal.
Here's what worked for me on Windows (XP and Server 2003):
- Set the JAVA_HOME system environment variable, as Dan stated.
- Modified the GEOSERVER_DATA_DIR variable value to be enclosed in double quotes, like: "L:\Program Files\GeoServer 1.6.3\data_dir". This must also be defined under System variables in order to make the service work.
- Modified wrapper.conf (mine is at L:\Program Files\GeoServer 1.6.3\bin\wrapper\wrapper.conf) to correct the wrapper.java.library.path.1 setting from lib to bin/wrapper/lib.
-Matt
Two things that I noticed I had to do to get this to work under Windows:
1. Set the path to the data dir to the 8.3 path name in windows D:\PROGRA~1\GEOSER~1.0-R\data_dir
2. Make sure that JAVA_HOME is set as a system variable, not a user variable.
Dan