From: Dragan Simic Date: Wed, 12 Jun 2024 16:25:11 GMT Subject: Re: [RFC] Avaiable disk space when automatic garbage collection kicks in Message-ID: <164fc547afd66caf58019b6c614b5134@manjaro.org> In-Reply-To: <950d4ad3bcee79df1424faee09eb6b00@manjaro.org> [Maybe this RFC deserves a "bump", so let me try.] On 2024-04-08 18:29, Dragan Simic wrote: > Hello all, > > A few days ago I've noticed a rather unusual issue, but still > a realistic one. When automatic garbage collection kicks in, > as a result of gc.auto >= 0, which is also the default, the > local repository can be left in a rather strange state if there > isn't enough free space available on the respective filesystem > for writing the objects, etc. > > It might be a good idea to estimate the required amount of free > filesystem space before starting the garbage collection, be it > automatic or manual, and refuse the operation if there isn't > enough free space available. > > As a note, the need_to_gc() function already does something a bit > similar with the available system RAM. > > Any thoughts?