All of lore.kernel.org
 help / color / mirror / Atom feed
From: Zdenek Kabelac <zdenek.kabelac@gmail.com>
To: "Thomas Brücker" <public0x05bf@bluewin.ch>, dm-devel@lists.linux.dev
Subject: Re: Extending "thin_trim"
Date: Sat, 16 Nov 2024 20:41:21 +0100	[thread overview]
Message-ID: <f98d06f5-ac06-4c8a-9f3e-40da4260de20@redhat.com> (raw)
In-Reply-To: <d2d0c5ba9f9d28cdd435e0bbf951de5a.squirrel@main>

Dne 16. 11. 24 v 17:10 "Thomas Brücker" napsal(a):
> Hello developers and others,
>
> Intro:
> Lets consider a data device of an thin-provisioning combination. On it, some
> data blocks are allocated ('by the metadata'), others not. (By using a thin-
> provisioning combination, some data_blocks get allocated, then you write to
> them, their content is probably not zero, and later, such a data_block is
> disallocated.
> "thin_trim" discards such unallocated data_blocks on the data device.
>
> 'Extending':
> It would be fine, if "thin_trim" would have an option, that instead of
> releasing
> the blocks, "thin_trim" would write zeroes to these blocks.
> --> REASON:
> e.g.
> * if you backup a data device by copying it to another device e.g. by
> "dd", it
>    would save time, when unallocated blocks are not copied, but just 'jumped'
>    by seek (by specifying "conv=sparse" to dd) ("conv=sparse" does its job
>    only, if these unallocated blocks are zeroed).
>
> * I have an utility, that backups a data device clusterwise
>    (cluster != data_block) to a cloud. To save space on the cloud, clusters
>    which contain only zeroes, are not copied to the cloud. Here too, having
>    a data device where every unallocated data_block is zero, would be fine.
>
> Thank you for your generous device-mapper efforts.


Hi


I think you should pro probably examine this project: 
https://github.com/jthornber/blk-archive

IMHO zeroing would likely not be so good plan - i.e. imagine you have mostly 
empty 2TiB thinpool...

blk-archive solves this way more efficiently.


Regards


Zdenek




      reply	other threads:[~2024-11-16 19:41 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-16 16:10 Extending "thin_trim" "Thomas Brücker"
2024-11-16 19: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=f98d06f5-ac06-4c8a-9f3e-40da4260de20@redhat.com \
    --to=zdenek.kabelac@gmail.com \
    --cc=dm-devel@lists.linux.dev \
    --cc=public0x05bf@bluewin.ch \
    /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.