[pve-devel] [PATCH] Implement pending change

Alexandre DERUMIER aderumier at odiso.com
Mon Oct 27 14:02:37 CET 2014


>>[CONF]
>>virtio0: local:100/vm-100-disk-1.qcow2
>>[PENDING]
>>virtio0: local:100/vm-100-disk-2.qcow2
>>
>>> So, what happen here ? I lost the reference of previous disk, and I will delete the
>>> new disk on pending commit.
>>
>>See my example - I do not lose any reference.

Ok, I got it. 

so, to apply the pending conf

qm set 100 -virtio0 local:100/vm-100-disk-2.qcow2

that should give us

[CONF]
virtio0: local:100/vm-100-disk-2.qcow2
unused0: local:100/vm-100-disk-1.qcow2



----- Mail original ----- 

De: "Dietmar Maurer" <dietmar at proxmox.com> 
À: "Alexandre DERUMIER" <aderumier at odiso.com> 
Cc: pve-devel at pve.proxmox.com 
Envoyé: Lundi 27 Octobre 2014 12:43:37 
Objet: RE: [pve-devel] [PATCH] Implement pending change 

> >>Or what is the advantage to allocate immediately? 
> 
> Because we can do hotplug. 
> So I create the disk, put in pending. 
> Then if hotplug fail, we keep the device in pending. 
> 
> (I could even be possible to always enable hotplug by default with this method) 

OK 

> >>And why do you want to maintain a list of unused disks inside [PENDING]? 
> 
> because we can delete and add a new disk on same id. (or swap it) If I don't 
> maintain a list of unused disk and use delete: 
> 
> 
> [CONF] 
> virtio0 

[CONF] 
virtio0: local:100/vm-100-disk-1.qcow2 

> 
> -delete the disk 
> 
> [CONF] 
> virtio0 
> [PENDING] 
> delete : virtio0 

[CONF] 
virtio0: local:100/vm-100-disk-1.qcow2 
[PENDING] 
delete : virtio0 

> now add a new disk on virtio0 
> 
> [CONF] 
> virtio0: new disk 
> [PENDING] 
> delete: virtio0 

[CONF] 
virtio0: local:100/vm-100-disk-1.qcow2 
[PENDING] 
virtio0: local:100/vm-100-disk-2.qcow2 

> So, what happen here ? I lost the reference of previous disk, and I will delete the 
> new disk on pending commit. 

See my example - I do not lose any reference. 



More information about the pve-devel mailing list