On Sep 24, 2005, at 5:29 PM, kiran wrote:
Hi All
Apache logger has support for logging into files through file
appender. But,
if my log file is existing on a different machine on the "intranet"
and the
log4j's logger is running on a different machine, how should i
specify that
network location in the log4j.properties? Also, Are there any the
issues that
are inherently present with this sort of remote logging.
2. Supposing that we define a new appender for logging onto a n/w
file, how to
conditionally instruct logger to log to that appender when a
special case is
satisfied? what i know is that when logging has to be done, apache
logger does
so dutifully to all the appeneders defined in the log4j.properties
file
thanks in advance!
kiran
You did not provide enough detail to answer the question. If you are
running on the Windows platform, you may use a UNC name to specify
the file, however you need to escape the backslashes even in the XML
configuration, resulting in a line like:
<param name="file" value="\\\\someserver\\somedir\\somefile"/>
If you are running some other network file system, then you should
just use the appropriate file name.