[SR-Users] XHTTP_Prom syntax error with usrloc in Kamailio 5.3

Tim Unkrig tim at unkrig.dev
Wed Sep 30 15:35:04 CEST 2020


Hello hello,

I would like to monitor our production kamailio cluster (5.3) with prometheus and I was in the beginning so happy to spot the xhhtp_prom module.
But when we enabled it, the output was in view of prometheus malformed in combination with the usrloc module, we got the following output:

kamailio_usrloc_location-contacts 0 1597934423943
kamailio_usrloc_location-expires 0 1597934423943
kamailio_usrloc_location-users 0 1597934423943

Prometheus only accepts “_”   instead of “-“. So unfortunately I get "strconv.ParseFloat: parsing "-contacts": invalid syntax” on the prometheus primary node, when I activated the scraper.
This has been issued in the master branch of kamailio with a sanatize function for that problem. But I would like to avoid compiling modules by myself, because this can be messy from time to time.
That´s why my question, is there maybe another way of fixing this?

I really appreciate any comments here and thanks for your time,
Tim Unkrig
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20200930/b8331949/attachment.sig>


More information about the sr-users mailing list