oVirt-shell command to move a disk

Hello, I'm confused because though I'm using ovirt-shell to script many actions every day, and even after a large bunch of reading and testing, I can not find the correct syntax to move (offline/available) disks between storage domains. May you help me please? (oVirt 3.4.4) -- Nicolas Ecarnot

------=_Part_2620081_1134578422.1417356067706 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Hi Nicolas, In oVit you can find /Disks under several locations /api/disks/api/vms/{vm:id}/disks/api/templates/{template:id}/disks/api/vms/{vm:id}/snapshots/{snapshot:id}/disks to move disk to a different domain, you have to use first one,e.g disk with no context [1], on ovirt-shell language it will look like [2]. [1] /disks/{disk:id}/move[2] action disk {disk:id} move -- storagedomain-name|--storagedomain-id [--action-async true] ...(use help/auto-completion to see command details/verbs) On Saturday, November 29, 2014 12:56 AM, Nicolas Ecarnot <nicolas@ecarnot.net> wrote: Hello, I'm confused because though I'm using ovirt-shell to script many actions every day, and even after a large bunch of reading and testing, I can not find the correct syntax to move (offline/available) disks between storage domains. May you help me please? (oVirt 3.4.4) -- Nicolas Ecarnot _______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users ------=_Part_2620081_1134578422.1417356067706 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div style=3D"color:#000; background-color:#fff; font-family:HelveticaNeue-= Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grand= e, sans-serif;font-size:16px"><div id=3D"yui_3_16_0_1_1417354182518_10880">= Hi Nicolas,</div><div id=3D"yui_3_16_0_1_1417354182518_10879"><br></div><di= v dir=3D"ltr" id=3D"yui_3_16_0_1_1417354182518_10878">In oVit you can find = /Disks under several locations</div><div id=3D"yui_3_16_0_1_1417354182518_1= 0883" dir=3D"ltr"><br></div><div id=3D"yui_3_16_0_1_1417354182518_10884" di= r=3D"ltr">/api/disks</div><div id=3D"yui_3_16_0_1_1417354182518_10885" dir= =3D"ltr">/api/vms/{vm:id}/disks</div><div id=3D"yui_3_16_0_1_1417354182518_= 10901" dir=3D"ltr">/api/templates/{template:id}/disks</div><div id=3D"yui_3= _16_0_1_1417354182518_10886" dir=3D"ltr">/api/vms/{vm:id}/snapshots/{snapsh= ot:id}/disks</div><div id=3D"yui_3_16_0_1_1417354182518_10887" dir=3D"ltr">= <br></div><div id=3D"yui_3_16_0_1_1417354182518_10897" dir=3D"ltr">to move = disk to a different domain, you have to use first one,</div><div id=3D"yui_= 3_16_0_1_1417354182518_10896" dir=3D"ltr">e.g disk with no context [1], on = ovirt-shell language it will look like [2].<br></div><div id=3D"yui_3_16_0_= 1_1417354182518_10900" dir=3D"ltr"><br></div><div id=3D"yui_3_16_0_1_141735= 4182518_10903" dir=3D"ltr">[1] /disks/{disk:id}/move</div><div id=3D"yui_3_= 16_0_1_1417354182518_10914" dir=3D"ltr">[2] action disk {disk:id} move -- s= toragedomain-name|--storagedomain-id [--action-async true] ...</div><div id= =3D"yui_3_16_0_1_1417354182518_11329" dir=3D"ltr">(use help/auto-completion= to see command details/verbs)<br></div><div id=3D"yui_3_16_0_1_14173541825= 18_10877"><span></span></div> <div class=3D"qtdSeparateBR"><br><br></div><d= iv style=3D"display: block;" class=3D"yahoo_quoted"> <div style=3D"font-fam= ily: HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, = Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div style=3D"font-fam= ily: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-s= erif; font-size: 16px;"> <div dir=3D"ltr"> <font face=3D"Arial" size=3D"2">= On Saturday, November 29, 2014 12:56 AM, Nicolas Ecarnot <nicolas@ecarn= ot.net> wrote:<br> </font> </div> <br><br> <div class=3D"y_msg_containe= r">Hello,<br><br>I'm confused because though I'm using ovirt-shell to scrip= t many actions <br>every day, and even after a large bunch of reading and t= esting, I can <br>not find the correct syntax to move (offline/available) d= isks between <br>storage domains.<br><br>May you help me please?<br><br>(oV= irt 3.4.4)<br><br>-- <br>Nicolas Ecarnot<br>_______________________________= ________________<br>Users mailing list<br><a ymailto=3D"mailto:Users@ovirt.= org" href=3D"mailto:Users@ovirt.org">Users@ovirt.org</a><br><a href=3D"http= ://lists.ovirt.org/mailman/listinfo/users" target=3D"_blank">http://lists.o= virt.org/mailman/listinfo/users</a><br><br><br></div> </div> </div> </div=
</div> ------=_Part_2620081_1134578422.1417356067706--

Le 30/11/2014 15:01, Michael Pasternak a écrit :
Hi Nicolas,
In oVit you can find /Disks under several locations
/api/disks /api/vms/{vm:id}/disks /api/templates/{template:id}/disks /api/vms/{vm:id}/snapshots/{snapshot:id}/disks
to move disk to a different domain, you have to use first one, e.g disk with no context [1], on ovirt-shell language it will look like [2].
[1] /disks/{disk:id}/move [2] action disk {disk:id} move -- storagedomain-name|--storagedomain-id [--action-async true] ... (use help/auto-completion to see command details/verbs)
Hi Mickael, Thank you for your reply, but here is what I get : [oVirt shell (connected)]# action disk serv-fs-int1_Disk1 move --storagedomain-name data-vm-adm8 ============================================================================ UNKNOWN ERROR ========================================================================= get() got an unexpected keyword argument 'name' ==================================================================================================================================================================== I get the same when using the id instead of the names. -- Nicolas Ecarnot

------=_Part_3077749_930899498.1417428474173 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable make sure you using latest sdk & cli, what is it btw? (run 'info' command) =20 On Sunday, November 30, 2014 7:48 PM, Nicolas Ecarnot <nicolas@ecarnot= .net> wrote: =20 Le 30/11/2014 15:01, Michael Pasternak a =C3=A9crit :
Hi Nicolas,
In oVit you can find /Disks under several locations
/api/disks /api/vms/{vm:id}/disks /api/templates/{template:id}/disks /api/vms/{vm:id}/snapshots/{snapshot:id}/disks
to move disk to a different domain, you have to use first one, e.g disk with no context [1], on ovirt-shell language it will look like [= 2].
[1] /disks/{disk:id}/move [2] action disk {disk:id} move -- storagedomain-name|--storagedomain-id [--action-async true] ... (use help/auto-completion to see command details/verbs)
Hi Mickael, Thank you for your reply, but here is what I get : [oVirt shell (connected)]# action disk serv-fs-int1_Disk1 move=20 --storagedomain-name data-vm-adm8 =20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=20 UNKNOWN ERROR=20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 get()= got=20 an unexpected keyword argument 'name' =20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D I get the same when using the id instead of the names. --=20 Nicolas Ecarnot ------=_Part_3077749_930899498.1417428474173 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div style=3D"color:#000; background-color:#fff; font-family:HelveticaNeue-= Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grand= e, sans-serif;font-size:16px"><div dir=3D"ltr" id=3D"yui_3_16_0_1_141735418= 2518_85012">make sure you using latest sdk & cli, what is it btw? (run = 'info' command)<br></div><div id=3D"yui_3_16_0_1_1417354182518_85011"><br><= /div><div id=3D"yui_3_16_0_1_1417354182518_84266"><span></span></div> <div = class=3D"qtdSeparateBR"><br><br></div><div style=3D"display: block;" class= =3D"yahoo_quoted"> <div style=3D"font-family: HelveticaNeue-Light, Helvetic= a Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; = font-size: 16px;"> <div style=3D"font-family: HelveticaNeue, Helvetica Neue= , Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir= =3D"ltr"> <font face=3D"Arial" size=3D"2"> On Sunday, November 30, 2014 7:4= 8 PM, Nicolas Ecarnot <nicolas@ecarnot.net> wrote:<br> </font> </div>= <br><br> <div class=3D"y_msg_container">Le 30/11/2014 15:01, Michael Past= ernak a =C3=A9crit :<br clear=3D"none">> Hi Nicolas,<br clear=3D"none">&= gt;<br clear=3D"none">> In oVit you can find /Disks under several locati= ons<br clear=3D"none">><br clear=3D"none">> /api/disks<br clear=3D"no= ne">> /api/vms/{vm:id}/disks<br clear=3D"none">> /api/templates/{temp= late:id}/disks<br clear=3D"none">> /api/vms/{vm:id}/snapshots/{snapshot:= id}/disks<br clear=3D"none">><br clear=3D"none">> to move disk to a d= ifferent domain, you have to use first one,<br clear=3D"none">> e.g disk= with no context [1], on ovirt-shell language it will look like [2].<br cle= ar=3D"none">><br clear=3D"none">> [1] /disks/{disk:id}/move<br clear= =3D"none">> [2] action disk {disk:id} move -- storagedomain-name|--stora= gedomain-id<br clear=3D"none">> [--action-async true] ...<br clear=3D"no= ne">> (use help/auto-completion to see command details/verbs)<br clear= =3D"none"><br clear=3D"none">Hi Mickael,<br clear=3D"none"><br clear=3D"non= e">Thank you for your reply, but here is what I get :<br clear=3D"none"><br= clear=3D"none">[oVirt shell (connected)]# action disk serv-fs-int1_Disk1 m= ove <br clear=3D"none">--storagedomain-name data-vm-adm8<br clear=3D"none">= <br clear=3D"none">=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D <br clear=3D"none">UNKNOWN ERROR <br clear=3D"none= ">=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D<br= clear=3D"none"> &nb= sp; &= nbsp; = get() got <br clear=3D"none">an unexpected keyword argument 'name'<= br clear=3D"none"> <br clear=3D"none">=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D<br clear=3D"none"><br clear=3D"none">I get the same when using the i= d instead of the names.<div class=3D"yqt0602482900" id=3D"yqtfd39894"><br c= lear=3D"none"><br clear=3D"none">-- <br clear=3D"none">Nicolas Ecarnot<br c= lear=3D"none"></div><br><br></div> </div> </div> </div> </div> ------=_Part_3077749_930899498.1417428474173--

Le 01/12/2014 11:07, Michael Pasternak a écrit :
make sure you using latest sdk & cli, what is it btw? (run 'info' command)
[oVirt shell (connected)]# info backend version: 3.4 sdk version : 3.4.4 cli version : 3.4.0.5 python version : 2.6.6.final.0 I think I run the version that is installed according to the global oVirt version ecosystem - quite the same packages versions around 3.4.4.
[oVirt shell (connected)]# action disk serv-fs-int1_Disk1 move --storagedomain-name data-vm-adm8
============================================================================
UNKNOWN ERROR ========================================================================= get() got an unexpected keyword argument 'name'
-- Nicolas Ecarnot

------=_Part_3124281_1833167183.1417434665641 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable not sure what sdk version 3.4.4 is, but according to log, latest official f= or 3.4 is 3.4.1.1-1(make you have it installed) =20 On Monday, December 1, 2014 12:10 PM, Nicolas Ecarnot <nicolas@ecarnot= .net> wrote: =20 Le 01/12/2014 11:07, Michael Pasternak a =C3=A9crit :
make sure you using latest sdk & cli, what is it btw? (run 'info' command= )
[oVirt shell (connected)]# info backend version: 3.4 sdk version=C2=A0 =C2=A0 : 3.4.4 cli version=C2=A0 =C2=A0 : 3.4.0.5 python version : 2.6.6.final.0 I think I run the version that is installed according to the global=20 oVirt version ecosystem - quite the same packages versions around 3.4.4.
[oVirt shell (connected)]# action disk serv-fs-int1_Disk1 move --storagedomain-name data-vm-adm8
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D
UNKNOWN ERROR =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 get() got an unexpected keyword argument 'name'
--=20 Nicolas Ecarnot ------=_Part_3124281_1833167183.1417434665641 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div style=3D"color:#000; background-color:#fff; font-family:HelveticaNeue-= Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grand= e, sans-serif;font-size:16px"><div dir=3D"ltr" id=3D"yui_3_16_0_1_141735418= 2518_109137">not sure what sdk version 3.4.4 is, but according to log, late= st official for 3.4 is 3.4.1.1-1</div><div id=3D"yui_3_16_0_1_1417354182518= _113024" dir=3D"ltr">(make you have it installed)<br></div> <div id=3D"yui_= 3_16_0_1_1417354182518_110005" class=3D"qtdSeparateBR"><br><br></div><div i= d=3D"yui_3_16_0_1_1417354182518_109148" style=3D"display: block;" class=3D"= yahoo_quoted"> <div id=3D"yui_3_16_0_1_1417354182518_109147" style=3D"font-= family: HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetic= a, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div id=3D"yui_3_16= _0_1_1417354182518_109146" style=3D"font-family: HelveticaNeue, Helvetica N= eue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div i= d=3D"yui_3_16_0_1_1417354182518_109155" dir=3D"ltr"> <font id=3D"yui_3_16_0= _1_1417354182518_110966" face=3D"Arial" size=3D"2"> On Monday, December 1, = 2014 12:10 PM, Nicolas Ecarnot <nicolas@ecarnot.net> wrote:<br> </fon= t> </div> <br><br> <div id=3D"yui_3_16_0_1_1417354182518_109145" class=3D"= y_msg_container">Le 01/12/2014 11:07, Michael Pasternak a =C3=A9crit :<br c= lear=3D"none">> make sure you using latest sdk & cli, what is it btw= ? (run 'info' command)<br clear=3D"none"><br clear=3D"none">[oVirt shell (c= onnected)]# info<br clear=3D"none"><br clear=3D"none">backend version: 3.4<= br clear=3D"none">sdk version : 3.4.4<br clear=3D"none">cli ve= rsion : 3.4.0.5<br clear=3D"none">python version : 2.6.6.final= .0<br clear=3D"none"><br clear=3D"none">I think I run the version that is i= nstalled according to the global <br clear=3D"none">oVirt version ecosystem= - quite the same packages versions around 3.4.4.<div class=3D"yqt754488904= 4" id=3D"yqtfd87505"><br clear=3D"none"><br clear=3D"none">> [oVirt shel= l (connected)]# action disk serv-fs-int1_Disk1 move<br clear=3D"none">> = --storagedomain-name data-vm-adm8<br clear=3D"none">><br clear=3D"none">= > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D<br clear=3D"none">><br clear=3D"none">> UNKNOWN ERROR<br cl= ear=3D"none">> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D<br clear=3D"none">>  = ; &nb= sp; &= nbsp; get() got<br clear=3D"none">> an unexp= ected keyword argument 'name'<br clear=3D"none"><br clear=3D"none"><br clea= r=3D"none">-- <br clear=3D"none">Nicolas Ecarnot<br clear=3D"none"></div><b= r><br></div> </div> </div> </div> </div> ------=_Part_3124281_1833167183.1417434665641--

On 12/01/2014 12:51 PM, Michael Pasternak wrote:
not sure what sdk version 3.4.4 is, but according to log, latest official for 3.4 is 3.4.1.1-1 (make you have it installed)
There are two issues here. First is that the "move" disk operation on the top level collection isn't correctly documented in the RSDL metadata. As a result the Python SDK and the CLI don't support this operation. You can however use the same operation in the context of the VM: # action disk {disk:id} move --vm-identifier {vm:id} --storage_domain-name={storagedomain:name} Please open a bug requesting a fix for this. The other issue is that the 3.4 version doesn't support specifying disks by alias, only by id. This has been fixed in 3.5. So, all in all, at the moment you will need a command like this: # action disk c6aab66a-b551-4cc5-8628-efe9622c0dce move --vm-identifier myvm --storage_domain-name mysd
On Monday, December 1, 2014 12:10 PM, Nicolas Ecarnot <nicolas@ecarnot.net> wrote:
Le 01/12/2014 11:07, Michael Pasternak a écrit :
make sure you using latest sdk & cli, what is it btw? (run 'info' command)
[oVirt shell (connected)]# info
backend version: 3.4 sdk version : 3.4.4 cli version : 3.4.0.5 python version : 2.6.6.final.0
I think I run the version that is installed according to the global oVirt version ecosystem - quite the same packages versions around 3.4.4.
[oVirt shell (connected)]# action disk serv-fs-int1_Disk1 move --storagedomain-name data-vm-adm8
============================================================================
UNKNOWN ERROR ========================================================================= get() got an unexpected keyword argument 'name'
-- Nicolas Ecarnot
_______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
-- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

Le 01/12/2014 13:23, Juan Hernández a écrit :
On 12/01/2014 12:51 PM, Michael Pasternak wrote:
not sure what sdk version 3.4.4 is, but according to log, latest official for 3.4 is 3.4.1.1-1 (make you have it installed)
There are two issues here. First is that the "move" disk operation on the top level collection isn't correctly documented in the RSDL metadata. As a result the Python SDK and the CLI don't support this operation. You can however use the same operation in the context of the VM:
# action disk {disk:id} move --vm-identifier {vm:id} --storage_domain-name={storagedomain:name}
Please open a bug requesting a fix for this.
Done! https://bugzilla.redhat.com/show_bug.cgi?id=1169376
The other issue is that the 3.4 version doesn't support specifying disks by alias, only by id. This has been fixed in 3.5.
So, all in all, at the moment you will need a command like this:
# action disk c6aab66a-b551-4cc5-8628-efe9622c0dce move --vm-identifier myvm --storage_domain-name mysd
Your workaround is working : thank you. -- Nicolas Ecarnot

On 01. 12. 2014 14:40, Nicolas Ecarnot wrote:
Le 01/12/2014 13:23, Juan Hernández a écrit :
On 12/01/2014 12:51 PM, Michael Pasternak wrote:
not sure what sdk version 3.4.4 is, but according to log, latest official for 3.4 is 3.4.1.1-1 (make you have it installed)
There are two issues here. First is that the "move" disk operation on the top level collection isn't correctly documented in the RSDL metadata. As a result the Python SDK and the CLI don't support this operation. You can however use the same operation in the context of the VM:
# action disk {disk:id} move --vm-identifier {vm:id} --storage_domain-name={storagedomain:name}
Please open a bug requesting a fix for this.
Done!
https://bugzilla.redhat.com/show_bug.cgi?id=1169376
The other issue is that the 3.4 version doesn't support specifying disks by alias, only by id. This has been fixed in 3.5.
So, all in all, at the moment you will need a command like this:
# action disk c6aab66a-b551-4cc5-8628-efe9622c0dce move --vm-identifier myvm --storage_domain-name mysd
Your workaround is working : thank you.
Hi, i know this is an old thread but i need to move a bunch of disks from one storage domain to another. I am unable to move disks with ovirt-shell as it seems it does not support moving disks when quota enabled and enforced on datacenter. Is that correct? Any help appreciated. ovirt shell action disk 689ce8fe-0d40-47e1-a933-7bae5ed0812b move --storage_domain-name NLSAS_PRIM status: 400 reason: Bad Request detail: Cannot move Virtual Machine Disk. Quota is not valid. I can move disks normally via webadmin. Using ovirt-engine-cli-3.6.2.0-1.fc23.noarch, ovirt-engine-3.5.6.2-1.el6.noarch

On 07/13/2016 10:30 AM, Jure Kranjc wrote:
On 01. 12. 2014 14:40, Nicolas Ecarnot wrote:
Le 01/12/2014 13:23, Juan Hernández a écrit :
On 12/01/2014 12:51 PM, Michael Pasternak wrote:
not sure what sdk version 3.4.4 is, but according to log, latest official for 3.4 is 3.4.1.1-1 (make you have it installed)
There are two issues here. First is that the "move" disk operation on the top level collection isn't correctly documented in the RSDL metadata. As a result the Python SDK and the CLI don't support this operation. You can however use the same operation in the context of the VM:
# action disk {disk:id} move --vm-identifier {vm:id} --storage_domain-name={storagedomain:name}
Please open a bug requesting a fix for this.
Done!
https://bugzilla.redhat.com/show_bug.cgi?id=1169376
The other issue is that the 3.4 version doesn't support specifying disks by alias, only by id. This has been fixed in 3.5.
So, all in all, at the moment you will need a command like this:
# action disk c6aab66a-b551-4cc5-8628-efe9622c0dce move --vm-identifier myvm --storage_domain-name mysd
Your workaround is working : thank you.
Hi,
i know this is an old thread but i need to move a bunch of disks from one storage domain to another. I am unable to move disks with ovirt-shell as it seems it does not support moving disks when quota enabled and enforced on datacenter. Is that correct? Any help appreciated.
ovirt shell action disk 689ce8fe-0d40-47e1-a933-7bae5ed0812b move --storage_domain-name NLSAS_PRIM status: 400 reason: Bad Request detail: Cannot move Virtual Machine Disk. Quota is not valid.
I can move disks normally via webadmin. Using ovirt-engine-cli-3.6.2.0-1.fc23.noarch, ovirt-engine-3.5.6.2-1.el6.noarch
Doron, Roy, internally the API uses the "MoveDisks" command to move the disks, and that action is marked as "QuotaDependency.STORAGE". Is that correct? Can you take a look? -- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

Hi, any news on the subject? How do other users move many disks between storage domains? I believe not many people use quotas though.. On 13. 07. 2016 13:38, Juan Hernández wrote:
On 07/13/2016 10:30 AM, Jure Kranjc wrote:
On 01. 12. 2014 14:40, Nicolas Ecarnot wrote:
Le 01/12/2014 13:23, Juan Hernández a écrit :
On 12/01/2014 12:51 PM, Michael Pasternak wrote:
not sure what sdk version 3.4.4 is, but according to log, latest official for 3.4 is 3.4.1.1-1 (make you have it installed)
There are two issues here. First is that the "move" disk operation on the top level collection isn't correctly documented in the RSDL metadata. As a result the Python SDK and the CLI don't support this operation. You can however use the same operation in the context of the VM:
# action disk {disk:id} move --vm-identifier {vm:id} --storage_domain-name={storagedomain:name}
Please open a bug requesting a fix for this. Done!
https://bugzilla.redhat.com/show_bug.cgi?id=1169376
The other issue is that the 3.4 version doesn't support specifying disks by alias, only by id. This has been fixed in 3.5.
So, all in all, at the moment you will need a command like this:
# action disk c6aab66a-b551-4cc5-8628-efe9622c0dce move --vm-identifier myvm --storage_domain-name mysd Your workaround is working : thank you.
Hi,
i know this is an old thread but i need to move a bunch of disks from one storage domain to another. I am unable to move disks with ovirt-shell as it seems it does not support moving disks when quota enabled and enforced on datacenter. Is that correct? Any help appreciated.
ovirt shell action disk 689ce8fe-0d40-47e1-a933-7bae5ed0812b move --storage_domain-name NLSAS_PRIM status: 400 reason: Bad Request detail: Cannot move Virtual Machine Disk. Quota is not valid.
I can move disks normally via webadmin. Using ovirt-engine-cli-3.6.2.0-1.fc23.noarch, ovirt-engine-3.5.6.2-1.el6.noarch
Doron, Roy, internally the API uses the "MoveDisks" command to move the disks, and that action is marked as "QuotaDependency.STORAGE". Is that correct? Can you take a look?
participants (4)
-
Juan Hernández
-
Jure Kranjc
-
Michael Pasternak
-
Nicolas Ecarnot