You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Thomas Muller <tt...@online.no> on 2002/10/02 17:06:42 UTC

RE: Relative path for FileAppender File

| I have an environment variable called CATALINA_HOME that contains
| D:/Tomcat4.1

You need to set the variable in the System properties. Environment or shell
variables are _not_ automatically or magicly transferred to the java
properties.

Either start the VM with the -D option
(e.g. -DCATALINA_HOME=%CATALINA_HOME%, or set it programmatically with
System.setProperty( "CATALINA_HOME", <path>" );

| I have tried:
| log4j.appender.R.File=${CATALINA_HOME}/webapps/democorp/WEB-INF/lo
| gs/surveyor.log

This is the correct syntax, given that CATALINA_HOME is defined in the
System properties.

Hope this helps.

--

Thomas



*************************************************************************
Copyright ERA Technology Ltd. 2002. (www.era.co.uk). All rights reserved. 
The information supplied in this email should be treated in confidence.
No liability whatsoever is accepted for any loss or damage 
suffered as a result of accessing this message or any attachments.

________________________________________________________________________
This email has been scanned for all viruses by the MessageLabs SkyScan
service. For more information on a proactive anti-virus service working
around the clock, around the globe, visit http://www.messagelabs.com
________________________________________________________________________

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>