From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:50819) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5sSI-0002HP-Te for guix-patches@gnu.org; Sun, 23 Feb 2020 09:42:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j5sSH-0004b6-SU for guix-patches@gnu.org; Sun, 23 Feb 2020 09:42:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:44599) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j5sSH-0004aw-Pa for guix-patches@gnu.org; Sun, 23 Feb 2020 09:42:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1j5sSH-000596-My for guix-patches@gnu.org; Sun, 23 Feb 2020 09:42:01 -0500 Subject: [bug#39734] [PATCH] scripts: Emit GC hint if free space is lower than absolute and relative threshold. Resent-Message-ID: From: Pierre Neidhardt In-Reply-To: <875zfxtlrk.fsf@gnu.org> References: <20200222104653.1324-1-mail@ambrevar.xyz> <874kvizxi6.fsf@gnu.org> <87tv3ig8bc.fsf@ambrevar.xyz> <87h7zhttk1.fsf@gnu.org> <874kvhfrqk.fsf@ambrevar.xyz> <875zfxtlrk.fsf@gnu.org> Date: Sun, 23 Feb 2020 15:41:18 +0100 Message-ID: <87pne5e581.fsf@ambrevar.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 39734@debbugs.gnu.org --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable See the original discussion: https://lists.gnu.org/archive/html/guix-devel/2020-02/msg00303.html Our users fall into 2 categories: =2D Those with a "small" store partition, say 25 GiB. =2D Those with a "big" store partition, say 1 TiB. If we use a relative threshold, users with a big partition will get a hint all the time. This may mislead newcomers into thinking that they should run "guix gc" while they still have 50 GiB of free space. If we use an absolute threshold, users with a small partition will get a hint all the time. In both cases, the hints becomes irrelevant if it's triggered for the wrong reason. The fix is to use both thresholds and to check against the lowest one. Does that make more sense? Cheers! =2D-=20 Pierre Neidhardt https://ambrevar.xyz/ --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAl5Sjw4ACgkQm9z0l6S7 zH/EXwf+IbtfLX8XEajP/VJVtT6CvbhavFyu10YFCvFNkYAA/gSullVT7vQil4zc xF0YLuy3Lt3HWWk5HfEuFQuVHKRf5LdiRiJB23SwwFIZRd4cd0DtRdPVRgazhJ67 Ulo6sW5iHRBzayfs3H7FnCUgTWZaskoSVIiIL/83V1Ezbj7fISqKgYufeBdMJ5LB kb+XBEN5pbFfsUMQyDbUxpToeswhJsyCw7aVGEnsF21jc6QB/W1cex6U0pvdPHMe cIDAhQdVcpMLXhnmVvINFh585XXU6DZJF+hnIx1kTktdZIBrqB4VBbxkjq3qGehE Y4E+tzRFAwHYWosz7/xkvcXT/8173Q== =hiYv -----END PGP SIGNATURE----- --=-=-=--