Working with karaf 2.2.9 on linux ubuntu servers, I have a karaf command which launches a some code. This generates some detailed functionnal log in the karaf.log This command is executed regularly (every 2 hours).
We want to collect the log corresponding to each execution.
We have a script shell which uses the client karaf to do the following :
All this is repeated every two hours.
In order to not limit too much the output, I have modified the "size" parameter in karaf/etc/org.apache.karaf.log.cfg to a higher value.
Sometimes, the output can be very rich (and of course, the richer it is, the more critical it becomes!).
So :
Is there a way to increase something so that I can take a rather comfortable amount of log between a log:clear and a log:display ?
Of course, other solutions could be considered, like remaking entirely the logging method or the program, but it would cost far much more than finding the right parameter for a system which already runs.
The default log service used in Karaf is ops4j pax logging .
You can setup the logging-System with the file karaf/etc/org.ops4j.pax.logging.cfg This is a log4j-like configuration file. Here you can setup your own appenders and loggers, adjust the file size, backup-index, etc...
This way you can extract specific logging-information into different log-files.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.