kamailio_exporter
kamailio_exporter copied to clipboard
Feature: add amount of warnings/errors/criticals for kamailio logs
Hi and thanks for this great exporter.
It would be very nice if we could have the amount of errors/warnings/criticals that kamailio had output to syslog. I will try to investigate how this can be implemented and make a PR if possible. If you have any ideas just say so :)
Thank you.
Hi and thanks!
I guess it all depends on which "errors/warnings/criticals" we are talking about. The exporter can only read from what Kamailio exposes on RPC. On my servers, I do not see those kind of errors exposed, but I suppose this could be done using the statistics module, by incrementing some variable every time you "catch" an error in the script.
However I do not think all errors could be catched this way. Let me know what you find :)
My first thoughts were to just parse the log file that kamailio uses (ie syslog) and count the amount of ERRORs/WARNINGs etc that it gets outputted there. But I'm not sure if there is a better more native kamailio way with a module. I'll check the statistics module, maybe it has something like that.