parallels: commit with PVCF_DETACH_HDD_BUNDLE flag

PCS removes disk image from filesystem, if you remove it
from config. There is a special flag PVCF_DETACH_HDD_BUNDLE
which allow to remove disk only from VM/CT config.

If you call virDomainDefine and remove some disk from
config it should be preserved, so call PrlVm_CommitEx
always with flag PVCF_DETACH_HDD_BUNDLE.

Signed-off-by: Dmitry Guryanov <dguryanov@parallels.com>
This commit is contained in:
Dmitry Guryanov 2015-01-13 14:27:38 +03:00 committed by Michal Privoznik
parent 4bbd3b1e7e
commit d86f2aa336

View File

@ -2745,7 +2745,7 @@ prlsdkApplyConfig(virConnectPtr conn,
ret = prlsdkDoApplyConfig(sdkdom, new);
if (ret == 0) {
job = PrlVm_Commit(sdkdom);
job = PrlVm_CommitEx(sdkdom, PVCF_DETACH_HDD_BUNDLE);
if (PRL_FAILED(waitJob(job, privconn->jobTimeout)))
ret = -1;
}