Skip to main content

VictoriaMetrics queries

v0.1.6

Read-only PromQL / MetricsQL access to VictoriaMetrics over its HTTP API: instant and range queries, series and label discovery, and the VM-specific status endpoints (TSDB cardinality, active queries, top queries). One base URL serves single-node, cluster (vmselect), and vmauth-fronted deployments.

8 allowed by default
Pack ID
victoriametrics
Vendor
emisar
OS
linux
Actions
8
Required binaries. Install these on the host before relying on the pack — an action that calls a missing one fails at run time.
curl

Install

emisar pack install fetches this pack, re-validates it, and verifies its content hash against the --hash below — the exact bytes this page was rendered against, so a tampered copy is rejected — before copying it into the runner's packs dir. The command reloads a running daemon itself; no manual restart.

on the runner host
sudo emisar pack install victoriametrics --hash sha256:f38a3c92177057ac492f45e11da1a057355923db04dde3fbefe697eb0221d3dd

Actions 8 total

View on GitHub
  • vm.active_queries script low

    GET /api/v1/status/active_queries

    List the queries VictoriaMetrics is executing right now — their text, how long they have been running, and the client address. Use to catch a runaway or slow query in the act.

    View source on GitHub
  • vm.label_values script low

    GET /api/v1/label/<name>/values

    List all values for one label. Use to enumerate jobs, instances, or any other dimension before filtering a query.

    View source on GitHub
  • vm.labels script low

    GET /api/v1/labels

    List every label name present in VictoriaMetrics over the default time range. Use to discover the available dimensions. Doubles as the pack's connectivity check.

    View source on GitHub
  • vm.query_instant script low

    GET /api/v1/query

    Run an instant PromQL/MetricsQL query against VictoriaMetrics — evaluates one expression at the current time. Use to answer "what is X right now?".

    View source on GitHub
  • vm.query_range script low

    GET /api/v1/query_range

    Run a range PromQL/MetricsQL query against VictoriaMetrics — evaluates one expression across a trailing window ending now. Use for trends and rates over time. Can be heavy on high-cardinality series.

    View source on GitHub
  • vm.series script low

    GET /api/v1/series

    List the time series matching a selector — the label sets that exist, not their samples. Use to discover what is stored before writing a query.

    View source on GitHub
  • vm.top_queries script low

    GET /api/v1/status/top_queries

    List the most frequent and most expensive queries VictoriaMetrics has seen — topByCount, topByAvgDuration, and topBySumDuration. Use to find what to optimize or rate-limit.

    View source on GitHub
  • vm.tsdb_status script low

    GET /api/v1/status/tsdb

    Show TSDB cardinality stats — the metric names, label pairs, and label values with the highest series counts. The first stop when cardinality or memory is climbing.

    View source on GitHub