HammerDB — Database Benchmarking
NOTE
Status: implemented and unit-tested, not proven on hardware. See the implementation status table. Command examples on this page show the intended workflow; the param block of each script is the authority for parameter names. Not proven on a live cluster.
HammerDB benchmarks SQL Server performance on Azure Local VMs using industry-standard TPC-C (OLTP) and TPC-H (OLAP) workloads. It measures transactions per minute (TPM) and new orders per minute (NOPM).
Run This Test
Prerequisites
- SQL Server instance deployed on an Azure Local VM
- HammerDB installed on the management station or target VM
- WinRM access to the target VM
- Framework prerequisites completed
Step 1 — Install HammerDB on the target VM
.\tools\hammerdb\scripts\Install-HammerDB.ps1 `
-ClusterName "hci01.corp.infiniteimprobability.com" `
-Nodes @("hci01-node1")Step 2 — Run the TPC-C benchmark
.\tools\hammerdb\scripts\Start-HammerDBTest.ps1 `
-ClusterName "hci01.corp.infiniteimprobability.com" `
-PrimaryNode "hci01-node1" `
-Profile "tpc-c" `
-Warehouses 100 `
-VirtualUsers 16Step 3 — Collect results
.\tools\hammerdb\scripts\Collect-HammerDBResults.ps1 `
-ClusterName "hci01.corp.infiniteimprobability.com" `
-PrimaryNode "hci01-node1" `
-RunId "<run-id-from-previous-step>"Step 4 — Ending a test early
There is no stop script for HammerDB. Start-HammerDBTest.ps1 writes a Tcl script whose runtimer is the ramp-up plus the test duration plus 60 seconds, so every run ends on its own after that time. To end one earlier, stop the hammerdbcli process on the primary node.
When to Use HammerDB
| Scenario | HammerDB |
|---|---|
| Validate SQL Server OLTP performance | ✅ |
| TPC-C transaction benchmarking | ✅ |
| TPC-H analytics query benchmarking | ✅ |
| Combined storage + compute validation | ✅ |
| Database sizing and capacity planning | ✅ |
Key Capabilities
- TPC-C (TPROC-C) — OLTP transaction processing simulation
- TPC-H (TPROC-H) — Decision support / analytics query workload
- Supports SQL Server, PostgreSQL, MySQL, Oracle, and more
- GUI, CLI, and web interfaces for flexibility
- Docker images available for reproducible CI/CD runs
What You Get
After a test completes, you will have:
- NOPM (New Orders Per Minute) — the primary TPC-C metric
- TPM (Transactions Per Minute) — total throughput
- TPC-H query times for analytics workloads
- Reports in PDF, DOCX, and/or XLSX format
File Locations
| Component | Path |
|---|---|
| Scripts | tools/hammerdb/scripts/ |
| Workload Profiles | tools/hammerdb/config/profiles/ |
| Alert Rules | tools/hammerdb/monitoring/alert-rules.yml |
| Report Templates | tools/hammerdb/reports/templates/ |
| Tests | tools/hammerdb/tests/ |
| Logs | tools/hammerdb/logs/ |
Deep Dive
| Topic | Page |
|---|---|
| Installation via PowerShell remoting | Installation |
| TPC-C and TPC-H profile configuration | Workload Profiles |
| Alert rules during test runs | Monitoring |
| Report formats and templates | Reporting |
| Common errors and fixes | Troubleshooting |
Automate This Test
To run HammerDB on a schedule or as part of a CI/CD workflow, see CI/CD Pipelines. The pipeline calls the same scripts listed above.