unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Nicolas Graves via "Development of GNU Guix and the GNU System distribution." <guix-devel@gnu.org>
To: guix-devel@gnu.org
Subject: btrfs recommended layout for snapshots?
Date: Mon, 14 Aug 2023 16:05:35 +0200	[thread overview]
Message-ID: <87jztxn2hc.fsf@ngraves.fr> (raw)


Hi! I've installed a guix system with btrfs for some time, but I now
want to configure it to properly handle snapshots, and there doesn't
seem to be a lot of resources about the way to do it properly.

What I mean is that by having a simple /root/boot/home/store/log layout
doesn't seem to really be adapted to snapshotting regurlarly. The most
comprehensive documentation I've found yet about how to do it properly
is here :
https://documentation.suse.com/sles/12-SP4/html/SLES-all/cha-snapper.html#snapper-dir-excludes

It explains quite clearly why some subvolumes are better be left alone /
not snapshotted. Although this is quite clear, I'm wondering about the
implications for a guix system, where basically most of what would be
useful to store in a btrfs snapshot is already handled by guix.

I guess there are two ways to consider the issue :
- either going for a simple layout with / snapshots, with a snapshot
of the store and exclusion of the directories listed in the previous
link. But that would mean we are regularly snapshotting the store, which
is not really useful if we suppose that we can get back what we need
with a system / home reconfigure.

- either not snapshotting the rootfs / at all, with the hypothesis that
  we get it back entirely from config files. Is that possible ? Is there
  information in / (I think of /etc in particular) that is saved, not
  temporary and not managed by guix system that would justify that we
  want to snapshot / at all?
  This would allow to simply care about only a few "user data"
  directories, and be sure to not miss anything when there's a need to
  restore the state.

I can't find easily a case of successful use of the second
configuration, but would be glad to find one, as well as some discussion
about what would be a recommended way to secure the state beyond
dotfiles. 

-- 
Best regards,
Nicolas Graves


             reply	other threads:[~2023-08-14 14:06 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-14 14:05 Nicolas Graves via Development of GNU Guix and the GNU System distribution. [this message]
2023-08-14 14:41 ` btrfs recommended layout for snapshots? Nicolas Graves via Development of GNU Guix and the GNU System distribution.
2023-08-15 14:33   ` Efraim Flashner
2023-08-15 19:58     ` Maxim Cournoyer
2023-08-16  8:10   ` Nicolas Graves via Development of GNU Guix and the GNU System distribution.
2023-08-16  9:31     ` Nicolas Graves via Development of GNU Guix and the GNU System distribution.
2023-08-16 14:39     ` Efraim Flashner
2023-08-17 23:58     ` Nicolas Graves via Development of GNU Guix and the GNU System distribution.
2023-09-12 11:39       ` Andrew Tropin
2023-08-14 16:56 ` Felix Lechner via Development of GNU Guix and the GNU System distribution.
2023-08-14 19:49   ` Maxim Cournoyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87jztxn2hc.fsf@ngraves.fr \
    --to=guix-devel@gnu.org \
    --cc=ngraves@ngraves.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).