[pve-devel] [PATCH 1/6] vm_deviceplug|unplug : implement pending change

Alexandre DERUMIER aderumier at odiso.com
Tue Nov 18 12:47:33 CET 2014


>># qm set 100 -tablet 1 
>>update VM 100: -tablet 1 
>>VM 100 qmp command 'device_add' failed - Duplicate ID 'tablet' for device 
>>
>>Does that work for you? 

Strange, I had put an eval for this specific qmp command to avoid this.
(I case of tablet is already plugged).

I think I can improve it with query-mice qmp, to check if the tablet already before try to hotplug it again.



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

De: "Dietmar Maurer" <dietmar at proxmox.com> 
À: "Alexandre DERUMIER" <aderumier at odiso.com> 
Cc: pve-devel at pve.proxmox.com 
Envoyé: Mardi 18 Novembre 2014 12:40:19 
Objet: RE: [pve-devel] [PATCH 1/6] vm_deviceplug|unplug : implement pending change 

> >>if (vm_deviceplug(...)) { 
> >>$conf->{$deviceid} = $optvalue; 
> >>delete $conf->{pending}->{$deviceid}; 
> >>PVE::QemuServer::update_config_nolock($vmid, $conf, 1); } 
> 
> >>(we can also make an extra sub for that) 
> 
> 
> So, Yes, we can do like this. 
> 
> I'll make a patch 

I also get this error : 

# qm set 100 -tablet 1 
update VM 100: -tablet 1 
VM 100 qmp command 'device_add' failed - Duplicate ID 'tablet' for device 

Does that work for you? 



More information about the pve-devel mailing list