Enterprise-grade network performance testing for large-scale infrastructure
hperf is a powerful tool for measuring maximum achievable bandwidth and latency between multiple servers in your infrastructure. Designed for scalability, it can run parallel tests across hundreds of nodes over extended periods, making it ideal for validating network performance in production environments.
Modern infrastructure demands reliable, high-performance networking. hperf helps you:
- Validate network investments - Measure actual throughput and latency between servers
- Diagnose performance issues - Identify bottlenecks in MTU configuration, NIC tuning, or network paths
- Ensure SLA compliance - Verify network performance meets business requirements
- Optimize at scale - Test payload sizes and buffer configurations for your workload
- Continuous monitoring - Run long-duration tests to detect intermittent issues
- Debugging link/NIC MTU misconfigurations
- Optimizing throughput for specific payload and buffer sizes
- Finding servers with application-level latency when ping shows no issues
- Benchmarking overall network throughput in your infrastructure
- Validating server-to-server connectivity and reachability
hperf uses a simple but powerful architecture:
Servers: Deploy the hperf server on each node you want to test. Servers communicate with each other to perform the actual performance measurements.
Client: Run the client from any machine that can reach your servers. The client orchestrates tests and displays results in real-time.
Stateless Operation: Tests run independently on servers. Clients can disconnect and reconnect to running tests at any time, making hperf ideal for long-running tests and monitoring scenarios.
- Start hperf in server mode on all nodes you want to test
- Run a client command specifying the test type and target servers
- The client instructs each server to test connectivity with all other servers (full mesh)
- Servers report real-time statistics back to the client
- Results are aggregated and displayed, with optional persistence for later analysis
Important: The --real-ip
flag should be set on servers when the bind address differs from the external IP used for inter-server communication. This ensures accurate reporting and prevents servers from testing against themselves.
Download pre-built binaries for your platform from GitHub Releases.
go install github.com/minio/hperf/cmd/hperf@latest
On each server you want to test:
# Basic setup - uses current directory for results
./hperf server
# Production setup - specify bind address, external IP, and storage path
./hperf server --address 10.10.2.10:5000 --real-ip 150.150.20.2 --storage-path /var/lib/hperf/
Security Note: The server API is unauthenticated. Do not expose the server port to untrusted networks.
Measure round-trip latency and time-to-first-byte between servers:
./hperf latency --hosts 10.10.10.{2...10} --port 5000 --duration 20 --id latency-test-1
Measure maximum throughput using concurrent streams:
./hperf bandwidth --hosts 10.10.10.{2...10} --port 5000 --duration 20 --concurrency 10 --id bandwidth-test-1
hperf supports flexible host specification:
# Comma-separated list
./hperf latency --hosts 1.1.1.1,2.2.2.2,3.3.3.3
# Ellipsis pattern (MinIO-style)
./hperf latency --hosts 1.1.1.{1...100}
# File input (one host per line)
./hperf latency --hosts file:/home/user/hosts.txt
During test execution, hperf displays aggregated statistics across all servers:
Metric | Description |
---|---|
#ERR |
Total error count across all servers |
#TX |
Total HTTP requests made across all servers |
TX(high/low) |
Highest and lowest transfer rate (single server) |
RMS(high/low) |
Longest and fastest round-trip latency (single server) |
TTFB(high/low) |
Slowest and fastest time-to-first-byte (single server) |
#Dropped |
Highest count of dropped packets (single server) |
Mem(high/low) |
Highest and lowest memory usage (single server) |
CPU(high/low) |
Highest and lowest CPU usage (single server) |
After a test completes, hperf automatically analyzes results and displays percentile breakdowns:
- P99 data points: Shows the worst 1% of measurements - critical for understanding tail latency
- Percentile statistics: P10, P50, P90, P99 breakdowns showing count, sum, min, average, and max values
- Results can be sorted by any metric using
--sort
flag (e.g.,--sort RMSH
for worst round-trip times)
Tests continue running on servers even if the client disconnects. This enables:
./hperf listen --hosts 10.10.10.{2...10} --id latency-test-1
Multiple clients can monitor the same test simultaneously.
./hperf stop --hosts 10.10.10.{2...10} --id latency-test-1
./hperf download --hosts 10.10.10.{2...10} --id latency-test-1 --file latency-test-1.json
# Basic analysis
./hperf analyze --file latency-test-1.json
# Detailed analysis with all data points and errors
./hperf analyze --file latency-test-1.json --print-stats --print-errors
# Filter by specific host
./hperf analyze --file latency-test-1.json --host-filter 10.10.10.5
./hperf csv --file latency-test-1.json
This creates latency-test-1.json.csv
with all data points for analysis in spreadsheet tools.
Useful for detecting intermittent network issues:
./hperf latency --hosts file:./hosts --port 6000 --duration 300 \
--concurrency 1 --request-delay 50 --buffer-size 1000 --payload-size 1000
Push the network to its limits:
./hperf bandwidth --hosts file:./hosts --port 6000 --duration 60 \
--concurrency 16 --payload-size 10000000
Find optimal buffer/payload sizes for your workload:
./hperf bandwidth --hosts file:./hosts --port 6000 --duration 30 \
--concurrency 8 --buffer-size 65536 --payload-size 5000000
Flag | Default | Description |
---|---|---|
--hosts |
(required) | Target servers (comma-separated, ellipsis pattern, or file:) |
--port |
9010 | Server port |
--id |
auto-generated | Test identifier (timestamp if not specified) |
--duration |
30 | Test duration in seconds |
--concurrency |
2×CPUs | Concurrent requests per server |
--payload-size |
1000000 | Payload size in bytes |
--buffer-size |
32000 | Network buffer size in bytes |
--request-delay |
0 | Delay between requests in milliseconds |
--save |
true | Save test results on servers |
--insecure |
false | Use HTTP instead of HTTPS |
--debug |
false | Enable debug output |
All flags can be set via environment variables with HPERF_
prefix:
export HPERF_HOSTS="10.10.1.{1...10}"
export HPERF_PORT="6000"
export HPERF_DURATION="60"
Deploy hperf across your Kubernetes cluster using Helm:
helm install hperf ./helm/hperf
The chart includes:
- StatefulSet for server deployment
- Job templates for automated bandwidth and latency tests
- ServiceAccount and RBAC configuration
See helm/hperf/values.yaml
for configuration options.
docker run -p 9010:9010 minio/hperf:latest server --address 0.0.0.0:9010
- Use dedicated storage: Specify
--storage-path
to a dedicated volume for test results - Set realistic test IDs: Use descriptive IDs like
prod-latency-2024-01-15
for easier result management - Configure external IPs: Always set
--real-ip
when servers have multiple interfaces - Plan for scale: Long tests with many servers generate significant data - monitor disk usage
- Network isolation: Run tests on a dedicated management network when possible
- Automate analysis: Use
--file
withanalyze
andcsv
commands to integrate with monitoring systems
- Start small: Test with 2-3 servers before scaling to production
- Use debug mode: Add
--debug
to understand communication flow - Experiment with parameters: Test different
--concurrency
,--payload-size
, and--buffer-size
values - Save results: Always use
--save
during testing to enable later analysis
Symptom: Unusually high throughput or low latency results
Solution: Ensure --real-ip
matches the external IP used for inter-server communication
Symptom: Client shows no statistics during test
Solution: Check firewall rules, verify servers can reach each other on the specified port, enable --debug
Symptom: Client can't connect to servers
Solution: Verify servers are running, check --address
and --port
match client configuration, test network connectivity
Symptom: #ERR
column shows many errors
Solution: Check server logs with --debug
, verify network stability, reduce --concurrency
or increase --request-delay
hperf is licensed under the GNU Affero General Public License v3.0. See LICENSE for details.
Contributions are welcome! This project is maintained by MinIO, Inc.
- Issues: Report bugs and request features on GitHub Issues
- Commercial Support: Contact MinIO for enterprise support and consulting