Hello all,

I am trying to use the "blkreplay" filter to record and replay block I/O
operations. Whenever I get a disk interrupt, I'm planning to replay the
disk operation basically. You can assume that I know when the disk
interrupt happened when we were recording all I/O events.

This is the command line I use to start recording -

./qemu-system-x86_64 -m 1024 --machine pc-i440fx-2.5 -cpu qemu64,-kvmclock
-enable-kvm -network_replay mode=record,file=record9.txt -clock_replay
mode=record,file=clock_record9.txt,host-clock-file=host_clock_record9.txt
-disk_replay mode=record,file=disk_record9.txt -netdev
tap,id=tap1,ifname=tap0,script=no,downscript=no -device
virtio-net-pci,netdev=tap1,mac=00:00:00:00:00:00 -object
filter-replay,id=replay,netdev=tap1 -drive
file=~/os_images_for_qemu/ubuntu-16.04-desktop-amd64.qcow2,format=qcow2,if=none,id=img-direct
*-drive driver=blkreplay,if=none,image=img-direct,id=img-blkreplay -device
virtio-blk-pci,drive=img-direct*

As you can see, I have separate files to record network and disk I/O
events.

I have a need to save the guest state when I do a record. So I created a
snapshot of the guest state by using savevm.

However, when I try to see the list of snapshots, I see that there are 2
snapshots created, one of which is having size = 0.

qemu-img snapshot -l ~/os_images_for_qemu/ubuntu-16.04-desktop-amd64.qcow2
Snapshot list:
ID        TAG                                 VM SIZE        DATE
                      VM CLOCK
1         vm-20210607081725       966 MiB         2021-06-07 08:17:25
00:00:52.539
2         vm-20210607081725           0 B             2021-06-07 08:17:25
00:00:52.539

Does this mean my snapshot might be 'incorrect'? If I load the guest with
the above snapshot, can I be certain the guest will start with the same
disk state? Can I get rid of the extra snapshot that is created here?

Thank you very much for all your help so far.

Best Regards,
Arnabjyoti Kalita

Reply via email to