Monitoring and Alerting
Enable Prometheus, Alertmanager, Grafana, and node-exporter.
Components
| Component | Purpose | Deployment |
|---|---|---|
| Prometheus | Collects and stores metrics | Enable manually |
| Alertmanager | Manages and sends alerts | Enable manually |
| Grafana | Displays monitoring dashboards | Enable manually |
| node-exporter | Collects node and server metrics | Enable manually |
Start monitoring
Start the components
OpenIM uses Prometheus, Alertmanager, Grafana, and node-exporter for monitoring and alerting. A regular docker compose up -d does not start them. Enable the monitoring profile with:
docker compose --profile m up -dThis procedure does not apply to Windows. To enable monitoring on Windows, update the network mode and port mappings for the monitoring services indocker-compose.yml, then replace127.0.0.1inprometheus.ymlwith the private-network IP.
Import OpenIM metrics into Grafana
Sign in to Grafana
Sign in to the admin console, select data monitoring in the left navigation, then sign in to Grafana with the default username admin and password admin.
You can also open your_ip:13000 directly, replacing your_ip with the deployment server IP.

Add a Prometheus data source
In the left navigation, open Connections/Add new connection, search for prometheus, and add the data source. Enter http://your_ip:19090 as the Prometheus URL (19090 is the default port), then select Save and Test.


Import the dashboard
Open Dashboards, select Create Dashboard, and then select Import dashboard.

Import the default OpenIM dashboard in either of these ways:
- Copy the contents of Demo.json into
Import via dashboard JSON model. - Select
Upload dashboard JSON fileand uploadopen-im-server/config/grafana-template/Demo.json.
Select Load.

Select the data source you just added, then select Import.

The main OpenIM monitoring metrics are now configured.
Import node-exporter metrics into Grafana
Open Dashboard, then select Import from the New menu.

Enter 1860 in Grafana.com dashboard URL or ID, select Load, and then select Import.

The node-exporter metrics appear in the imported dashboard.
