File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

limit property not working properly in logging.properties file in tomcat

 
vikas byn
Ranch Hand
Posts: 80
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
.handlers = 1catalina.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler

1catalina.org.apache.juli.FileHandler.level = FINE
1catalina.org.apache.juli.FileHandler.directory = ${catalina.base}/logs
1catalina.org.apache.juli.FileHandler.prefix = catalina.
1catalina.org.apache.juli.FileHandler.limit = 20000000
1catalina.org.apache.juli.FileHandler.count = 5

java.util.logging.ConsoleHandler.level = FINE
java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter

---------------------------------------------------------------------------

I set these property in logging.properties file to rotate calaline.out file after 20 MB. but its not working .
How can i achieve this.
 
Tim Holloway
Saloon Keeper
Pie
Posts: 17627
39
Android Eclipse IDE Linux
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try it on a smaller size and see if the limit really isn't working or not.

One problem with numbers like "20MB" or "20000000" is that it can actually mean several different values, as disk drive manufacturers have been known to exploit.
 
vikas byn
Ranch Hand
Posts: 80
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tim Holloway wrote:Try it on a smaller size and see if the limit really isn't working or not.

One problem with numbers like "20MB" or "20000000" is that it can actually mean several different values, as disk drive manufacturers have been known to exploit.


I search solution for this problem, most of forums suggest to make a cron entry for that.
but in my case, catalina.out fills logs pretty fast. so i want to rotate catalina.out against its size limit.

thanks your suggestion.
 
vikas byn
Ranch Hand
Posts: 80
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I tried several combination of limit but its not working file. my logs does not rotate.

1catalina.org.apache.juli.FileHandler.limit = 20000000

1catalina.org.apache.juli.FileHandler.limit = 20

1catalina.org.apache.juli.FileHandler.limit = 2

1catalina.org.apache.juli.FileHandler.limit = 200
 
vikas byn
Ranch Hand
Posts: 80
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please update..
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic