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

Re: [libvirt] [PATCH v3 4/7] qemu: Translate the iscsi pool/volume disk source



Il 22/07/2013 12:30, Osier Yang ha scritto:
> +        def->srcpool->pooltype = pooldef->type;
> +        if (pooldef->type == VIR_STORAGE_POOL_ISCSI) {
> +            /* Default to use the LUN's path on host */
> +            if (!def->srcpool->mode)
> +                def->srcpool->mode =
> VIR_DOMAIN_DISK_SOURCE_POOL_MODE_HOST;
> +
> +            if (def->srcpool->mode ==
> +                VIR_DOMAIN_DISK_SOURCE_POOL_MODE_DIRECT) {
> +                if (qemuAddISCSIPoolSourceHost(def, pooldef) < 0)
> +                    goto cleanup;
> +            } else if (def->srcpool->mode ==
> +                       VIR_DOMAIN_DISK_SOURCE_POOL_MODE_HOST) {
> +                if (!(def->src = virStorageVolGetPath(vol)))
> +                    goto cleanup;
> +            }

Ok, this answers my question. :)

I think the default mode should be direct, because otherwise things such
as persistent reservations do not work.

Paolo


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