Skip to content

ejabberd

Auto-Detection
Prometheus Metrics

Bleemeo monitors ejabberd through automatic service detection and through Prometheus metrics via the mod_prometheus community module.

Glouton automatically detects ejabberd instances running on the system.

If auto-detected parameters are incorrect, you can override them manually.

Terminal window
sudo tee /etc/glouton/conf.d/99-ejabberd.conf > /dev/null << 'EOF'
service:
- type: "ejabberd"
address: "127.0.0.1"
port: 5672
EOF

Glouton automatically detects configuration changes.

Prometheus metrics are available through the mod_prometheus community module. This module was previously bundled as mod_prom in ejabberd 21.07–23.x but has since moved to the ejabberd-contrib repository.

Install the module from ejabberd-contrib:

Terminal window
ejabberdctl module_install mod_prometheus

Then enable it in your ejabberd configuration file (/etc/ejabberd/ejabberd.yml):

modules:
mod_prometheus: {}

Restart ejabberd to apply the change:

Terminal window
sudo systemctl restart ejabberd

By default, mod_prometheus exposes metrics on port 9090 at /metrics. Verify the endpoint is working by visiting http://localhost:9090/metrics.

For more details, see the mod_prometheus documentation.

Terminal window
sudo tee /etc/glouton/conf.d/99-ejabberd.conf > /dev/null << 'EOF'
metric:
prometheus:
targets:
- url: "http://localhost:9090/metrics"
name: "ejabberd"
allow_metrics:
- "ejabberd_c2s_auth_total"
- "ejabberd_s2s_connections"
- "ejabberd_much_rooms"
- "ejabberd_registered_users"
- "ejabberd_online_users"
EOF

Glouton automatically detects configuration changes.

Metric Description
ejabberd_c2s_auth_total Total number of client-to-server authentication attempts
ejabberd_s2s_connections Current number of server-to-server connections
ejabberd_much_rooms Number of active multi-user chat rooms
ejabberd_registered_users Total number of registered users
ejabberd_online_users Number of currently connected users