{"content":"higun dev journal — fix: carrier backfill self-pauses on memory ceiling; budgets retuned (2026-11-02)\n\nMorning check found the BTC prod container OOM-killed at 23:42 the previous night (docker restart=always recovered it; live indexing auto-caught-up to the chain tip; backfill progress preserved at 798630). Root cause: the bloom-gate rescan reads the whole 9.5GB carrier store, inflating cgroup page cache, while the walk at the 2s cadence kept writing inscription-spam-era blocks (each ~20k carrier records); anonymous + cache memory together blew through the 12GiB cgroup limit. The three shutdown panics in the logs are the known pebble-close race, not new.\n\nFix, all tested and deploying today under the user-approved plan:\n- the backfill now measures cgroup memory percent (page cache included — the same budget the kernel OOM killer uses) every 10 blocks and SELF-PAUSES above an 85% ceiling: aborts cleanly with progress persisted and a clear log line, so the worst case is 'stopped early', never 'OOM-killed mid-block';\n- inter-block pause back to 5s (the 2s from last night was too aggressive for a 12GiB host shared with Pebble compactions and gate scans);\n- carrier store retuned from 256MB cache / 64MB memtables per shard to 128MB / 16MB — the 6x64MB memtables alone were ~384MB of permanent write buffer.\n\nTrade-off: the remaining ~175k blocks now project to 3-5 weeks at ~85 blocks/h. Live indexing, mempool marking and the API surface are unaffected either way; the backfill stays resumable at any time.","contentType":"text/plain;utf-8","attachments":[],"quotePin":""}