From: prashant patil <pmgpatil@gmail.com>
To: Eric Blake <eblake@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: Query on the dirty bitmap
Date: Wed, 5 Mar 2025 15:36:35 +0530 [thread overview]
Message-ID: <CAFvsdYk0J7ybdu+dL+w70Po1bGypLopBkixPp-ZzmTA8MdTr0w@mail.gmail.com> (raw)
In-Reply-To: <d2276vugq6wureu6zzrwci5sdtg3b6gllqskjv7hfvuulsmhyn@anl3d5htudty>
[-- Attachment #1: Type: text/plain, Size: 2092 bytes --]
I was trying to read the bitmap of the running vm's disk. When I followed
below mentioned commands, then I was able to read the bitmap properly.
block-dirty-bitmap-add, block-dirty-bitmap-disable, nbd-server-start,
nbd-server-add, qemu-img
map with x-dirty-bitmap image-opts.
Please let me know if there is any other better alternative to do the same.
Thanks
Prashant
On Fri, Feb 28, 2025 at 3:53 AM Eric Blake <eblake@redhat.com> wrote:
> On Wed, Feb 19, 2025 at 04:23:26PM +0530, prashant patil wrote:
> > Hello All,
> > Hope this email finds you well.
> >
> > I have been trying with qemu for a while now, and have come across a
> > problem specific to dirty bitmaps. I have enabled bitmap on the qcow2
> disk
> > image using 'qemu-img bitmap' command, exposed the bitmap over a unix
> > socket using 'qemu-nbd' command. Now when I try to read the bitmap using
> > 'qemu-img map' command with 'x-dirty-bitmap=qemu:dirty-bitmap:{bitmap}'
> > option, I get one single extent which shows that the entire disk is
> dirty.
> > Note that the disk size is 5 GB, and has only a few MB of data in it, and
> > had added very small data after the bitmap was enabled. Bitmap output has
> > been pasted below.
>
> Can you show the exact sequence of command lines you used to create
> the image, dirty a portion of it, then start up the qemu-nbd process
> to inspect it? As written, I can't reproduce your issue, but I know
> it sounds similar to tests/qemu-iotests/tests/qemu-img-bitmaps which
> does what you're talking about, so I know the code works and have to
> suspect you may have missed a step or reordered things in such a way
> that the entire bitmap is reading as dirty.
>
> >
> > [{ "start": 0, "length": 5368709120, "depth": 0, "present": true, "zero":
> > false, "data": true, "compressed": false, "offset": 0}]
> >
> > Can someone please help me understand why the bitmap content shows the
> > entire disk as dirty?
>
> --
> Eric Blake, Principal Software Engineer
> Red Hat, Inc.
> Virtualization: qemu.org | libguestfs.org
>
>
[-- Attachment #2: Type: text/html, Size: 2829 bytes --]
next prev parent reply other threads:[~2025-03-05 10:07 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-19 10:53 Query on the dirty bitmap prashant patil
2025-02-27 22:23 ` Eric Blake
2025-03-05 10:06 ` prashant patil [this message]
2025-03-05 22:14 ` Eric Blake
2025-04-07 9:16 ` prashant patil
2025-04-07 14:53 ` Eric Blake
2025-04-08 11:00 ` prashant patil
2025-04-11 16:04 ` Eric Blake
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=CAFvsdYk0J7ybdu+dL+w70Po1bGypLopBkixPp-ZzmTA8MdTr0w@mail.gmail.com \
--to=pmgpatil@gmail.com \
--cc=eblake@redhat.com \
--cc=qemu-devel@nongnu.org \
/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).