A Go-based network metrics exporter that collects and exposes real-time network performance data — including packet statistics, connection status, throughput, and error rates — through a local HTTP endpoint.
This tool enables easy integration with monitoring systems like Prometheus and Node Exporter, providing deep insights into network health and performance.
- Collects key network metrics such as:
- Packet counts (sent, received, dropped)
- Active connections
- Throughput (upload/download rates)
- Error and retransmission rates
- Built in Go, leveraging system APIs (
netstat,ifstat, and/proc/net/) for low-overhead data collection. - Optimized for minimal CPU and memory usage.
- Exposes collected metrics through a local HTTP server, compatible with:
- Prometheus scrapers
- Node Exporter text format
- Easy integration with existing monitoring setups.
- Designed to complement Node Exporter, allowing seamless collection of network metrics alongside CPU, memory, and disk stats.
- Simple HTTP endpoint for quick visualization of current network statistics.
- Provides a straightforward, developer-friendly way to monitor system network performance.
- Language: Go (Golang)
- APIs Used: netstat, ifstat, procfs
- Output Format: Prometheus / Node Exporter-compatible text
- Interface: HTTP server (localhost)
- Go 1.21 or higher
- Linux or macOS environment with
/procfilesystem
- git clone https://github.com/sarthak21-negi/network-metrics-exporter.git
- cd network-metrics-exporter
- go mod tidy
go run main.gohttp://localhost:9090/metrics