Re: [libvirt] [PATCH v2 4/5] Implement virDomainMigrateSetMaxDowntime in qemu driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> > +int qemuMonitorJSONSetMigrationDowntime(qemuMonitorPtr mon,
> > +                                        unsigned long long downtime)
> > +{
> > +    int ret;
> > +    char *downtimestr;
> > +    virJSONValuePtr cmd;
> > +    virJSONValuePtr reply = NULL;
> > +    if (virAsprintf(&downtimestr, "%llun", downtime) < 0) {
> 
> 
>   Hum, just wondering, QEmu interface really takes nanoseconds as its
> input or shouldn't that be scaled down ? And in case we forgot to scale
> down, we need to be very careful if the division leads to 0, assuming
> 
> migrate_set_downtime 0
> 
> may mean something completely different from what we asked .
> 
>   Can you confirm QEmu uses nanoseconds input ?

Oh crap... I did a mistake here and in text monitor code. QEmu accepts
floating-point seconds with possible "ms", "us", or "ns" suffix for milli-,
micro-, or nanoseconds. So yes, it accepts nanoseconds, although I should have
used "ns" instead of "n" suffix. I'm wondering how it could ever worked as
QEmu is supposed to complain about unknown unit suffix.

Jirka

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]