Ready for scraping NGINX metrics? Nginx_vts_exporter + Prometheus + Grafana

Scrape up like a bee, take it like a spider

Anton Shevtsov
11 min readJul 6, 2019

Nginx. One of the best solution for organizing a web-server. But once you come across a situation where the number of servers under your control leaves you with no other chance — you need to somehow track the main indicators on requests to the servers…

There is a rather large variety of approaches to organizing the collection of nginx metrics: embedded functionality in nginx+, own tools from puma, fast surface solutions like nginx_prometheus_exporter deployed by docker, third-party libraries for frameworks.

Let’s take as a basis the mini-server for collectiong metrics, offered on the official Prometheus website nginx_vts_exporter.

Nginx virtual host traffic status exporter …why ?

And really why? After all, we could raise nginx_prometheus_metrics using docker and maybe it would be faster and easier. However, deploying nginx_vts_exporter will open the magic behind the scenes of the deployment of the docker container, as well as install the GO and compile the binary from the nginx_vts_exporter.go source.

Let’s dig it…

Concept

--

--