> For the complete documentation index, see [llms.txt](https://docs.cennso.com/components/npp/latest/llms.txt) (all documentation: [llms.txt](https://docs.cennso.com/llms.txt)). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cennso.com/components/npp/latest/concepts/speedtest-monitor.md).

# Speedtest Monitor

`SpeedtestMonitor` Custom Resource (CR) deploys a probe for continuous [Ookla speedtest](https://www.speedtest.net/) measurements within a cluster. The probe is injected into a selected pod where it periodically runs speedtests and exposes download and upload bandwidth, latency, and jitter as Prometheus metrics on port `9100`.

## Pod selection

The `podSelector` field controls which pod the probe is injected into. Use label selectors to target a specific pod. The `container` field optionally pins the probe to a specific container within that pod — if omitted, a random container is used.

```yaml
spec:
  podSelector:
    labels:
      {LABEL_KEY}: {LABEL_VALUE}
  container: {CONTAINER_NAME}
```

## Test configurations

The `configurations` field defines the list of speedtests to run. Each configuration binds the probe to a source and optionally pins the Ookla server to test against.

```yaml
spec:
  configurations:
    - name: {CONFIGURATION_NAME}
      source: {SOURCE_ADDRESS}
      serverID: {SERVER_ID}
```

### Server selection

The `serverID` field pins the test to a specific Ookla speedtest server. If omitted, the probe selects the nearest (lowest-latency) server on each run. The selected server is exposed in the `server` and `server_name` metric labels.

The `serverURL` field points the test at a custom speedtest server (for example `https://speedtest.example.com:8080`), bypassing the Ookla server list lookup entirely. Set at most one of `serverID` or `serverURL`.

### Source selection

Each configuration binds its probes to a source. Set exactly one of the following fields:

- `source` — a fixed bind address, for example `0.0.0.0` to use any interface.
- `sourceInterface` — the name of a network interface in the target pod's network namespace. The probe resolves the interface's global unicast address on every run, so it follows dynamic addresses such as User Equipment (UE) IP addresses.

```yaml
spec:
  configurations:
    - name: {CONFIGURATION_NAME}
      sourceInterface: {INTERFACE_NAME}
```

## Interval and timeout

The `interval` field controls how often the probe runs speedtests. The `timeout` field sets the maximum duration for each run. Both values apply globally to all configurations; you can also override them per configuration. A speedtest loads the link to measure bandwidth, so choose an interval that tolerates the extra traffic. Durations are specified with a unit suffix, for example `30s`, `5m`, or `1h`.

```yaml
spec:
  interval: {INTERVAL}
  timeout: {TIMEOUT}
```

## Read more

For all available parameters, see [SpeedtestMonitor Custom Resource Definition](https://docs.cennso.com/components/npp/latest/technical-reference/npp.cennso.com_speedtestmonitors.md).

To deploy a monitor and view results, see [Deploy a monitor](https://docs.cennso.com/components/npp/latest/guides/deploy-monitors.md).
