Bug 55104 - Allow passing arguments with spaces to Commons Daemon
Allow passing arguments with spaces to Commons Daemon
Status: NEW
Product: Tomcat 7
Classification: Unclassified
Component: Integration
7.0.41
All All
: P2 enhancement with 1 vote (vote)
: ---
Assigned To: Tomcat Developers Mailing List
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2013-06-16 18:13 UTC by marko asplund
Modified: 2013-06-16 19:09 UTC (History)
1 user (show)



Attachments
allow passing arguments with spaces (585 bytes, text/plain)
2013-06-16 18:15 UTC, marko asplund
Details

Note You need to log in before you can comment on or make changes to this bug.
Description marko asplund 2013-06-16 18:13:45 UTC
With the current version of the Commons Daemon wrapper script (daemon.sh) it's not possible to pass arguments with spaces to jsvc.

For example jsvc fails to start with the following command:

JSVC_OPTS="-XX:OnOutOfMemoryError='/bin/ls foo bar'" daemon.sh start

The attached patch makes it possible to pass arguments with spaces to Commons Daemon like this:

daemon.sh start -XX:OnOutOfMemoryError='/bin/ls foo bar'

The patch also allows daemon.sh invoker override hardcoded arguments (i.e. "-wait"). Overriding the current wait default value is often required because Tomcat startup may take a long time due to entropy read operation blocking by default on Linux.
Comment 1 marko asplund 2013-06-16 18:15:09 UTC
Created attachment 30446 [details]
allow passing arguments with spaces