I installed jitsi-meet on a new server, I was used to the docker install so a “normal” one was not that hard. The only issue I’m having is with
jitsi-meet-turnserver, It’s working fine but I can’t activate the prometheus exporter. When I set the option
prometheus in /etc/turnserver.conf I get this error :
0: Bad configuration format: prometheus
I tried with packages version :
Any ideas ? I was thinking of trying to install coturn from the official repo to get the lastest version but will it be ok with the rest of the Jitsi stack ?
The prometheus option was introduced in coturn in version 4.5.2, unfortunately the newest version packaged for coturn is <4.5.2 for stable Ubuntu/Debian.
I suspect it would work just fine if we compiled latest coturn from repo and replace the binaries, but that’s a baseless guess on my part. I have plans to test it some day, but will be a while before I get round to it.
p.s. I don’t use the docker setup, so not sure how relevant this might be to you.
edit: If you are running on docker, you may want to wait till this is resolved before upgrading to latest coturn: Running on docker with prometheus open keep eating up memory · Issue #666 · coturn/coturn · GitHub
Hey @shawn thanks for the quick and clear answer !
I’ll give a try to install coturn =>4.5.2 to see if I’m able to activate prometheus exporter.
I’ll answer here with the results
Regarding your edit, I switched to normal .deb install after a few weeks with a lot of issues with coturn and docker. I saw that it was on the roadmap to integrate coturn config in the docker install so I’ll wait a little bit before going back there
Managed to carve out some time to give this a go – compiled coturn-4.5.2 from source and replaced the binaries.
/etc/turnserver.conf needed a small tweak (see step 6 below), but other than that all seems to work the same.
Have not done any thorough testing, but things looks promising. Video calls using TURN server works, and I can now use
http://127.0.0.1:9641 for healthchecks and
http://127.0.0.1:9641/metrics to derive coturn stats.
For anyone who wants to give this a go and perhaps test this more thoroughly, these are the steps gleaned from my notes when installing on Ubuntu 18.04:
Install prometheus-client-c - needed for prometheus support in coturn
apt-get install -y libmicrohttpd-dev # needed by libpromhttp-dev
dpkg -i libprom-dev-0.1.3-Linux.deb
dpkg -i libpromhttp-dev-0.1.3-Linux.deb
Install other deps needed by coturn
apt-get install -y pkg-config libssl-dev sqlite3 libsqlite3-dev libevent-dev
- Note: I’m compiling without redis/postgres/mysql support. If you need support for these, also install libpq-dev (for postgres), libhiredis-dev (for redis), mysql-client and libmysqlclient-dev (mysql)
Download and extract coturn source
tar zxvf 4.5.2.tar.gz
/etc/init.d/coturn to change bin path to
/usr/local/bin so the new coturn binary is used. I changed the following two lines:
Reload service definition and restart
systemctl restart coturn
The steps above assumes that coturn apt package is already installed and TURN service already configured and working as expected.
Wow ! Thanks a lot @shawn this is amazing !
I’ll give it a try probably next week and make some thorough testing, I’ll write my feedback here.