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

[Xen-API] [PATCH] try extra hard to kill stunnel

To: xen-api@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-API] [PATCH] try extra hard to kill stunnel
From: David Scott <dave.scott@xxxxxxxxxxxxx>
Date: Wed, 7 Apr 2010 16:56:59 +0100
Delivery-date: Wed, 07 Apr 2010 08:54:57 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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>
Sender: xen-api-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User David Scott <dave.scott@xxxxxxxxxxxxx>
# Date 1270655800 -3600
# Node ID 2acdc92cc8fee02d10228f58846c8db51fb5dea3
# Parent  08ed7d25bd714e282c3fc758af3daa22db8d548d
CA-39972: try extra hard to kill stunnel in 'service xapissl stop'

Previously we sent one SIGTERM and waited for up to 3 minutes. In a quick test, 
out of 1000 back-to-back 'service xapissl restart' calls, one took the full 3 
minutes, as if the signal was ignored.

Now we send additional SIGTERMS as we go around the loop, one per second. In a 
quick test, 10000 back-to-back 'service xapissl restart' calls completed 
without any taking more than a few seconds.

Signed-off-by: David Scott <dave.scott@xxxxxxxxxxxxx>

diff -r 08ed7d25bd71 -r 2acdc92cc8fe scripts/init.d-xapissl
--- a/scripts/init.d-xapissl    Wed Apr 07 16:56:10 2010 +0100
+++ b/scripts/init.d-xapissl    Wed Apr 07 16:56:40 2010 +0100
@@ -121,6 +121,7 @@
            kill -0 $SSLPID 2> /dev/null
             if [ $? -eq 0 ]; then
                echo -n .
+               kill ${SSLPID} # in case the first signal was missed
                sleep 1
            else
                echo
1 file changed, 1 insertion(+)
scripts/init.d-xapissl |    1 +


Attachment: xen-api.hg.patch
Description: Text Data

_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-API] [PATCH] try extra hard to kill stunnel, David Scott <=