[Users] Progress on image operations (dd & USR1 signal)
Ayal Baron
abaron at redhat.com
Sun Mar 17 10:54:43 EDT 2013
----- Original Message -----
> Hi, I am using ovirt 3.2 and noticed that during image operations
> (move,
> copy)
> the user has no progress report. This is painful, especially if the
> images are large
> or the storage is slow.
>
> Vdsm uses 'dd' to transfer images and dd provides a simple progress
> report, when
> it receives the USR1 signal. Could this be uses to provide the user
> with
> some kind
> of progress?
Actually image operations many times occur with qemu-img command so a solution for dd alone would not suffice, however, this is exactly the reason why we got the qemu folks to add -USR1 support for qemu-img. So this is in general the plan.
Unfortunately today as you said we do not yet support progress report for these operations.
If you feel like jumping into the code, we'd be more than happy to help you understand where changes need to be made (although I'm not sure this specific change would be trivial).
>
> Right now i would do it with myself with strace and kill, but
> ovirt/vdsm
> detects an
> stderr output and reports a failure.
Actually it only detects a non zero return code, it shouldn't fail on retcode = 0 even if stderr is nonzero (if you're interested look at execCmd in vdsm/storage/misc.py).
What is the retcode of dd if USR1 is called? if it's none zero then I would say this is a bug in dd, if it is zero then it sounds like either something else is going on or that there is a bug in vdsm.
You can see the retcode in the vdsm.log together with the stdout and stderr, can you paste those after calling -USR1?
>
> $ strace -ff -etrace=write -p `pidof dd` 2>&1 | grep -v 'write(1'
>
> # then, in a second terminal I send the signal
> $ killall -USR1 dd
>
> Process 8706 attached - interrupt to quit
> --- SIGUSR1 (User defined signal 1) @ 0 (0) ---
> write(2, "14022+0 records in\n14021+0 recor"..., 39) = 39
> write(2, "14702084096 bytes (15 GB) copied", 32) = 32
> write(2, ", 2189.75 s, 6.7 MB/s\n", 22) = 22
>
> --
> Ernest Beinrohr, AXON PRO
> Ing <http://www.beinrohr.sk/ing.php>, RHCE
> <http://www.beinrohr.sk/rhce.php>, RHCVA
> <http://www.beinrohr.sk/rhce.php>, LPIC
> <http://www.beinrohr.sk/lpic.php>, +421-2--6241-0360
> <callto://+421-2--6241-0360>, +421-903--482-603
> <callto://+421-903--482-603>
> icq:28153343, skype:oernii-work <callto://oernii-work>,
> jabber:oernii at jabber.org
> ------------------------------------------------------------------------
> “The bureaucracy is expanding to meet the needs of the expanding
> bureaucracy.” ― Oscar Wilde
> _______________________________________________
> Users mailing list
> Users at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users
>
More information about the Users
mailing list