· Alexander · Grafana  · 2 min read

Transmission Metrics in Grafana

Export Transmission stats to Prometheus and graph them in Grafana.

Export Transmission stats to Prometheus and graph them in Grafana.

If you use Transmission as your download client, you can use a metrics exporter for Prometheus to ingest info into Grafana to display. You’ll also want to make sure Prometheus is set up and running or else this won’t work!

SSH to your docker host that is running Prometheus and edit the prometheus.yml configuration file by adding the following:

Terminal window
scrape_configs:
- job_name: 'transmission'
scrape_interval: 10s
static_configs:
- targets: ['<ip.of.transmission.exporter>:19091']

Save and close prometheus.yml. Now create the Transmission-Exporter.

Terminal window
docker run -d -p 19091:19091 -e TRANSMISSION_ADDR=http://<ip.of.transmission.client>:<port> metalmatze/transmission-exporter

You’ll need to change ipoftransmission:<port> to the ip

of your Transmission install. If you have authentication enabled you’ll need to specify -e TRANSMISSION_USERNAME=username and -e TRANSMISSION_PASSWORD=password to the above command before metalmatze/transmission-exporter. Restart your Prometheus container so it picks up the new config. You should be able to navigate to the Prometheus web ui now and run the following query:

Terminal window
transmission_session_stats_downloaded_bytes{type="cumulative"}

You should see something similar to:

Now open Grafana and under Data Sources add a new Prometheus source:

SettingValue
NamePrometheus
URLhttp://ip-of-prometheus:9090
HTTP MethodGET

Click Save & Test. If you get an error, make sure Grafana can reach Prometheus.

Adding Transmission Stats to your Dashboard

Navigate to a Dashboard you wish to add Transmission stats to and add a new singlestat panel. Under Metrics, add the following query:

Terminal window
transmission_session_stats_downloaded_bytes{type="cumulative"}

And then under the Options tab select “Average” for Stat and “data(metric)/bytes” under Unit.


Edit 4/29/19: Updated to match new Grafana guide settings.

Back to Blog

Comments


Related Posts

View All Posts »