From patchwork Wed Jan 12 17:21:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 36282 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C329727BBEA; Wed, 12 Jan 2022 17:41:32 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 81E4727BBE9 for ; Wed, 12 Jan 2022 17:41:32 +0000 (GMT) Received: from localhost ([::1]:44938 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n7hcp-0004Ed-Ku for patchwork@mira.cbaines.net; Wed, 12 Jan 2022 12:41:31 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50926) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n7hJy-0005Ql-4l for guix-patches@gnu.org; Wed, 12 Jan 2022 12:22:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:37745) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n7hJx-0006yR-Pk for guix-patches@gnu.org; Wed, 12 Jan 2022 12:22:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n7hJx-00083Y-NH for guix-patches@gnu.org; Wed, 12 Jan 2022 12:22:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53213] [PATCH] daemon: Always default to gzip for log compression. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 12 Jan 2022 17:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 53213 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53213@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.164200810030917 (code B ref -1); Wed, 12 Jan 2022 17:22:01 +0000 Received: (at submit) by debbugs.gnu.org; 12 Jan 2022 17:21:40 +0000 Received: from localhost ([127.0.0.1]:58874 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hJc-00082b-HS for submit@debbugs.gnu.org; Wed, 12 Jan 2022 12:21:40 -0500 Received: from lists.gnu.org ([209.51.188.17]:35996) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hJX-00082N-IX for submit@debbugs.gnu.org; Wed, 12 Jan 2022 12:21:39 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50418) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n7hJX-0004f1-Ap for guix-patches@gnu.org; Wed, 12 Jan 2022 12:21:35 -0500 Received: from [2001:470:142:3::e] (port=52122 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n7hJS-0006oM-25; Wed, 12 Jan 2022 12:21:34 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=YY+vqVuBKnHv/aeJh08WFY6J4MSoyUS3px4dt16EEoo=; b=geZWfTtQj+FfvR Do+VR51ohKRMlgOtkiQ63U/PWmdkop5r7dlN+Bq5x24wMXma8UpKzK1y1b4oG4ANGhf/2nFpLai8O LTsBlZpyTqHEy8P43gPREPHWQASP+QuOGdXAxPNHikxkF98qGz5VV5fXYSfcKzCHOLsZ/imjvuLBe 0USKZ3aqbdtjlylX+UaLA1Rom18e+87dLQMn7m2HMUobinvV+yR2WE/Jg41rPqldtqxoKcSyj4U33 PAROPvhdm9O92f/J+R+2vadiSMQ0qKMHYs3edaGa9Kn8+xX/33NCTEiif7npP7J5OlslrTdcDKYOG iY5Kf/MqlLHgw9JDu4DA==; Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=34738 helo=gnu.org) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n7hJQ-0005oK-0r; Wed, 12 Jan 2022 12:21:30 -0500 From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Wed, 12 Jan 2022 18:21:18 +0100 Message-Id: <20220112172118.12250-1-ludo@gnu.org> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * nix/libstore/globals.cc (Settings::Settings): Have 'logCompression' default to COMPRESSION_GZIP unconditionally. * gnu/services/base.scm ()[log-compression]: Default to 'gzip. * doc/guix.texi (Invoking guix-daemon, Base Services): Adjust accordingly. --- doc/guix.texi | 4 ++-- gnu/services/base.scm | 2 +- nix/libstore/globals.cc | 4 ---- 3 files changed, 3 insertions(+), 7 deletions(-) Hello! I think bzip2 compression of the build logs doesn’t buy us much, it doesn’t play well with ‘guix publish’, and bzip2 is generally rather uncommon these days—hence this patch. Thoughts? Ludo’. base-commit: cd68fc1e42f3f233ba5ccfd1323e46509a970d6b diff --git a/doc/guix.texi b/doc/guix.texi index 876172fa3a..084d3c92fe 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -1690,7 +1690,7 @@ Compress build logs according to @var{type}, one of @code{gzip}, Unless @option{--lose-logs} is used, all the build logs are kept in the @var{localstatedir}. To save space, the daemon automatically compresses -them with Bzip2 by default. +them with gzip by default. @item --discover[=yes|no] Whether to discover substitute servers on the local network using mDNS @@ -16608,7 +16608,7 @@ The number of seconds of silence and the number of seconds of activity, respectively, after which a build process times out. A value of zero disables the timeout. -@item @code{log-compression} (default: @code{'bzip2}) +@item @code{log-compression} (default: @code{'gzip}) The type of compression used for build logs---one of @code{gzip}, @code{bzip2}, or @code{none}. diff --git a/gnu/services/base.scm b/gnu/services/base.scm index e46bb591a9..71e2baf959 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -1565,7 +1565,7 @@ (define-record-type* (timeout guix-configuration-timeout ;integer (default 0)) (log-compression guix-configuration-log-compression - (default 'bzip2)) + (default 'gzip)) (discover? guix-configuration-discover? (default #f)) (extra-options guix-configuration-extra-options ;list of strings diff --git a/nix/libstore/globals.cc b/nix/libstore/globals.cc index 0cc001fbe4..d4f9a46a74 100644 --- a/nix/libstore/globals.cc +++ b/nix/libstore/globals.cc @@ -45,11 +45,7 @@ Settings::Settings() useChroot = false; impersonateLinux26 = false; keepLog = true; -#if HAVE_BZLIB_H - logCompression = COMPRESSION_BZIP2; -#else logCompression = COMPRESSION_GZIP; -#endif maxLogSize = 0; cacheFailure = false; pollInterval = 5;