Log roation using wrapper

2011-06-03
2012-12-11
  • kishore kumar

    kishore kumar - 2011-06-03

    Hi ,

    I want to rotate logs  every hour .can i do this using wrapper logging functionality . currently we use  cronolog  which rotate logs every 1 hour and it creates the dirs  like 201105/03/logname_1.log  . if the dir is not there. is there a way that i can do the same thing using  wrapper logging functionality .

    Thanks in advance

    -kishore

     
  • Leif Mortenson

    Leif Mortenson - 2011-06-05

    It is not currently possible to roll based on time. Only by date, once per day.   This is something that we will look into adding for a future version.

    In the mean time, would using log4j to log the majority of your application output.  You can configure it to only log summary data to the console.  Only the log output sent to the console will be added to the Wrapper's log file.   It is nice to have everything in the same log file, but would this be an option in your case?

    Cheers,
    Leif

     
  • kishore kumar

    kishore kumar - 2011-06-05

    Thank you Leif  for your response.

    I am starting my Jboss instance using wrapper,so all the Jboss instance specific logs can go to wrapper and the app logging  can go to seperate logging. (may be i can use log4j for this) .?

     
  • Leif Mortenson

    Leif Mortenson - 2011-06-05

    If you are already sending your application logs to other files, I would not expect very much output from only JBoss and the Wrapper.  Is there a reason why you want to roll the logs every hour?  If you roll too often, it can actually make it harder to find useful information, like when exactly a JVM was restarted for example.

    Cheers,
    Leif

     
  • kishore kumar

    kishore kumar - 2011-06-05

    Hmm……that is true. There wont be much from Jboss. right now we maintain separate stdout logs where application  logging will also gets logged. If there is a problem in a particular hour, its easy  to look at the logs for that particular Hour logs rather than looking at a big  log file which contains all info belongs to whole day. It is much more convenient  to troubleshoot for errors when we rotate logs on Hourly basis.

    -Thanks
      kishore

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks