source: installer/resources/wrapper.config @ 168d688

Last change on this file since 168d688 was 168d688, checked in by dev <dev@…>, 6 years ago

Disable JVM stats being written to file, to prevent long (up to ~400ms) pauses.

  • Property mode set to 100644
File size: 11.3 KB
Line 
1#encoding=UTF-8
2#********************************************************************
3# Wrapper Properties
4#
5# WARNING - for any changes to take effect, you must completely
6# stop the router and the wrapper. Clicking 'Restart' on your
7# router console will NOT reread this file! You must
8# click "Shutdown", wait 11 minutes, then start i2p.
9#
10# WARNING - The wrapper is NOT run (and this file is not used)
11# if you start I2P with the 'no window' icon on Windows, or
12# with the runplain.sh script on Linux. Use the 'restartable'
13# icon on Windows or the i2prouter script on Linux to run the wrapper.
14#
15# NOTE - Directory organization:
16# The standard I2P Installation will set up a "split" directory structure
17# with code in the install directory, data and configuration files in the
18# user's home directory, and temporary files in the system temporary directory.
19# To set up a single-directory "portable" installation suitable for
20# a USB stick, make several changes specified below (search for PORTABLE).
21#
22# NOTE - The izpack installer performs variable subsitiution on this
23# file upon installation. If you did not use izpack, you must
24# find and replace all instances of (dollar)INSTALL_PATH and
25# (dollar)SYSTEM_java_io_tmpdir with appropriate values
26# (perhaps . and /var/tmp, respectively)
27#
28#********************************************************************
29# Java Application
30wrapper.java.command=java
31#  Specify a specific java binary:
32#set.JAVA_HOME=/java/path
33#wrapper.java.command=%JAVA_HOME%/bin/java
34# Gentoo uses the following:
35#wrapper.java.command=/etc/java-config-2/current-system-vm/bin/java
36#
37# Tell the Wrapper to log the full generated Java command line.
38#wrapper.java.command.loglevel=INFO
39##
40## PORTABLE installation:
41# A portable Java installation can be configured thusly:
42#set.JAVA_HOME=C:\path\to\your\portable\java\installation
43#wrapper.java.command=%JAVA_HOME\bin\java.exe
44##
45
46# Java Main class.  This class must implement the WrapperListener interface
47#  or guarantee that the WrapperManager class is initialized.  Helper
48#  classes are provided to do this for you.  See the Integration section
49#  of the documentation for details.
50wrapper.java.mainclass=org.tanukisoftware.wrapper.WrapperSimpleApp
51
52# Java Classpath (include wrapper.jar)  Add class path elements as
53#  needed starting from 1
54#
55# Doing it this way means we can add new apps without asking people
56# to update their wrapper.config.
57# The downside is that we lose control over classpath order,
58# This is fine for new installs (where the uninstall jars
59# copy.jar, delete.jar, and exec.jar containing duplicate FileUtil
60# classes, or all the classes of i2p.jar, are in a different directory).
61# Be sure there are no other duplicate classes.
62#
63wrapper.java.classpath.1=$INSTALL_PATH/lib/*.jar
64#  uncomment this to use the system classpath as well (e.g. to get tools.jar)
65# wrapper.java.classpath.2=%CLASSPATH%
66
67# Java Library Path (location of Wrapper.DLL or libwrapper.so)
68wrapper.java.library.path.1=$INSTALL_PATH
69wrapper.java.library.path.2=$INSTALL_PATH/lib
70
71# Java Bits.  On applicable platforms, tells the JVM to run in 32 or 64-bit mode.
72wrapper.java.additional.auto_bits=TRUE
73
74# Java Additional Parameters
75# Numbers must be consecutive (except for stripquotes)
76wrapper.java.additional.1=-DloggerFilenameOverride=logs/log-router-@.txt
77wrapper.java.additional.2=-Dorg.mortbay.http.Version.paranoid=true
78wrapper.java.additional.3=-Dorg.mortbay.xml.XmlParser.NotValidating=true
79wrapper.java.additional.4=-Di2p.dir.base="$INSTALL_PATH"
80wrapper.java.additional.4.stripquotes=TRUE
81
82# Prevent the JVM from exporting stats (and thereby causing hundreds of
83# ms long pauses during GC)
84wrapper.java.additional.5=-XX:+PerfDisableSharedMem
85
86# On some IPv6 enabled systems, I2P and other network-enabled java applications
87# may fail to start. For examples see
88# http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=560044.
89# Two things that may help if you experience this issue
90# 1) "echo 0 > /proc/sys/net/ipv6/bindv6only" as root; or
91# 2) uncomment the next two lines:
92#wrapper.java.additional.6=-Djava.net.preferIPv4Stack=true
93#wrapper.java.additional.7=-Djava.net.preferIPv6Addresses=false
94
95# Jetty says this is a security risk
96# Uncommenting this won't help as the router forces it to true
97# If you really need this, you have to set it in jetty.xml
98# somehow - not sure exactly but here's a clue:
99# org.mortbay.util.FileResource.setCheckAliases(false)
100# wrapper.java.additional.8=-Dorg.mortbay.util.FileResource.checkAliases=false
101# PORTABLE installation:
102# uncomment the following
103#wrapper.java.additional.8=-Di2p.dir.pid="$INSTALL_PATH"
104#wrapper.java.additional.8.stripquotes=TRUE
105#wrapper.java.additional.9=-Di2p.dir.temp="$INSTALL_PATH"
106#wrapper.java.additional.9.stripquotes=TRUE
107#wrapper.java.additional.10=-Di2p.dir.config="$INSTALL_PATH"
108#wrapper.java.additional.10.stripquotes=TRUE
109#
110# Uncomment this for better performance.
111# If it doesn't work, server mode is not available in your JVM.
112# This may not be required if your machine is already "server-class".
113# See http://java.sun.com/j2se/1.5.0/docs/guide/vm/server-class.html
114#wrapper.java.additional.7=-server
115
116# Initial Java Heap Size (in MB)
117#wrapper.java.initmemory=4
118
119# Maximum Java Heap Size (in MB)
120# The JVM's default is 64MB, and I2P can work fine in that, but to handle
121# lots of I2PSnark activity in the same JVM, increasing the default max heap
122# size should help.  Feel free to reduce this if not using I2PSnark in the jvm
123# High-bandwidth routers may need to increase to 256 or more.
124#
125# WARNING - for any changes to take effect, you must completely
126# stop the router and the wrapper. Clicking 'Restart' on your
127# router console will NOT reread this file! You must
128# click "Shutdown", wait 11 minutes, then start i2p.
129#
130wrapper.java.maxmemory=128
131
132# Application parameters.  Add parameters as needed starting from 1
133wrapper.app.parameter.1=net.i2p.router.Router
134
135#********************************************************************
136# Wrapper Logging Properties
137#********************************************************************
138# Enables Debug output from the Wrapper.
139# wrapper.debug=TRUE
140# Format of output for the console.  (See docs for formats)
141wrapper.console.format=PM
142
143# Log Level for console output.  (See docs for log levels)
144wrapper.console.loglevel=INFO
145
146# Log file to use for wrapper output logging.
147# You may wish to change this.
148# NOTE: On Linux/Mac this is overridden in the i2prouter script; changes here will have no effect.
149# System temp directory:
150wrapper.logfile=$SYSTEM_java_io_tmpdir/wrapper.log
151# PORTABLE installation:
152# Use the following instead. I2P will find the logfile here,
153# no need for a wrapper.java.additional line too.
154#wrapper.logfile=$INSTALL_PATH/wrapper.log
155
156# Format of output for the log file.
157# The format consists of the tokens 'L' for log level, 'P' for prefix, 'D' for thread,
158# 'T' for time, 'Z' for millisecond time, and 'M' for message
159# Unfortunately the log timezone cannot be changed, see
160# http://www.nabble.com/Log-message-timezone-td23651317.html
161wrapper.logfile.format=TM
162
163# Log Level for log file output.  (See docs for log levels)
164wrapper.logfile.loglevel=INFO
165
166# Maximum size that the log file will be allowed to grow to before
167#  the log is rolled. Size is specified in bytes.  The default value
168#  of 0, disables log rolling.  May abbreviate with the 'k' (kb) or
169#  'm' (mb) suffix.  For example: 10m = 10 megabytes.
170wrapper.logfile.maxsize=1m
171
172# Maximum number of rolled log files which will be allowed before old
173#  files are deleted.  The default value of 0 implies no limit.
174wrapper.logfile.maxfiles=2
175
176# Log Level for sys/event log output.  (See docs for log levels)
177wrapper.syslog.loglevel=NONE
178
179# these will shut down or crash the JVM
180wrapper.signal.mode.usr1=IGNORE
181wrapper.signal.mode.usr2=IGNORE
182
183# choose what to do if the JVM kills itself based on the exit code
184wrapper.on_exit.default=SHUTDOWN
185wrapper.on_exit.0=SHUTDOWN
186wrapper.on_exit.1=SHUTDOWN
187# OOM
188wrapper.on_exit.10=RESTART
189# graceful shutdown
190wrapper.on_exit.2=SHUTDOWN
191# hard shutdown
192wrapper.on_exit.3=SHUTDOWN
193# hard restart
194wrapper.on_exit.4=RESTART
195# hard restart
196wrapper.on_exit.5=RESTART
197
198# the router may take a few seconds to save state, etc
199wrapper.jvm_exit.timeout=60
200
201# give the OS 60s to clear all the old sockets / etc before restarting
202# Let's change the default from 60 to 15 seconds and see if anyone moans..
203wrapper.restart.delay=15
204
205wrapper.ping.interval=300
206# The ping timeout must be at least 5 seconds longer than the value of wrapper.ping.interval.
207# Extend this if you are getting 'JVM appears hung' shutdowns.
208wrapper.ping.timeout=320
209
210# use the wrapper's internal timer thread.  otherwise this would
211# force a restart of the router during daylight savings time as well
212# as any time that the OS clock changes
213wrapper.use_system_time=false
214
215# pid file for the JVM
216# If you plan to have multiple wrappers running on the same machine,
217# you should copy this file, change the location or file name,
218# and edit the i2prouter script to change the WRAPPER_CONF setting
219# to point to the new wrapper.config location.
220# Windows users may wish to uncomment.
221# Linux/Mac users, do not set here, see settings in the i2prouter script.
222# Directory must exist or the wrapper will fail to start.
223# System temp directory:
224#wrapper.java.pidfile=$SYSTEM_java_io_tmpdir/routerjvm.pid
225# PORTABLE installation:
226# Use the following instead.
227#wrapper.java.pidfile=$INSTALL_PATH/routerjvm.pid
228# pid file for the service monitoring the JVM
229#
230# From i2prouter:
231#
232#     PIDDIR="."
233#     APP_NAME="i2p"
234#     PIDFILE="$PIDDIR/$APP_NAME.pid"
235#
236# This means i2prouter looks for './i2p.pid'.
237# See comments above for wrapper.java.pidfile
238# Windows users may wish to uncomment.
239# Linux/Mac users, do not set here, see settings in the i2prouter script.
240# Directory must exist or the wrapper will fail to start.
241# System temp directory:
242#wrapper.pidfile=$SYSTEM_java_io_tmpdir/i2p.pid
243# PORTABLE installation:
244# Use the following instead.
245#wrapper.pidfile=$INSTALL_PATH/i2p.pid
246
247#********************************************************************
248# Wrapper General Properties
249#********************************************************************
250# Allow for the use of non-contiguous numbered properties
251wrapper.ignore_sequence_gaps=TRUE
252
253# Title to use when running as a console
254wrapper.console.title=I2P Service
255
256# Set permissions used when creating files
257# See http://wrapper.tanukisoftware.com/doc/english/prop-umask.html
258# for a detailed explanation of these settings.
259wrapper.umask=0022
260wrapper.java.umask=0022
261wrapper.logfile.umask=0077
262
263#********************************************************************
264# Wrapper NT Service Properties
265#********************************************************************
266# WARNING - Do not modify any of these properties when an application
267#  using this configuration file has been installed as a service.
268#  Please uninstall the service before modifying this section.  The
269#  service can then be reinstalled.
270
271# Name of the service
272wrapper.ntservice.name=i2p
273
274# Display name of the service
275wrapper.ntservice.displayname=I2P Service
276
277# Description of the service
278wrapper.ntservice.description=The I2P router service
279
280# Service dependencies.  Add dependencies as needed starting from 1
281wrapper.ntservice.dependency.1=
282
283# Mode in which the service is installed.  AUTO_START or DEMAND_START
284wrapper.ntservice.starttype=AUTO_START
285
286# Allow the service to interact with the desktop.
287wrapper.ntservice.interactive=false
288
Note: See TracBrowser for help on using the repository browser.