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-devel

[Xen-devel] [PATCH] xend: Sleep before sending SIGKILL to device model

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] xend: Sleep before sending SIGKILL to device model
From: Yosuke Iwamatsu <y-iwamatsu@xxxxxxxxxxxxx>
Date: Wed, 28 Jan 2009 17:46:32 +0900
Delivery-date: Wed, 28 Jan 2009 00:47:50 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.19 (Windows/20081209)
When we destroy a domain, xend sends SIGTERM to the device model and
wait by waitpid() until the device model process disappears.
If we restarted xend during the lifetime of the domain, waitpid() fails
because the device model is no longer a child of xend, and in that case
xend gives up waiting for the shutdown of process and just send it
SIGKILL immediately. This is problematic because most of the case the
device model will be forcibly killed by xend before shutting itself
down.
This patch adds time.sleep before sending SIGKILL to the device model.
On my test box shutdown of a device model usually takes about 0.5 sec,
so waiting two seconds should be enough in most cases.

Regards,
-----------------------
Yosuke Iwamatsu
        NEC Corporation

Signed-off-by: Yosuke Iwamatsu <y-iwamatsu@xxxxxxxxxxxxx>

Attachment: xend_dm_sigkill.patch
Description: all/allfiles

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>