File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JBoss/WildFly and the fly likes stop server.log getting clearedoff on restarts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "stop server.log getting clearedoff on restarts" Watch "stop server.log getting clearedoff on restarts" New topic
Author

stop server.log getting clearedoff on restarts

Nainar Mohamed
Greenhorn

Joined: Dec 15, 2007
Posts: 9
Hi,

Can someone please tell with me to stop the JBOSS clearing the server.log file on every restarts.
Basically I want the old loggings in the server.log file also to be present when the server is restarted.
Is there any configuration change in JBOSS, which can retain the old log information in the server.log file, whenever its restarted?

Regards,
Nainar
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 9930
    
159

There's a log4j.xml (or jboss-log4j.xml depending on the version of JBoss you are using) under %JBOSS_HOME%/server/xxx/conf folder where you can set the "Append" attribute of the appender named "FILE" to true. By default the "Append" is set to false



[My Blog] [JavaRanch Journal]
Nainar Mohamed
Greenhorn

Joined: Dec 15, 2007
Posts: 9
Hi Friend,

This works.
Thanks for your fast reply.

Regards,
Nainar
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: stop server.log getting clearedoff on restarts
 
Similar Threads
server.log file
Difference in time between server.log and system time
Configuring Jboss log4j.xml file.
persist previous server.log after server restarts using log4j.xml
logging in one file only