Monitor Speedify Aero with Prometheus and Grafana

Speedify Aero can answer Prometheus scrapes with each connection's speed, latency, and losses, so you can chart them in Grafana and get alerts. Use this if you already run Prometheus, or want to watch several routers over time.

Beta - Speedify Aero is a beta test of the next generation of Speedify technology. The beta test is open to anyone with a Speedify for Routers license.

You need: a Prometheus server that can reach the router, and Grafana.


Set Up Prometheus

Step 1: Turn On the Prometheus Endpoint

  1. Open Speedify Aero > Settings > Integrations > Prometheus and tick its box. Speedify Aero is in the LuCI menu, or under VPN in GL.iNet's admin panel on GL.iNet firmware.

    The Prometheus card in Speedify Aero Settings, with Listen on set to 0.0.0.0:9961, a Token field with a Generate button, a sample scrape configuration, and Save

  2. Leave Listen on as 0.0.0.0:9961, which is every interface.
  3. Next to Token, choose Generate and copy the token now. It is shown only once. Save it on the Prometheus server in a file only Prometheus can read, such as /etc/prometheus/speedify-aero.token.
  4. Choose Save. Leaving the page with unsaved changes asks whether to discard them.

Step 2: Let Prometheus Reach the Router

A Prometheus server on your LAN can reach the router as is. From another zone, such as a VPN, add a firewall rule:

uci add firewall rule
uci set firewall.@rule[-1].name='Allow-Aero-Prometheus'
uci set firewall.@rule[-1].src='vpn'
uci set firewall.@rule[-1].proto='tcp'
uci set firewall.@rule[-1].dest_port='9961'
uci set firewall.@rule[-1].target='ACCEPT'
uci commit firewall
service firewall restart

Set src to the zone Prometheus is in. Never open this port to the internet.


Step 3: Add the Router to Prometheus

In prometheus.yml:

scrape_configs:
  - job_name: speedify-aero
    static_configs:
      - targets: ["192.168.1.1:9961"]
        labels:
          device: office-router
    authorization:
      credentials_file: /etc/prometheus/speedify-aero.token

Reload Prometheus. Its Status > Targets page should show the router as UP. For several routers, add one target each to the same job.


Step 4: Alerts

These rules notify you when the tunnel is down or Speedify Aero stops answering:

groups:
  - name: speedify-aero
    rules:
      - alert: AeroTunnelDown
        expr: aero_tunnel_status{status="connected"} == 0
        for: 2m
      - alert: AeroNotAnswering
        expr: aero_bridge_aero_connected == 0
        for: 1m

If It Does Not Work

Prometheus says Because
401 Unauthorized The token is missing or wrong. Generate a new one and copy it again.
404 Not Found The path is not /metrics.
connection refused The endpoint is off, on a different port, or blocked by a firewall.

Did you know - Speedify Aero can send an event to Home Assistant, MQTT, or a webhook the moment a connection drops. See Send Speedify Aero Events to Home Assistant, MQTT, and Webhooks.