* Re: [Qemu-devel] qemu-nbd
[not found] <CAGhAadf5A=t=0CM6bC3LaUf-53NV8PynHgQ2A5_UtL+hE5eZUg@mail.gmail.com>
@ 2018-03-26 18:14 ` Max Reitz
0 siblings, 0 replies; only message in thread
From: Max Reitz @ 2018-03-26 18:14 UTC (permalink / raw)
To: Pascal, nbd, qemu-devel@nongnu.org, Qemu-block
[-- Attachment #1: Type: text/plain, Size: 776 bytes --]
On 2018-03-22 13:17, Pascal wrote:
> hi everybody,
>
> when I use `qemu-nbd -s -c /dev/nbd0 /dev/sda` where are changes to
> /dev/ndb0 saved ?
> I searched in /proc/{pid_of_qemu-nbd}/ but found nothing there...
In snapshot mode, qemu (or in this case qemu-nbd) creates a temporary
qcow2 file in $TMPDIR (or /var/tmp) which will get the changes. You
should see a link to that file in /proc/$pid/fd, like this:
lrwx------. [...] 10 -> /var/tmp/vl.JjYLDm (deleted)
As you can see, the file is deleted right after it is opened, though.
If you want to have control over where the data is stored, you can just
create the overlay yourself, like so:
$ qemu-img create -f qcow2 -b /dev/sda -F raw overlay.qcow2
$ qemu-nbd -c /dev/nbd0 overlay.qcow2
Max
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 512 bytes --]
^ permalink raw reply [flat|nested] only message in thread