[Users] Related to extend disk size of existing virtual machine !

Michael Pasternak mpastern at redhat.com
Wed Nov 21 08:25:30 UTC 2012


On 11/21/2012 08:19 AM, Romil Gupta wrote:
> Hello,
> 
> To add a disk to VM we use the following :
> 
> api.vms.get(VM_NAME).disks.add(params.Disk(storage_domains=params.StorageDomains(storage_domain=[api.storagedomains.get(STORAGE_NAME)]),
>                                                    size=512*MB,
>                                                    # type_='system', - disk type is deprecated
>                                                    status=None,
>                                                    interface='virtio',
>                                                    format='cow',
>                                                    sparse=True,
>                                                    bootable=True))
> 
> but the type_ attribute is deprecated , so I got the following exception :
> 
> Failed to add disk
> 
> status: 400
> reason: Bad Request
> detail: Cannot add Virtual Machine Disk. Disk 1 already marked as system
> 
> Now , if I try giving disk_type='Data' on GUI of RHEVM  then it will be added to VM.
> 
> 
> I want to know from which ovirt-sdk version you have deprecated attribute disk_type ?
> 
> I am currently using  ovirt-engine-sdk-3.1.0.3-1.el6.noarch.rpm  and I didn't find type_ attribute using this rpm !

deprecated != removed, we had a bug in version that you're using, it was fixed
in one of the following releases, please upgrade to latest sdk.

> 
> How I can extend the disk size of a existing VM in RHEVM ?
> 
> Help me !
> 
> 
> 
> 
> Regards ,
> Romil Gupta
> 
> 


-- 

Michael Pasternak
RedHat, ENG-Virtualization R&D



More information about the Users mailing list