<div dir="ltr"><div><div>Hi<br><br></div>a small update on this. I just migrated the vm
 from the site to my laptop and fired it up. The exact same xml 
configuration (except file paths and such) starts up and bursts with 
50Mb/s to 115Mb/s in the guest. This allows only one reasonable answer: 
the cpu on my laptop is somehow better suited to emulate IO than the CPU
 built into the host on site. The host there is a HP proliant 
microserver gen8 with xeon processor. But the processor there is also 
never capped at 100% when the guest copies files.<br><br>I just ran 
another test by copying a 3Gb large file on the guest. What I can 
observe on my computer is that the copy process is not at a constant 
rate but rather starts with 90Mb/s, then drops down to 30Mb/s, goes up 
to 70Mb/s, drops down to 1Mb/s, goes up to 75Mb/s, drops to 1Mb/s, goes 
up to 55Mb/s and the pattern continues. Please note that the drive is 
still configured as:<br><br><driver name='qemu' type='qcow2' cache='none' io='threads'/><br><br></div>and
 I would expect a constant rate that is either high or low since there 
is no caching involved and the underlying hard drive is a samsung ssd 
evo 850. To have an idea how fast that drive is on my laptop:<br><br>$ dd if=/dev/zero of=testfile bs=1M count=1000 oflag=direct<br>1000+0 records in<br>1000+0 records out<br>1048576000 bytes (1.0 GB, 1000 MiB) copied, 2.47301 s, 424 MB/s<br><div><br></div><div>I can further observe that the smaller the saved chunks are the slower the overall performance is:<br><br>dd if=/dev/zero of=testfile bs=512K count=1000 oflag=direct<br>1000+0 records in<br>1000+0 records out<br>524288000 bytes (524 MB, 500 MiB) copied, 1.34874 s, 389 MB/s<br><br>$ dd if=/dev/zero of=testfile bs=5K count=1000 oflag=direct<br>1000+0 records in<br>1000+0 records out<br>5120000 bytes (5.1 MB, 4.9 MiB) copied, 0.105109 s, 48.7 MB/s<br><br>$ dd if=/dev/zero of=testfile bs=1K count=10000 oflag=direct<br>10000+0 records in<br>10000+0 records out<br>10240000 bytes (10 MB, 9.8 MiB) copied, 0.668438 s, 15.3 MB/s<br><br>$ dd if=/dev/zero of=testfile bs=512 count=20000 oflag=direct<br>20000+0 records in<br>20000+0 records out<br>10240000 bytes (10 MB, 9.8 MiB) copied, 1.10964 s, 9.2 MB/s<br><br></div><div>Could this be a limiting factor? Does qemu/kvm do many many writes of just a few bytes?<br></div><div><br>Ideas, anyone?<br><br></div>Cheers</div><div class="gmail_extra"><br><div class="gmail_quote">2017-06-21 20:46 GMT+02:00 Dan <span dir="ltr"><<a href="mailto:srwx4096@gmail.com" target="_blank">srwx4096@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tue, Jun 20, 2017 at 04:24:32PM +0200, Gianluca Cecchi wrote:<br>
> On Tue, Jun 20, 2017 at 3:38 PM, Dominik Psenner <<a href="mailto:dpsenner@gmail.com">dpsenner@gmail.com</a>> wrote:<br>
><br>
> ><br>
> > to the following:<br>
> ><br>
> > <disk type='file' device='disk'><br>
> >   <driver name='qemu' type='qcow2' cache='none'/><br>
> >   <source file='/var/data/virtuals/<wbr>machines/windows-server-2016-<br>
> > x64/image.qcow2'/><br>
> >   <backingStore/><br>
> >   <target dev='hda' bus='scsi'/><br>
> >   <address type='drive' controller='0' bus='0' target='0' unit='0'/><br>
> > </disk><br>
> ><br>
> > Do you see any gotchas in this configuration that could prevent the<br>
> > virtualized guest to power on and boot up?<br>
> ><br>
> ><br>
> When I configure like this, from a linux guest point of view I get this<br>
> Symbios Logic SCSI Controller:<br>
> 00:08.0 SCSI storage controller: LSI Logic / Symbios Logic 53c895a<br>
><br>
> But htis is true only if you add the SCSI controller too, not only the disk<br>
> definition.<br>
> In my case<br>
><br>
>     <controller type='scsi' index='0'><br>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x08'<br>
> function='0x0'/><br>
>     </controller><br>
><br>
> Note the slot='0x08' that is reflected into the first field of lspci inside<br>
> my linux guest.<br>
> So between your controllers you have to add the SCSI one<br>
><br>
> In my case (Fedora 25 with virt-manager-1.4.1-2.fc25.<wbr>noarch,<br>
> qemu-kvm-2.7.1-6.fc25.x86_64, libvirt-2.2.1-2.fc25.x86_64) with "Disk bus"<br>
> set as SCSI in virt-manager, the xml defintiion for the guest is<br>
> automatically updated with the controller if not existent yet.<br>
> And the disk definition sections is like this:<br>
><br>
>     <disk type='file' device='disk'><br>
>       <driver name='qemu' type='qcow2'/><br>
>       <source file='/var/lib/libvirt/images/<wbr>slaxsmall.qcow2'/><br>
>       <target dev='sda' bus='scsi'/><br>
>       <boot order='1'/><br>
>       <address type='drive' controller='0' bus='0' target='0' unit='0'/><br>
>     </disk><br>
><br>
> So I think you should set dev='sda' and not 'hda' in your xml for it<br>
><br>
</div></div>I am actually very curious to know if that would make a difference. I<br>
don't have a such windows vm images ready to test at present.<br>
<span class="HOEnZb"><font color="#888888"><br>
Dan<br>
</font></span><span class="im HOEnZb">> I don't kknow if w2016 contains the symbios logic drivers already<br>
> installed, so that a "simple" reboot could imply an automatic<br>
> reconfiguration of the guest....<br>
> Note also that in Windows when the hw configuration is considered heavily<br>
> changed, you could be asked to register again (I don't think that the IDE<br>
> --> SCSI should imply it...)<br>
><br>
> Gianluca<br>
<br>
</span><div class="HOEnZb"><div class="h5">> ______________________________<wbr>_________________<br>
> libvirt-users mailing list<br>
> <a href="mailto:libvirt-users@redhat.com">libvirt-users@redhat.com</a><br>
> <a href="https://www.redhat.com/mailman/listinfo/libvirt-users" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/libvirt-users</a><br>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Dominik Psenner<br></div></div>
</div>