From: Fiona Ebner <f.ebner@proxmox.com>
To: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>,
qemu-block@nongnu.org
Cc: qemu-devel@nongnu.org, armbru@redhat.com, eblake@redhat.com,
xiechanglong.d@gmail.com, wencongyang2@huawei.com,
hreitz@redhat.com, kwolf@redhat.com, jsnow@redhat.com
Subject: Re: [PATCH v2 3/4] qapi: blockdev-backup: add discard-source parameter
Date: Fri, 26 Jan 2024 10:21:22 +0100 [thread overview]
Message-ID: <1cec54a7-073c-4dd7-a390-9890bf990720@proxmox.com> (raw)
In-Reply-To: <ee7438e8-ba86-40cc-b24e-5ea6160ba564@yandex-team.ru>
Am 25.01.24 um 18:22 schrieb Vladimir Sementsov-Ogievskiy:
>
> Hmm. Taking maximum is not optimal for usual case without
> discard-source: user may want to work in smaller granularity than
> source, to save disk space.
>
> In case with discarding we have two possibilities:
>
> - either take larger granularity for the whole process like you propose
> (but this will need and option for CBW?)
> - or, fix discarding bitmap in CBW to work like normal discard: it
> should be aligned down. This will lead actually to discard-source option
> doing nothing..
>
> ==
> But why do you want fleecing image with larger granularity? Is that a
> real case or just experimenting? Still we should fix assertion anyway.
>
Yes, it's a real use case. We do support different storage types and
want to allow users to place the fleecing image on a different storage
than the original image for flexibility.
I ran into the issue when backing up to a target with 1 MiB cluster_size
while using a fleecing image on RBD (which has 4 MiB cluster_size by
default).
In theory, I guess I could look into querying the cluster_size of the
backup target and trying to allocate the fleecing image with a small
enough cluster_size. But not sure if that would work on all storage
combinations, and would require teaching our storage plugin API (which
also supports third-party plugins) to perform allocation with a specific
cluster size. So not an ideal solution for us.
> I think:
>
> 1. fix discarding bitmap to make aligning-down (will do that for v3)
>
Thanks!
> 2. if we need another logic for block_copy_calculate_cluster_size() it
> should be an option. May be explicit "copy-cluster-size" or
> "granularity" option for CBW driver and for backup job. And we'll just
> check that given cluster-size is power of two >= target_size.
>
I'll try to implement point 2. That should resolve the issue for our use
case.
Best Regards,
Fiona
next prev parent reply other threads:[~2024-01-26 9:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-17 16:07 [PATCH v2 0/4] backup: discard-source parameter Vladimir Sementsov-Ogievskiy
2024-01-17 16:07 ` [PATCH v2 1/4] block/copy-before-write: fix permission Vladimir Sementsov-Ogievskiy
2024-01-17 16:07 ` [PATCH v2 2/4] block/copy-before-write: create block_copy bitmap in filter node Vladimir Sementsov-Ogievskiy
2024-01-17 16:07 ` [PATCH v2 3/4] qapi: blockdev-backup: add discard-source parameter Vladimir Sementsov-Ogievskiy
2024-01-19 14:46 ` Fiona Ebner
2024-01-25 17:28 ` Vladimir Sementsov-Ogievskiy
2024-01-24 15:03 ` Fiona Ebner
2024-01-25 12:47 ` Fiona Ebner
2024-01-25 17:22 ` Vladimir Sementsov-Ogievskiy
2024-01-26 9:21 ` Fiona Ebner [this message]
2024-01-17 16:07 ` [PATCH v2 4/4] iotests: add backup-discard-source Vladimir Sementsov-Ogievskiy
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=1cec54a7-073c-4dd7-a390-9890bf990720@proxmox.com \
--to=f.ebner@proxmox.com \
--cc=armbru@redhat.com \
--cc=eblake@redhat.com \
--cc=hreitz@redhat.com \
--cc=jsnow@redhat.com \
--cc=kwolf@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=vsementsov@yandex-team.ru \
--cc=wencongyang2@huawei.com \
--cc=xiechanglong.d@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 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 NNTP newsgroup(s).