Indexing Tomcat Log File Format By Date


I want to change tomcat log file from this format “catalina.2010-05-17.log” to “2010-05-17.catalina.log”. With “date” as prefix, i can index the log file. But because prefix if remarked then the log file will add “juli.” as prefix, so i left prefix = .
To do that, here the steps,
1. Edit “logging.properties” file on [TOMCAT_HOME]/conf
2. Change some text like this

.
.
.
1catalina.org.apache.juli.FileHandler.prefix = .
1catalina.org.apache.juli.FileHandler.suffix = .catalina
.
.
.
2localhost.org.apache.juli.FileHandler.prefix = .
2localhost.org.apache.juli.FileHandler.suffix = .localhost
.
.
.
3manager.org.apache.juli.FileHandler.prefix = .
3manager.org.apache.juli.FileHandler.suffix = manager
.
.
.
4host-manager.org.apache.juli.FileHandler.prefix = .
4host-manager.org.apache.juli.FileHandler.suffix = .host-manager

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: