Repository navigation
Releases
Version 2.6.1
What's Changed
memtier_benchmark 2.6.1 is a packaging-only release: it contains the 2.6.0 code unchanged and fixes the CI signature check that blocked 2.6.0's YUM publish.
- RPM publishing: the YUM release job rejected correctly signed RPMs because the runner's newer rpm prints
Header OpenPGP V4 …instead ofHeader V4 …(#905). 2.6.0 shipped to Docker and APT without RPMs; use 2.6.1 for RPM installs.
See the 2.6.0 release notes for everything else in 2.6.
Full Changelog: 2.6.0...2.6.1
Version 2.6.0
What's Changed
memtier_benchmark 2.6.0 adds --request-timeout, a sliding-window tail-latency row, a Memcached meta protocol mode and a native Windows build, and fixes many --test-time, reconnect, retry and cluster edge cases.
Read Upgrade notes first: several changes move benchmark numbers or reject command lines that 2.5.x accepted.
Upgrade notes
Command lines and exit codes
--requestis ambiguous (#903). It now abbreviates both--requestsand--request-timeout; use the full name.- Empty and out-of-range numbers are errors (#699, #721, #748, #761, #668). Empty values such as an unset
--max-reconnect-attempts=$VARor--max-retries=$VAR(previously 0) are rejected; pass0explicitly. Wrapped and overflowing values, ports outside 1-65535 and--reconnect-backoff-factorinfinity or underflow are rejected too.--multi-key-getis capped at 16777214 and--data-offsetat 536870911. --uri(#764, #720). Credentials are percent-decoded, so a literal%XXin a password must be written%25XX; bracketed IPv6 hosts work.--data-import(#767). Keys or values over 512 MiB are rejected and--generate-keysvalidates the file at startup.- Runs that exited 0 can now fail. Write errors on any output file or stdout (exit 1; a closed pipe reader such as
| headis exempt) (#729, #760, #717), verification mismatches or a verification pass with no replies (#771), connection rejections counted as ops (#897; exit 1, or 2 under unlimited reconnects after--connection-stage-timeout), and a closed stdout with no--out-file(#736). - Signals. SIGTERM is handled like Ctrl+C (#706).
Output consumers
- New fields. Top-level
FATAL_ERRORon failed runs (#25),TotalsErrors,Retry AttemptsandRetried Opswith--retry-on-error(#801),Unanswered requestsinRuntime(#669), and library versions (#823). - Changed values. Empty latency histograms keep their JSON keys and write
0.000(#793). Percentile keys are no longer truncated or colliding (#517), duplicate--commandkeys get a" #N"suffix (#588, #631), and invalid UTF-8 becomes U+FFFD (#741, #751).--uriand-avalues are redacted in--json-out-fileand--show-config(#735).
Build and runtime requirements
- libevent 2.0.11 or newer (#812). The default-on Prometheus exporter needs 2.1.4 or newer; on 2.1.1 to 2.1.3 use
--disable-prometheus(#823). libtool is no longer required (#762). - A failed
evthread_use_pthreads()is now a fatal error instead of a warning that could hang later (#823). memtier also warns when the loaded libevent or OpenSSL has a different major.minor than the one it was built against.
New Features
- Request stall timeout:
--request-timeout=SECS(default0, off) fails connections whose requests are never answered, for example a proxy that completes the TCP handshake but stops callingaccept(). It is a stall timeout, not a per-request deadline: a connection that keeps receiving reply data never trips it, a connection that never answers is detected afterSECS, and one that goes silent after answering withinSECSto2*SECS. A timeout is a connection error (reconnected under--reconnect-on-error, otherwise the run fails). Do not set it below the length of a legitimate blocking command such asBLPOPorWAIT. (#903) - Sliding-window tail latency:
--latency-window=SECS(default 60,0disables, maximum 3600) under--realtime-latenciesadds awin<N>srow with the percentiles of every sample from the last N seconds. Rows show their sample count (n=), and percentiles from too few samples are flagged*. Also fixes theoverallrow dropping samples recorded between a client's last snapshot and its per-second reset, a bug since 2.4.0. (#386, #824) - Configurable progress display:
--progress-interval=SECS(positive whole seconds, default 1; 0 is rejected) renders progress every SECS seconds while supervision and export keep their cadence. (#129) - Memcached meta protocol:
--protocol=memcache_metafor SET, GET and multi-GET against Memcached 1.6.10 and newer;--wait-ratioand--commandare rejected at startup in this mode. (#363) - Abstract Unix sockets:
--unix-socket @NAMEconnects to Linux abstract-namespace sockets (name up to 107 bytes; use./@NAMEfor a filesystem path that starts with@). (#257) - Native Windows build: build and run on Windows 10+ with MSYS2 UCRT64 and the autotools build. Unix sockets are rejected on Windows. (#553)
- Cursor walks for more types:
--scan-incremental-iterationfollows cursors forHSCAN,SSCANandZSCANas well asSCAN(standalone, single command, pipeline 1). GeneratedMATCHarguments now stay fixed for the whole walk, including forSCAN. (#539) - Structured failure summary: with
--json-out-file, a failed run records a top-levelFATAL_ERRORstring and keeps the configuration and results already written. Successful runs and graceful interrupts do not gain the field; JSON notices on stderr appear only with--debug. (#25) - Retry counters in JSON:
TotalsgainsErrors,Retry AttemptsandRetried Opsunder--retry-on-error. (#801) - RESP2 without
HELLO: with--protocol=resp2, a server that answers-ERR unknown command 'HELLO'(Redis older than 6.0, other RESP servers) is treated as RESP2 instead of stalling.--protocol=resp3still fails against such a server, now with a clearer message. (#884)
Bug Fixes
--test-time, reconnects and retries
- Timed-run end times: clients end at the later of their deadline and last reply, send no workload past the deadline, and exit
--clients-startruns at--test-time; the JSONStart time,Finish timeandTotal durationaverage all threads, not the last one. (#869, #876, #892, #722, #742, #723, #789) - Setup-only clients: a client that reconnects repeatedly but never submits workload no longer adds its setup interval to
Total duration, and a late first connect no longer ends a--reconnect-on-errorrun with zero requests. (#821, #865, #714) - Dead server: with
--reconnect-on-errorand unlimited attempts (the default), the--test-timedeadline wins over further reconnects and the run exits normally; a finite--max-reconnect-attemptsstill exits 1 when exhausted. (#666, #873, #812) --connection-stage-timeout: measured in microseconds, soNcan no longer abort after just over N-1 seconds; a worker that already ended is not also reported as an abort; exit 2 if any--run-countrun hits it. (#860, #891, #752)- Hangs on rejected setup: a run whose AUTH, SELECT or HELLO is rejected on only some connections, or on reconnect, now ends or reconnects instead of hanging; a retried
CLUSTER SLOTSreplaces a hang. (#750, #630, #667) - Connection rejections and errors:
-ERR Protocol error,-ERR max number of clientsand-DENIED ... protected modeare not counted as operations, ordinary error replies count as connection progress (#897, #788), and connection errors and Ctrl+C of clients that never connected are reported (#707, #698, #730). - Retry backoff: each retry waits its own
retry-backoff-ms * factor^resends; fractional factors are floored at 100 ms (or--retry-backoff-msif smaller),nan,inf, overflowing and empty factors are rejected. (#700, #727, #694, #692) - Retry accounting: a
--requestsrun no longer stops early, exits 0 having sent fewer commands than requested, or fails with "client(s) stopped before reaching their stop condition" when retries remain after the last request; in-flight requests dropped on disconnect no longer stall clients. (#559, #556) - Worker threads and transactions: worker threads are no longer silently re-run after connection errors (#546); a
--transactionblock is no longer continued after itsMULTIis lost to a reconnect, transaction requests are not retried, and planned--reconnect-intervalreconnects finish the rotation first (#607, #634, #615, #807, #606, #893).
Cluster mode
- Redirects and slot maps:
-MOVEDretries go to the node the reply names,-ASKretries sendASKINGfirst, empty hosts resolve to the replying connection, andCLUSTER SLOTSfollowsMOVEDeven with a full pipeline; refreshes no longer happen inside an openMULTI, twice concurrently or on every-READONLY, and back off per client onCLUSTERDOWN(1 s doubling to 8 s). (#622, #600, #787, #591, #576, #618, #662, #777, #877) - Connections and partial maps: only a dropped cluster connection is reconnected, and once; synchronous dial failures are retried; a refresh that retires its own connection no longer aborts the run; partial slot maps no longer leave workloads spinning, and a seed owning none of the keys no longer stalls. (#560, #574, #575, #584, #799, #612)
- Replica reads and statistics: keyless
--commandrequests stay off replicas unless replica reads are allowed, strict--read-preference=secondarywith no replicas names the cause, retried redirects count once and arbitrary-command redirects count inMOVED/secandASK/sec. (#887, #901, #605, #593, #582, #594, #583, #878)
Output, JSON and statistics
--run-count: BEST and WORST no longer always show run 1 and prefer complete runs (a run with a failed worker carriesInterrupted: true); the aggregateTotalsblock has a real histogram,KB/secand miss-rate warning, and latency is weighted by completed samples. (#571, #794, #572, #581, #573, #586, #804, #757)- Latency and counters: built-in
WAITreports real latency in JSON (#805); run statistics and hit, miss, MOVED and ASK counters are 64-bit, so totals no longer wrap on 32-bit and Windows builds (#552, #659). - JSON validity: strings, keys and non-UTF-8 bytes are escaped or replaced, deep-percentile keys no longer truncate or collide, and the...
Version 2.5.2
memtier_benchmark 2.5.2 is a maintenance release on the 2.5 line.
Fixes
- Build against OpenSSL 4.0. The OpenSSL-4.0-only
--tls-protocolscontiguity check calledbitmask_is_contiguous()before it was declared, somemtier_benchmark.cppfailed to compile with OpenSSL 4.0. Added a forward declaration under the same guards. Thanks @collinfunk. (#548) - TCP keepalive and no-delay are always applied.
setsockopt(SO_KEEPALIVE)andsetsockopt(TCP_NODELAY)were passed an uninitializedflagsvalue, so depending on stack contents the options could be left disabled. They are now set explicitly, with a regression test covering connection setup and reconnects. (#541) - URI credentials and hostnames are owned correctly. Values parsed from a
redis://URI mixedmalloc/strdupcopies with borrowedargvpointers. They are now held in owned storage for the lifetime of the run. The "URI takes precedence" warnings now fire only when the conflicting flag (--tls,--authenticate,--select-db,--port,--host/--server) was actually given. (#544)
Packaging / CI
- Restored the legacy OpenSSL and Debian Bullseye builds, and stabilized the mixed Zipfian validation test. (#540)
- CI now runs on the
2.*maintenance branches; previously onlymaster/maingot build and test runs. (#549)
Full Changelog: 2.5.1...2.5.2
2.5.1
What's Changed
Packaging
- Debian 13 (trixie) and Ubuntu 26.04 LTS (resolute) are now built and published to the packages.redis.io APT repository, fixing installation on those releases (#511).
- Fixed Ubuntu armhf/arm64 package builds. The Ubuntu arm ports mirror (
ports.ubuntu.com) is unreachable from the CI runners; every Ubuntu arm64/armhf.debhad been failing to build.debian/setup_sbuild.shnow uses a reachable mirror (with the correct/ubuntu-portspath), so arm packages publish again across all Ubuntu codenames.
Observability
- Added a Grafana dashboard for the Prometheus
/metricsexporter (grafana/dashboards/prom-memtier.json), with import instructions in the real-time metrics docs (#510).
Docs
- README now lists the supported APT platforms: Debian 11/12/13 and Ubuntu 20.04/22.04/24.04/26.04.
Full Changelog: 2.5.0...2.5.1
Version 2.5.0
memtier_benchmark 2.5.0
First release of the 2.5 minor series (cut from master @ ec3d55f). Same-source performance verified equal-or-better vs 2.4.4 on Intel Ice Lake (pipeline 1: +0.04%, pipeline 16: +0.29%, p99 unchanged).
Features
- Built-in Prometheus
/metricsexporter via--prometheus-port(opt-in), with per-run labels and configurable latency buckets (#468); arbitrary-command hit/miss counter series (#484) --read-preferenceread-endpoint routing for cluster and standalone (#456)- Per-thread and whole-process CPU tracking with saturation warning (#471)
--transactionEXEC-abort breakdown and live miss/abort rates (#486); single-key reuse across a--commandrotation in cluster mode (#485)- Cluster-mode endpoint count and connection fan-out reporting (#489, #491)
Performance
fill_pipeline: makebufferevent_enableconditional, recovering the ~4% ops/sec regression introduced in 2.4 (#448)- Alloc-free per-position miss tracking; drop reply materialization for empty-collection arbitrary commands (#472, #469)
Fixes
- Enable arbitrary-command miss tracking on cluster shard connections (#477)
- Normalize latency stats through int64 microseconds (#463)
- Monitor-input hardening: skip HELLO while loading, bound fuzz payload (#498)
Packaging / CI
Version 2.4.4
memtier_benchmark 2.4.4 is a maintenance release on the 2.4 line.
Fixes
- Correct Ops/sec for sub-millisecond aggregate spans.
run_stats::timeval_factorial_averageaveragedtv_sec/tv_usecindependently with truncation, so aggregate durations under ~1 ms could round to 0 µs and make the summary reportOps/sec = 0(and Hits/sec, KB/sec) even withCount > 0and a non-zero average latency. Now normalized throughint64_tmicroseconds. (#463, #465) - RPM repository is publicly readable again. The YUM publish step uploaded objects with a private ACL, causing
403 AccessDeniedforpackages.redis.io/rpm/**(repo metadata and packages). Objects are now uploaded withpublic-read, matching the DEB pipeline. (#500, #501/#502) --monitor-input: skipHELLOlines while loading and bound the fuzz payload. (#496/#497)- monitor-input fuzz harness: fix 5 pre-existing nightly failures. (#475/#495)
CI / test hardening
- Backport nightly fuzz/soak harness fixes; add an opt-in timeout to the soak
Benchmark.run()path. (#493, #499)
Observability
Full changelog: 2.4.3...2.4.4
Version 2.4.3
What's Changed
Enhancements
--transactionnow pins a rotation to a single key, in every mode (#485). In--cluster-mode --transaction, every__key__across a--commandrotation now resolves to the same key (taken from the first keyed command's--command-key-pattern), so all keyed commands of aWATCH/MULTI/EXECunit (e.g.WATCH/GET/SETEX) hash to one slot and one key. Previously each keyed--commanddrew an independent key: without a hash tag they landed in different slots and the cluster rejected the transaction withCROSSSLOT/MOVED; even with a hash tag theWATCHguarded a different key than theSETEXwrote, making the optimistic lock meaningless. The same per-rotation key reuse was also lifted into the base client, so--transactionis no longer a no-op without--cluster-mode— it now collapses keys against a single endpoint that fronts a slot-enforcing backend (e.g. a Redis Enterprise proxy accessed without--cluster-mode). Requires the literal text around__key__(including any{tag}) to be identical across keyed commands;--helpand the standalone warning updated accordingly.
New Features
- EXEC aborts broken out from misses under
--transaction(#486). AnEXECthat returns a null array is an optimistic-lock abort (a watched key changed), not a cache miss. Under--transactionthe stats table gains anAborts/seccolumn alongsideMisses/sec, the per-command warning forEXECnow reads "abort rate" instead of "miss rate", and JSON output gainsAborts/secfor theEXECcommand block and Totals. This is a display-only reinterpretation —EXECnulls still increment the per-command miss counter, so global miss totals are unchanged, and the column/field/wording only change under--transaction; default arbitrary-command output is untouched.
Bug Fixes
--realtime-latencieslive miss % in--command(arbitrary) mode: the live "miss %" was wired to the SET/GET hit/miss counters, which stay zero for arbitrary commands, so it always showed-. It now sources misses from the arbitrary-command counters, and adds a live "abort %" field under--transaction(#486).
Full Changelog: 2.4.2...2.4.3
Version 2.4.2
What's Changed
Performance
- Restore HGETALL/HMGET throughput regressed by arbitrary-command miss-tracking (RED-200840). Miss-tracking (default-on since 2.4.0) materialized every reply to attribute per-position hits/misses. EmptyCollection commands (HGETALL/SMEMBERS/LRANGE) now read emptiness from the declared top-level array length with zero materialization (#469); ArrayPerElementNulls commands (HMGET/MGET/ZMSCORE/GEOPOS) now record per-position hits via an alloc-free parser bitmap instead of building the reply tree (#472). Restores both HGETALL and HMGET to within ~2-3% of the pre-2.4 (2.2.1) baseline with miss-tracking left on; no change to reported hit/miss statistics.
Full Changelog: 2.4.1...2.4.2
Version 2.4.1
What's Changed
Bug Fixes
- Recover client-bound throughput:
bufferevent_enableinfill_pipelineis now conditional on a newm_bev_pausedflag instead of firing on every response. Recovers ~12% ops/sec when the client is the bottleneck; no change on server-bound workloads (#448).
Full Changelog: 2.4.0...2.4.1
Version 2.4.0
What's Changed
New Features
- Cluster
--monitor-inputsupport: Route-then-stage replay across shards with end-to-end backpressure (#395, #399). - Cluster
--multi-key-get: Slot-aware MGET routing with a shared cache rebuilt on every topology refresh (#397). --transactionflag: Pins a--commandrotation to a single shard in--cluster-mode; works with--pipeline > 1(#390, #400).--retry-on-errorpipeline: Adds--max-retries,--retry-backoff-ms,--retry-backoff-factor,--retry-on=LIST,--max-retry-queue,--failed-keys-file(#381).--realtime-latencies: Streaming HDR-histogram block emits per-secondcur (avg: …)for ops/sec, bytes/sec, miss%, and configured percentiles (#379).- Per-key miss tracking for
--command:--command-miss-tracking={auto,off}plus--miss-rate-threshold=PCT; emits aPer-Key MissesJSON section (#374, #398). --connection-stage-timeout=SECS: Bounds the AUTH/HELLO/SELECT/CLUSTER SLOTS / first-steady-state phase; defaults to 30 s,0disables (#431).- TLS handshake logging: New
TLS connection established: protocol X, cipher Ystderr line and a top-levelTLSobject inmb.json(#403).
Bug Fixes
- Stack overflow in
--monitor-inputreplay: VLA-allocated split-token buffer overflowed for large lines; now heap-allocated (#405). - Stack smash in memcached text parser: Unbounded
sscanf("%s %s …")allowed a hostile server to overflow a 256-byte stack buffer; widths now bounded (#415). - OOB read on malformed
CLUSTER SLOTS:handle_cluster_slotsnow validates reply shape and clamps slot bounds; malformed shards are logged and skipped (#425). - SIGPIPE on TLS RST:
signal(SIGPIPE, SIG_IGN)installed process-wide so a peer RST mid-write no longer exits 141 (#383). - Crash handler hardening:
sigaltstackon main and each worker, pre-warmed backtrace symbols,backtrace_symbols_fd, and a 5 s watchdog (#412, #416). - Cluster reconnect SIGABRT:
cluster_client::connect()is now idempotent under--cluster-mode --reconnect-on-error(#378). - Reconnect duplicate-error thread kill: Duplicate error callbacks while a reconnect is pending no longer break the event loop (#392).
- Unbounded reconnect/retry backoff: Exponential backoff is now capped at 60 s; previously
factor=2.0+ unlimited attempts could schedule reconnects ~34 years out (#433). --monitor-inputparsing: Preserves embedded NUL bytes in the loader; handles CR-only line endings (#434).- RESP3 push and nil: Accepts
>push frames (drained out-of-band) and counts_(nil) as a miss in arbitrary-command tracking (#435). - CLI input validation: Rejects at parse time inputs that 2.3 silently accepted and then crashed/hung on —
-c/-t/-n/--test-timenegatives (#436),--run-countoverflow (#429),--pipeline / --data-size / --data-size-list(#428),--command / --command-ratio(#427),--key-stddev / --key-median / G:Gdegenerate ranges (#430). All return a clear error andexit 2. - Bound recursive RESP teardown: Iterative
~mbulk_size_elso deeply-nested replies can't stack-overflow on cleanup;-Werror=vlabuild guard (#415). - TLS path leakage in JSON:
--cert/--key/--cacertare now basename-only inmb.json(#440). m_reqs_generateddefensive clamp: Underflow guard at three cluster_client subtraction sites (#437).- Hits/sec /0 guard:
summarize()rate computations no longer emit+Inf/nanon zero-duration runs (#436).
Build & Configuration Improvements
- OpenSSL 4.0 build: Replaces removed
SSL_OP_NO_TLSv*flags withSSL_CTX_set_min/max_proto_version; rejects non-contiguous--tls-protocolsselection at parse time on 4.0+ (#432, #444).
Developer Tooling & CI Improvements
- libFuzzer harnesses: Per-PR 60 s smoke fuzz across
split_command_to_args,monitor_input, andredis_protocol(#421). - Adversarial RESP mock-server fixtures: 12 deterministic payloads exercising the parser surface (#419).
- Monitor-input black-box fuzzer: Corpus + synthetic seeds, nightly +
run-fuzzlabel trigger (#422). - Hypothesis CLI fuzzer: Re-broadened strategy + new
cli-fuzz-nightly.yml(#424, #445). - Differential vs
redis-benchmark/redis-cli:run-differentialPR label, label/cron-triggered workflow (#420). - Nightly soak suite: 7 scenarios (long-run memory, large payloads, high concurrency, connection churn, cluster turbulence, retry storm, slow network) with
run-soaklabel (#423). - Sanitizer stress matrix: STRESS=1 cells across ASAN/UBSan/TSAN (#418).
- Workflow permissions hardening:
permissions: contents: readdeclared on every workflow (#380, #393). - PARALLELISM=2 on cluster cells: Resolves Test cell 15-min timeout on cluster TLS (#402).
New Contributors
- @arpitjain099 made their first contribution (#380, #393).
Full Changelog: 2.3.1...2.4.0