TECH Signal 290
RipGrep musl binaries occasionally segfault during very-large searches
Engineers deploying ripgrep musl binaries on large-scale search workloads may encounter unrecoverable crashes that are difficult to reproduce without sufficient data volume and concurrency. The root cause appears to be in musl's allocator rather than ripgrep itself, which raises concerns for any application statically linked against musl under similar memory pressure conditions.
Written by elseif from the cluster below · every claim links back to a sourceThe three things worth knowing
The crash triggers a SIGSEGV at a heap metadata integrity assertion inside musl's mallocng, within a calloc call originating from opendir during concurrent directory traversal.
Reproduction requires a sufficiently large search tree—roughly 20GiB across 1.8M files—and high concurrency, with the segfault typically appearing within about a minute on a 24-core system.
The bug was initially encountered in the ripgrep binary bundled with OpenAI Codex, which is byte-for-byte identical to the official ripgrep 15.2.0 x86_64-unknown-linux-musl release binary.
THE CLUSTER