All of lore.kernel.org
 help / color / mirror / Atom feed
From: Zdenek Kabelac <zdenek.kabelac@gmail.com>
To: Jean-Marc Saffroy <saffroy+redhat@gmail.com>
Cc: LVM general discussion and development <linux-lvm@redhat.com>
Subject: Re: [linux-lvm] Can I combine LUKS and LVM to achieve encryption and snapshots?
Date: Fri, 29 Sep 2023 15:41:46 +0200	[thread overview]
Message-ID: <f4f236a4-e78a-416c-8ebb-65ed66dd3513@gmail.com> (raw)
In-Reply-To: <CAM5YWZdnPJtZ_BDWkspDzoTk=6Zk-BG=eiH6hbVe2F-e57dDhg@mail.gmail.com>

Dne 28. 09. 23 v 14:23 Jean-Marc Saffroy napsal(a):
> On Wed, Sep 27, 2023 at 5:41 PM Zdenek Kabelac <zdenek.kabelac@gmail.com> wrote:
>>
>>> What is the role of "dmsetup suspend"? I am having trouble finding
>>> decent documentation about its purpose and how it's related to
>>> snapshots. I did not need it in my experiments, so I am curious.
>>>
>>
>>
>> Suspend is freezing device's i/o queue  (together with freezing FS layer - so
>> the snapshot should be easily mountable without requiring extensive fsck
>> operation as it would be missing some important metadata to be written on disk)
>> So the goal of a suspend is to take a 'good point in time' where the content
>> of snapshot is having all 'committed' transaction on disk in valid state.
> 
> Is this still required or useful with a journaling FS like ext4? It is
> robust to pulling the plug at any time, so any point in time should be
> good, no?

Wondering where do you came to the idea that journaling FS can rescue such 
scenario flawlessly.  Sure 'FS' should not completely broke itself if you 
avoid this suspension & fsfreeze  - but on the other hand the internal 
inconsistency within a snapshot would require some repairing operation to 
happen - and potential risk of valid data loss as even ext4 by default 
journals only it's metadata, and 'data' are journaled only in 'data=journal' 
mode - which is however used only by very small group of users who are willing 
to give-up performance for this feature.

In all other cases - you want to get FS into frozen state before taking its 
snapshot - so there is maximal consistency.


> That said, I am curious about what can be achieved with dmsetup
> commands. By any chance, do you have pointers to documentation besides
> what's in the kernel (Documentation/admin-guide/device-mapper/)?

There are some DM talks available on the net describing some target logic in 
greater details with some drawn boxes describing I/O flow - but other then 
that I'm not sure what other kind of help would be needed here?

Regards

Zdenek

_______________________________________________
linux-lvm mailing list
linux-lvm@redhat.com
https://listman.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/

      reply	other threads:[~2023-09-29 13:43 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-24 22:09 [linux-lvm] Can I combine LUKS and LVM to achieve encryption and snapshots? Jean-Marc Saffroy
2023-09-26  9:26 ` Harald Dunkel
2023-09-26 20:00 ` Zdenek Kabelac
2023-09-26 23:10   ` Jean-Marc Saffroy
2023-09-26 23:32     ` Stuart D Gathman
2023-09-27  1:43     ` Demi Marie Obenour
2023-09-27  9:58     ` Zdenek Kabelac
2023-09-27 13:26       ` Roberto Fastec
2023-09-27 15:13         ` Jean-Marc Saffroy
2023-09-27 13:45       ` Jean-Marc Saffroy
2023-09-27 15:40         ` Zdenek Kabelac
2023-09-28 12:23           ` Jean-Marc Saffroy
2023-09-29 13:41             ` Zdenek Kabelac [this message]

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

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

  git send-email \
    --in-reply-to=f4f236a4-e78a-416c-8ebb-65ed66dd3513@gmail.com \
    --to=zdenek.kabelac@gmail.com \
    --cc=linux-lvm@redhat.com \
    --cc=saffroy+redhat@gmail.com \
    /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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.