In springframework, for logging by log4j subsystem, We Can config it with the file named log4j. properties and put it in the folder web-INF/class /(If using wsad, you should put it in your ource/. It will be deployed to Web-INF/class.).
The content of a log4j. properties file like this:
Log4j. rootcategory = info, stdout, logfile
Log4j. appender. stdout = org. Apache. log4j. leleappender
Log4j. appender. stdout. layout = org. Apache. log4j. patternlayout
Log4j. appender. stdout. layout. conversionpattern = % d % P [% C]-<% m> % N
Log4j. appender. logfile = org. Apache. log4j. rollingfileappender
Log4j. appender. logfile. File =/home/trisberg/jakarta-tomcat-4.1.24/logs/springapp. Log
Log4j. appender. logfile. maxfilesize = 512kb
# Keep three backup files
Log4j. appender. logfile. maxbackupindex = 3
Log4j. appender. logfile. layout = org. Apache. log4j. patternlayout
# Pattern to output: date priority [category]-<message> line_separator
Log4j. appender. logfile. layout. conversionpattern = % d % P [% C]-<% m> % N
The item "log4j. appender. logfile. File" is the path.