user47827: What directories should I delete regularly to keep my disk usage under control when regularly running Bitcoin Core and the unit/functional tests?

user47827: This was answered on Twitter by various individuals.
You should remove the directory /tmp/test_common_Bitcoin Core regularly. For Martin Leitner-Ankerl this was 6GB of leftover files (leftovers only happen when tests fail or are canceled).
theStack also recommends running rm -rf /tmp/bitcoin_func_test_* every now and then.
The /tmp directory is usually only deleted at boot. It is uncommon on modern Linux distros for /tmp to be cleaned up automatically during runtime.
Occasionally (e.g. with the merge of #23371) you need to run rm -rf ./test/cache to force cache regeneration. In the #23371 case the pre-mined chain of the functional test framework changed and the functional tests using MiniWallet would fail (credit: theStack)
For general advice on compiling Bitcoin Core and running the tests see this doc from Jon Atack.

47827: <p>What directories should I delete regularly to keep my disk usage under control when regularly running Bitcoin Core and the unit/functional tests?</p>
 47827: <p>This was answered on <a href="https://twitter.com/sunitram/status/1457654478811828226?s=20" rel="nofollow noreferrer">Twitter</a> by various individuals.</p>
<p>You should remove the directory <code>/tmp/test_common_Bitcoin Core</code> regularly. For Martin Leitner-Ankerl this was 6GB of leftover files (leftovers only happen when tests fail or are canceled).</p>
<p>theStack also recommends running <code>rm -rf /tmp/bitcoin_func_test_*</code> every now and then.</p>
<p>The <code>/tmp</code> directory is usually only deleted at boot. It is uncommon on modern Linux distros for <code>/tmp</code> to be cleaned up automatically during runtime.</p>
<p>Occasionally (e.g. with the merge of <a href="https://github.com/bitcoin/bitcoin/pull/23371" rel="nofollow noreferrer">#23371</a>) you need to run <code>rm -rf ./test/cache</code> to force cache regeneration. In the #23371 case the pre-mined chain of the functional test framework changed and the functional tests using MiniWallet would fail (credit: theStack)</p>
<p>For general advice on compiling Bitcoin Core and running the tests see this <a href="https://jonatack.github.io/articles/how-to-compile-bitcoin-core-and-run-the-tests" rel="nofollow noreferrer">doc</a> from Jon Atack.</p>
