All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel]  snapshot:create snapshot for rbd disk failed.
@ 2018-03-22  3:44 Zhangzijian
  2018-04-03 12:33 ` Stefan Hajnoczi
  0 siblings, 1 reply; 2+ messages in thread
From: Zhangzijian @ 2018-03-22  3:44 UTC (permalink / raw)
  To: qemu-devel

Hello,

In 'bdrv_all_create_snapshot', each block will create snapshot in a for loop. If a domain configured disk mixed with qcow2 and rbd.
In 'qcow2_snapshot_create', sn_info->id_str will be set. But in 'qemu_rbd_snap_create' the 'id_str' is checked. 
On this condition, 'id_str' check will be failed. Since 'id_str' is useless for rbd, why this check is needed, Can it be removed?

#0  qemu_rbd_snap_create (bs=0x55596a51eba0, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/rbd.c:982
#1  0x0000555967fca15e in bdrv_snapshot_create (bs=0x55596a51eba0, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/snapshot.c:171
#2  0x0000555967fca18d in bdrv_snapshot_create (bs=0x55596a518890, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/snapshot.c:174
#3  0x0000555967fcaf43 in bdrv_all_create_snapshot (sn=0x7fff4b0a0d60, vm_state_bs=0x55596a509750, vm_state_size=0, first_bad_bs=0x7fff4b0a0d10)
    at /root/code/qemu_201801/block/snapshot.c:531
#4  0x0000555967ed9362 in save_snapshot (name=0x55596bc37bf0 "snap1", nostate=true, errp=0x7fff4b0a10c0) at /root/code/qemu_201801/migration/savevm.c:2256
#5  0x0000555967ca9ad7 in hmp_savevm (mon=0x7fff4b0a1180, qdict=0x55596af40d60) at /root/code/qemu_201801/hmp.c:1334
#6  0x0000555967b0f034 in handle_hmp_command (mon=0x7fff4b0a1180, cmdline=0x55596b4741e7 "-n snap1") at /root/code/qemu_201801/monitor.c:3110
#7  0x0000555967b0872b in qmp_human_monitor_command (command_line=0x55596b4741e0 "savevm -n snap1", has_cpu_index=false, cpu_index=0, errp=0x7fff4b0a12f0)
    at /root/code/qemu_201801/monitor.c:614


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] snapshot:create  snapshot for rbd disk failed.
  2018-03-22  3:44 [Qemu-devel] snapshot:create snapshot for rbd disk failed Zhangzijian
@ 2018-04-03 12:33 ` Stefan Hajnoczi
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Hajnoczi @ 2018-04-03 12:33 UTC (permalink / raw)
  To: Zhangzijian; +Cc: qemu-devel, Hitoshi Mitake, Liu Yuan, Jeff Cody

[-- Attachment #1: Type: text/plain, Size: 1844 bytes --]

On Thu, Mar 22, 2018 at 03:44:00AM +0000, Zhangzijian wrote:
> Hello,

CCing Sheepdog block driver maintainers.

You can find maintainers for a source file using:

  $ scripts/get_maintainers -f block/sheepdog.c

> 
> In 'bdrv_all_create_snapshot', each block will create snapshot in a for loop. If a domain configured disk mixed with qcow2 and rbd.
> In 'qcow2_snapshot_create', sn_info->id_str will be set. But in 'qemu_rbd_snap_create' the 'id_str' is checked. 
> On this condition, 'id_str' check will be failed. Since 'id_str' is useless for rbd, why this check is needed, Can it be removed?
> 
> #0  qemu_rbd_snap_create (bs=0x55596a51eba0, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/rbd.c:982
> #1  0x0000555967fca15e in bdrv_snapshot_create (bs=0x55596a51eba0, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/snapshot.c:171
> #2  0x0000555967fca18d in bdrv_snapshot_create (bs=0x55596a518890, sn_info=0x7fff4b0a0d60) at /root/code/qemu_201801/block/snapshot.c:174
> #3  0x0000555967fcaf43 in bdrv_all_create_snapshot (sn=0x7fff4b0a0d60, vm_state_bs=0x55596a509750, vm_state_size=0, first_bad_bs=0x7fff4b0a0d10)
>     at /root/code/qemu_201801/block/snapshot.c:531
> #4  0x0000555967ed9362 in save_snapshot (name=0x55596bc37bf0 "snap1", nostate=true, errp=0x7fff4b0a10c0) at /root/code/qemu_201801/migration/savevm.c:2256
> #5  0x0000555967ca9ad7 in hmp_savevm (mon=0x7fff4b0a1180, qdict=0x55596af40d60) at /root/code/qemu_201801/hmp.c:1334
> #6  0x0000555967b0f034 in handle_hmp_command (mon=0x7fff4b0a1180, cmdline=0x55596b4741e7 "-n snap1") at /root/code/qemu_201801/monitor.c:3110
> #7  0x0000555967b0872b in qmp_human_monitor_command (command_line=0x55596b4741e0 "savevm -n snap1", has_cpu_index=false, cpu_index=0, errp=0x7fff4b0a12f0)
>     at /root/code/qemu_201801/monitor.c:614
> 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-04-03 12:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-22  3:44 [Qemu-devel] snapshot:create snapshot for rbd disk failed Zhangzijian
2018-04-03 12:33 ` Stefan Hajnoczi

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.