Overview
Load test UltraBalancer to validate performance, identify bottlenecks, and ensure it can handle your production traffic patterns.Apache Bench
Simple HTTP benchmarking tool
wrk
Modern HTTP benchmarking tool
hey
Go-based load generator
k6
Modern load testing for DevOps
Apache Bench (ab)
Installation
- Ubuntu/Debian
- macOS
- CentOS/RHEL
Basic Usage
Output Analysis
wrk
Installation
Basic Usage
Lua Scripts
post-request.lua
hey
Installation
Usage
k6
Installation
Load Test Script
load-test.js
Advanced k6 Test
advanced-test.js
Test Scenarios
Baseline Performance
Stress Testing
Spike Testing
Endurance Testing
Monitoring During Tests
Real-time Metrics
Results Analysis
Key Metrics to Track
Throughput
Throughput
- Requests per second (RPS): Target varies by application
- Transactions per second (TPS): For write-heavy workloads
- Bytes per second: Network throughput
Latency
Latency
- Average latency: Mean response time
- p50 (median): 50% of requests faster than this
- p95: 95% of requests faster than this
- p99: 99% of requests faster than this
- Max latency: Worst-case scenario
Errors
Errors
- Error rate: Percentage of failed requests
- Timeout rate: Requests that timed out
- Connection errors: Failed to connect
System Resources
System Resources
- CPU usage: Should not hit 100%
- Memory usage: Watch for memory leaks
- Network bandwidth: Avoid saturation
- File descriptors: Ensure sufficient limits
Best Practices
Example Test Suite
test-suite.sh