WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-api

Re: [Xen-API] Host Down VDI Locked

To: Rushikesh <rushikesh.jadhav@xxxxxxxxxx>, xen-api@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-API] Host Down VDI Locked
From: Chris Percol <chris.percol@xxxxxxxxx>
Date: Thu, 24 Feb 2011 10:58:03 +0000
Cc:
Delivery-date: Thu, 24 Feb 2011 02:58:33 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=jFt1K9SXZ8GRH7IGkV+yZOlzHs61zeZy0cYUDQM7g0A=; b=ejk2MioPwtF/LqPP8YskbUG/HqQvFEycn7A/2tSEG2WPjzAQYWM1NTB+LiqcAaNuQ5 DhyFNuKTT2HMAtQbENkzb9UwdPmYRbA0BMZ8JFxyxIU5v9FTD3E/LYn2Pyq2ezSAjKdU tr1uxNqGEjWg4L1LlXFHx42NQMxrHanEYcakQ=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=bnHGF3XYu7qyPIHn/2ZW2fS6CU0hxdM6lVlXrzsIMLMtki2PiIowVwHiIFxYMQUnwk OIAWjANTuMruWt7O2M47df0nJbIEc0cUCG/D1GpDIrVkkdRO4iLbDwJwpVevfFZKUk04 krXLZcqhKu6Db62dOie9eg0OPaJm6R7/RRPys=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4D657796.20101@xxxxxxxxxx>
List-help: <mailto:xen-api-request@lists.xensource.com?subject=help>
List-id: Discussion of API issues surrounding Xen <xen-api.lists.xensource.com>
List-post: <mailto:xen-api@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-api>, <mailto:xen-api-request@lists.xensource.com?subject=unsubscribe>
References: <4D657796.20101@xxxxxxxxxx>
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
Here are some notes I made on recovering from vdi not available after a power failure on our iscsi san. Just for reference for others as you seems to be sorted anyway. 

###Fix VDI Problems after Power Failure###

#Steps that fixed 'vdi not available', sr backend failure

console
xe pbd-list sr-uuid=<uuid>
xe pbd-unplug uuid=<uuid>

Xen Center
Storage Forget
Storage > New Storage

xsconsole
Restore Virtual Machine Metadata

On Wed, Feb 23, 2011 at 9:09 PM, Rushikesh <rushikesh.jadhav@xxxxxxxxxx> wrote:
Hello all,

I am using and studying XCP from past 2 month and have got my self a
little acquainted with its architectural working.

My setup: 3 XCP 1beta hosts and shared iSCSI storage.  ( not the rc3 )

I have just started getting my hands dirty on code. (Python is very new
for me)

I had a case when my host was hard rebooted while VM on it were running.
And now all are refusing to start with Exception "VDI is unavailable".

So, when I started reading the traceback more closely I found that the
exception is generating at

File "/opt/xensource/sm/blktap2.py", line 1230, in _add_tag
if sm_config.get("writable") == "true":
   raise util.SMException("VDI %s already attached RW" % vdi_uuid)

I compared a crashed VDI and non crashed and saw that the crashed VDI
still has  a writable : true in sm-config.

# xe vdi-param-list uuid=03dfd013-bdd0-4c76-b099-4ad30d4018b6   (
Crashed VDI )

sm-config (MRO): writable: true; vhd-parent:
4841232c-09d9-47c6-8ba5-e68117745392;
host_OpaqueRef:205c3920-6b6d-c96b-a963-d16cdc21496f: active


# xe vdi-param-list uuid=f701575e-b399-4c02-a930-e3d0dee87b6e    (
Normal VDI )

sm-config (MRO): vhd-parent: 545b2f45-552a-474c-8b4f-f6079907fd21;
vdi_type: vhd


Then I started reading the code but Im getting little lost and I dont
want to make xe database corrupt. Recreating SR is a solution with a
risk of getting all VM rebooted.

So, I tried same scene with XCP1 and all VM were able to get
successfully boot. Nice work guys :)

I really want to understand how you did it and was I on correct path...
I really want to get into some development of XCP but my first problem
is already solved ;)


Thanks for patience and expecting a positive reply.

Regards,
Rushikesh





_______________________________________________
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
<Prev in Thread] Current Thread [Next in Thread>