Closed wolframhaussig closed 2 years ago
Hi,
Your logging pattern includes the pid and tags.
The tags are these: [gc,init] [gc,heap ] [gc,phases ] etc.
garbagecat does handle default tags, where they are prepended by the log level. For example, "[info]" before the "[gc]": [0.014s][info][gc] Using G1
But when you explicitly specify "tag", it looks like it removes the leading "[info]".
I will update the code so "[info]" is optional.
Regarding tags, what is the use case for including these in your logging?
I would think logging that every line is wasted space?
I'm not that familiar with Elasticsearch, but doesn't it have the ability to extract gc logging for a specific process without logging pid on each line?
Thank you for your fast response :-)
We are trying to keep the config changes minimal and this is the default config from Elastic. Elasticsearch does not even read this line, but I feat that that the config is overwritten on version updates so we do not really want to touch this file.
Ok, I will make an update to handle the default Elasticsearch logging pattern.
I added support for the provided logging. You may well run into other issues, if you do, please open a new issue.
I am trying to analyze GC logfiles from Elasticsearch which contains its own JDK:
GC configuration:
9-:-Xlog:gc*,gc+age=trace,safepoint:file=/var/log/elasticsearch/gc.log:utctime,pid,tags:filecount=32,filesize=64m
I tried both
java -jar garbagecat-4.0.0.jar -v -l gc.log
andjava -jar garbagecat-4.0.0.jar -v -l gc.log -p
but the preprocessing does not seem to make a difference. Every GC log line seems to be unrecognised:Can you give me a hint what I am doing wrong?