tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier>
Subject Re: - how to set system properties to values containing spaces
Date Wed, 10 Jun 2009 13:47:41 GMT
Sorry, I mistook "CATALINA_OPTS" for "JAVA_OPTS",

Bap wrote:
> Hi André,
> The solution you have suggested just introduces a new variable, but with 
> exactly the same characteristics of the existing CATALINA_OPTS variable 
> (unless I am missing something.)

Say that, originally in, you set CATALINA_OPTS as follows (in 
one single line) :

CATALINA_OPTS='-Dcom.sun.jndi.ldap.connect.pool.protocol="plain ssl"'

Then, in, a line such as the following :


would make CATALINA_OPTS now be :

-Dcom.sun.jndi.ldap.connect.pool.protocol="plain ssl"

then, at the next invocation, say here :


this would be seen as

exec (whatever) (whatever_java_opts) 
-Dcom.sun.jndi.ldap.connect.pool.protocol=plain ssl (whatever_follows)

which is pretty much what you are seeing, right ?

Now, what I am trying to tell you is :

the CATALINA_OPTS variable is used several times in the 
script, in a way that may make it difficult to determine how many times 
it is being so "interpolated" into itself before being finally used.
Each level of such interpolation, will remove one level of quoting.

By defining your own variable, and using it just once in, at 
least you know how many times it is being interpolated (just once), and 
you can quote it correctly.

Now, all this being said, why don't you try this in :

CATALINA_OPTS='-Dcom.sun.jndi.ldap.connect.pool.protocol=\"plain ssl\"'

And all of that being said, whoever decided that the property 
"com.sun.jndi.ldap.connect.pool.protocol" could be set to a value with 
embedded spaces ought to be exiled to a remote arctic island.
Together with whomever invented file paths with embedded spaces.
Together with whomever decided to install Tomcat by default in 
c:\program files\apache software foundation\.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message