From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id qcj7MHSC1F46fQAA0tVLHw (envelope-from ) for ; Mon, 01 Jun 2020 04:22:12 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id iDdpLHSC1F4NTgAAB5/wlQ (envelope-from ) for ; Mon, 01 Jun 2020 04:22:12 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2D784940603 for ; Mon, 1 Jun 2020 04:22:12 +0000 (UTC) Received: from localhost ([::1]:35428 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jfbxf-0000k9-Mg for larch@yhetil.org; Mon, 01 Jun 2020 00:22:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58356) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jfbxa-0000k1-1U for guix-patches@gnu.org; Mon, 01 Jun 2020 00:22:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50953) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jfbxZ-0003De-Ol for guix-patches@gnu.org; Mon, 01 Jun 2020 00:22:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jfbxZ-0001Pn-Ka for guix-patches@gnu.org; Mon, 01 Jun 2020 00:22:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#40236] [PATCH] doc: Suggest Btrfs with compression instead of ext4 for root partition. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 01 Jun 2020 04:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40236 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Efraim Flashner Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Pierre Neidhardt , 40236@debbugs.gnu.org, Jonathan Brielmaier Received: via spool by 40236-submit@debbugs.gnu.org id=B40236.15909852895382 (code B ref 40236); Mon, 01 Jun 2020 04:22:01 +0000 Received: (at 40236) by debbugs.gnu.org; 1 Jun 2020 04:21:29 +0000 Received: from localhost ([127.0.0.1]:34266 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jfbx3-0001Ok-FV for submit@debbugs.gnu.org; Mon, 01 Jun 2020 00:21:29 -0400 Received: from mail-qt1-f193.google.com ([209.85.160.193]:37352) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jfbx2-0001OS-9l for 40236@debbugs.gnu.org; Mon, 01 Jun 2020 00:21:28 -0400 Received: by mail-qt1-f193.google.com with SMTP id x29so6771401qtv.4 for <40236@debbugs.gnu.org>; Sun, 31 May 2020 21:21:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=HvZWdO1jrgIypXA9VuIJ7EREfjAqwOPkvsE2fax5jEo=; b=K+hDKFZocjrAcO96u2d/0i0M58DxTq9dMsgUf5M/VOUiGC9De5s6tidIv529WcvIgA LB7HDQaZFJCL/jXyRpBcrUC/SeJL1zbLYQf7dVJiVVyKCqwjG8HdJ9CBUwe778hb1B+H U/RXmoIVfyUjbW7DyLc5tfkbqYyp4aeeOlJ5VX44SEuy1ApqQGsClzIZ2qzMx3rRm6tu AbMVnz1ssChZsMrCc8Wy0dzYBPYU5mDt/ivMs9tRuB91yar0ITlniV7S4oEOTFvb5iom R5iofb15NBRAo9qVWeTPXREm/n3Cq3IqYpi8L5Ild50L7kZp3RoZRW0Vtasa1v6pYdEi qaAA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=HvZWdO1jrgIypXA9VuIJ7EREfjAqwOPkvsE2fax5jEo=; b=T/CL2IOWdY4isi7BC6qfAnmAP8sCg6Kkq2a5QEyBM2IIwAT9tovU2Fb5yotgJAehvK N7RLdkJ9UhgicDfTCNbks3UlGycpBSiCI8yPTqjfHaSJzbSI6fgZ/WuIcv9+zOROHFAv 7YRcGyNOk3iuLSekmXdkLMxh9+teUwahUcJI6kDWIOLTl/pt79mJ3k+c6q+LjfGWpHXc OFkklrx5Xs70JiV31h4Xvey5jlOl29iv/zdrHFKSfI5LWGnENKGGpgRb0Zwc42DQ8UTy MxGezSMynFcaEKWXeujKUHS5Kp18NbhsBctQODKYjAmAnyr7qiROFXZHvMoGzYrcilCV qWIA== X-Gm-Message-State: AOAM5331Ns+MZQ8pTdb5s/XaJPqbIj7dpTO8yQeLs48DwQXIhazUo+UC +TbJb/smUGtIq0zEn5Irbpc= X-Google-Smtp-Source: ABdhPJxvK+i30Wi7nXGLZgJMH8XENFyRU/H9gb81XTsL80LTU4xPbx+FS8N32uMvDC4kIpw+aSx2Iw== X-Received: by 2002:ac8:3009:: with SMTP id f9mr19955631qte.335.1590985282735; Sun, 31 May 2020 21:21:22 -0700 (PDT) Received: from hurd (dsl-10-148-140.b2b2c.ca. [72.10.148.140]) by smtp.gmail.com with ESMTPSA id o6sm14783852qtd.59.2020.05.31.21.21.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 May 2020 21:21:22 -0700 (PDT) From: Maxim Cournoyer References: <87o8s3wz7d.fsf@ambrevar.xyz> <87o8s2k6lr.fsf@gmail.com> <20200409201244.GR1518@E5400> <87o8rzvlg9.fsf@ambrevar.xyz> <20200410082425.GA1518@E5400> <87eesvvhim.fsf@ambrevar.xyz> <87h7xmiz96.fsf@gmail.com> <87lfmya78b.fsf@ambrevar.xyz> <87y2p83650.fsf@ambrevar.xyz> <20200531075532.GD7397@E5400> Date: Mon, 01 Jun 2020 00:21:20 -0400 In-Reply-To: <20200531075532.GD7397@E5400> (Efraim Flashner's message of "Sun, 31 May 2020 10:55:32 +0300") Message-ID: <878sh75scf.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=gmail.com header.s=20161025 header.b=K+hDKFZo; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 0.09 X-TUID: xnqboxmSlVud Hello! Efraim Flashner writes: > On Sun, May 31, 2020 at 09:39:23AM +0200, Pierre Neidhardt wrote: >> Now that 37305 is merged, we can revisit this issue. >> >> 1. This patch only includes a documentation update. >> 2. We could make Btrfs the default in the graphical installer. >> 3. We would probably need to update the tests, at least for the latter. >> >> As mentioned above, I think it's safe to enable Btrfs without subvolume, >> with Zstd compression. >> >> For subvolumes, we would need to implement the corresponding tests. >> >> Thoughts? > > My main concern is the possibility of data loss. I don't know how much > is FUD and how much is legit so to me it seems safest to see what > OpenSuSE uses and to mimic that a bit (in terms of not using most of the > features available). Except for Btrfs RAID 5 and 6, which are still known to have issues and are considered experimental, I'd say mostly FUD, although there were some bugs in Linux 5.1 and 5.2. As you noted, (Open)SUSE defaults to Btrfs, and companies such as Synology ship network storage products with Btrfs on. If it was that bad, nobody would buy those, and the companies would stop proudly advertising their use of Btrfs. > That said, I use btrfs with no subvolumes with compression turned on and > I'm pretty happy with that. > > Two more things: > /var/guix/db should probably have CoW disabled, as should /tmp I haven't bothered and my system seems to be doing OK. When I asked in #btrfs, people told me to keep CoW unless I was really sure it was a problem (i.e., run benchmarks), as it implies loosing the checksum validation and compression. The command 'man 5 btrfs' also states that "Updates in-place improve performance for workloads that do frequent overwrites, at the cost of potential partial writes, in case the write is interrupted (system crash, device failure).", which doesn't sound safe to do for something as important as /var/guix/db. > would the deduplication of btrfs be "better" than the deduplication from > the daemon? On my system (with zstd compression), compsize -x /gnu/store suggests a resounding yes: --8<---------------cut here---------------start------------->8--- sudo compsize -x /gnu/store Processed 3479664 files, 954748 regular extents (3002677 refs), 1451082 inline. Type Perc Disk Usage Uncompressed Referenced TOTAL 57% 51G 88G 217G none 100% 32G 32G 81G zstd 33% 18G 56G 135G --8<---------------cut here---------------end--------------->8--- The delta between the Uncompressed and Referenced column is attributed to the deduplication done by Btrfs, and provides massive space savings in my case (this is just for /gnu/store). I'd need 217 GiB over a traditional fs such as EXT4 to hold my current store, while an uncompressed Btrfs partition would use only 88 GiB. With zstd compression, it's down to 51 GiB, or less that a quarter of what would have been required using EXT4. Maxim