<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Mon, Mar 26, 2018 at 1:03 PM Richard W.M. Jones <<a href="mailto:rjones@redhat.com">rjones@redhat.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Mon, Mar 26, 2018 at 09:27:25AM +0000, Daniel Erez wrote:<br>
> You can get it from '.storage.type' on the StorageDomain object.<br>
> E.g.<br>
> sd = connection.system_service().storage_domains_service().list()[0]<br>
> sd.storage.type -> nfs/iscsi/etc<br>
<br>
Is there a defined set of what can be returned, and/or a way<br>
to find out if the storage is "block-like" or not?<br></blockquote><div><br></div><div>Yes, the list is defined by the StorageType enum (file/block sub-type is also specified):</div><div><a href="https://raw.githubusercontent.com/oVirt/ovirt-engine/master/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/storage/StorageType.java">https://raw.githubusercontent.com/oVirt/ovirt-engine/master/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/storage/StorageType.java</a></div><div>I don't see we expose it through the sdk though.</div><div> <br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Alternately what happens if we don't specify the sparse flag at all?</blockquote><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Will it do the right thing? </blockquote><div><br></div><div><div>If not specified, the volume type should fallback to its default value, which is thin.</div><div>So it's depended on your use-case...</div></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Rich.<br>
<br>
--<br>
Richard Jones, Virtualization Group, Red Hat <a href="http://people.redhat.com/~rjones" rel="noreferrer" target="_blank">http://people.redhat.com/~rjones</a><br>
Read my programming and virtualization blog: <a href="http://rwmj.wordpress.com" rel="noreferrer" target="_blank">http://rwmj.wordpress.com</a><br>
virt-df lists disk usage of guests without needing to install any<br>
software inside the virtual machine.  Supports Linux and Windows.<br>
<a href="http://people.redhat.com/~rjones/virt-df/" rel="noreferrer" target="_blank">http://people.redhat.com/~rjones/virt-df/</a><br>
</blockquote></div></div>