Re: [ovirt-users] Unable to rename disks via REST API

2017-06-30 Thread Bruno Rodriguez
Finally I was able to rename the disks, the problem was about handling that put request and my inability to check libcurl documentation (I was treating the XML I was sending as a string instead of a file). Sorry because I needed this script to be working as fast as I could, so I didn't try to

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Juan Hernández
On 06/28/2017 01:34 PM, Bruno Rodriguez wrote: > Shit, I got it. Sorry > > The problem is that I was accessing to the v4 disk-attachment id and I > was getting everything quite messed up. I was doing all of this while > creating a machine, so I was trying to rename the disk at the same time >

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Bruno Rodriguez
Shit, I got it. Sorry The problem is that I was accessing to the v4 disk-attachment id and I was getting everything quite messed up. I was doing all of this while creating a machine, so I was trying to rename the disk at the same time it's being created. I'll delete all the "if ($ovirt_major ==

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Juan Hernández
On 06/28/2017 12:55 PM, Bruno Rodriguez wrote: > I'm sorry about bothering you again, but after trying it some times I'm > still getting a "500 Internal Server Error". I'm using a REST client > instead of CURL and I tried adding a "Version: 3" to headers and used > the URL with the v3 as well. >

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Bruno Rodriguez
I'm sorry about bothering you again, but after trying it some times I'm still getting a "500 Internal Server Error". I'm using a REST client instead of CURL and I tried adding a "Version: 3" to headers and used the URL with the v3 as well. I'm issuing a PUT of Alias_for_disk To the URL

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Bruno Rodriguez
Thank you very much !!! I expected I was missing something like that. Thanks again! On Wed, Jun 28, 2017 at 11:12 AM, Juan Hernández wrote: > On 06/28/2017 10:43 AM, Bruno Rodriguez wrote: > > Thank you, Daniel > > > > I tried a PUT with the same XML body, I got a "405

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Juan Hernández
On 06/28/2017 10:43 AM, Bruno Rodriguez wrote: > Thank you, Daniel > > I tried a PUT with the same XML body, I got a "405 Method Not Allowed". > It's quite strange, there must be someting I'm missing > The operation to update a disk will be introduced in version 4 of the API with version 4.2 of

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Bruno Rodriguez
Thank you, Daniel I tried a PUT with the same XML body, I got a "405 Method Not Allowed". It's quite strange, there must be someting I'm missing On Wed, Jun 28, 2017 at 10:07 AM, Daniel Erez wrote: > Hi, > > Updating is done using the PUT method. > Please try that with the

Re: [ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Daniel Erez
Hi, Updating is done using the PUT method. Please try that with the same XML body. Thanks, Daniel On Wed, Jun 28, 2017 at 10:26 AM Bruno Rodriguez wrote: > Hello everyone, > > I'm having some problems about renaming some disks (setting a different > alias, name or description)

[ovirt-users] Unable to rename disks via REST API

2017-06-28 Thread Bruno Rodriguez
Hello everyone, I'm having some problems about renaming some disks (setting a different alias, name or description) for VMs disks created from a template. When I get this URL https://ovirt-manager/ovirt-engine/api/disks/0123 I can see are the methods sparsify, export, move and copy. I tried to