[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-API] VM_IMPORT_FAILED addition


  • To: xen-api@xxxxxxxxxxxxxxxxxxx
  • From: ka <ka@xxxxxxxx>
  • Date: Mon, 23 Jan 2012 21:38:34 +0400
  • Delivery-date: Mon, 23 Jan 2012 17:37:59 +0000
  • List-id: Discussion of API issues surrounding Xen <xen-api.lists.xensource.com>

23.01.2012 20:49, ka пишет:
But when I try to revert VM, I have strange behavior of VM.revert operation.

I rollback my ZFS storage, unregister VM, import VM metadata, rescan SR and try to call VM.revert function. Its return VM_REVERT_FAILED message.

*The strangeness of the fact that when I ignore VM_REVERT_FAILED exception and try to repeat VM.revert call - it works fine.*
I mean that second call of VM.revert works without error (There is no pause between them).

I looked at sources: https://github.com/xen-org/xen-api/blob/master/ocaml/xapi/xapi_vm_snapshot.ml
It's look like line 420 update_vifs_and_vbds ~__context ~snapshot ~vm; through error.
I look at the let update_vifs_and_vbds (281).
Seems, it line 295 through exception List.iter (safe_destroy_vbd ~__context ~rpc ~session_id) vm_VBDs;

I try to make this call from my script (I mean destroy API function call for all VM's VBDs) and got same error as in log:

VBD 'd92b50bf-16b4-de2f-b8c8-454157f51904' still attached to '29f39b05-72b5-9512-3207-5c400aec4bcf'
OPERATION_NOT_ALLOWED

The only line executed after this exception is 430: Xapi_vm_lifecycle.force_state_reset ~__context ~self:vm ~value:`Halted;
I check imported VM status. It is 'halted' and I cannot to call VM.hard_shutdown.
Can I invoke Xapi_vm_lifecycle.force_state_reset  as in 430 throuhg API?




_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api

_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.