Accepts PromQL / MetricsQL queries (Prometheus-compatible /api/v1/query, /query_range, /series, /labels, plus the vmui UI).
On each query it fans out to all vmstorage nodes, asks each for the relevant raw data, then merges, deduplicates, and evaluates the MetricsQL expression on the combined result.
Stateless and horizontally scalable. Has an in-memory + optional on-disk query cache (rollup result cache) keyed by query+time range.
Because it must contact every vmstorage to get a complete answer, a slow or missing vmstorage affects queries (tunable with -search.denyPartialResponse / partial-response behavior — you can choose to return partial results instead of erroring).
Cluster Native
With the CLUSTER_NATIVE_LISTEN_ADDR=8401 you make the vmselect to be able to be queried by other vmselects just like if it were a vmstorage
Then on the top-level vmselect you need to enable VM_SELECT_MULTI_LEVEL=true and VM_SELECT_SECOND_LEVEL_ADDRESS_=host1:8401,host2:8401 to set what other vmselects it can reach out to