X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:reply-to :references:mime-version:content-type:in-reply-to; q=dns; s= default; b=uEGC6VL/IKkmumVd2aAKayHpWxQiVJS1di/wby1vdYqHJMLSD31ic /Fxbute5J5+e/lZTyKyae5OgCLzA9OLvDfDWEFpZ6LbmMFx0qWM4+3aMuEr9DSh1 9vq+rLKOnFJIhFjmKq2f4Fl9xmjB/iIz3+JPKDhfoMxYSDYXuUBxv8= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:reply-to :references:mime-version:content-type:in-reply-to; s=default; bh=1A8DRqNukmNPzrKMba0iwTQMUJM=; b=YD6bbfHeBxy0Uhx9C9+QtrZtLhbM ICPJkJgNwaNez+zLIF69q8zNpp6jbpHldgLNe3k/GawTFWBP9JgR3+n90mgeJGJu 4fCpffAxcvkkb0CsgGC4Vra+XK2Uj8kbijhR67k2oa1iwXmBkVdKwZOU3P84LN1E VwhfZCopK4FkAY0= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,TIME_LIMIT_EXCEEDED autolearn=unavailable version=3.3.2 spammy=mails, af_unix, sockets, looping X-HELO: drew.franken.de X-Spam-Score: -2.899 Date: Thu, 22 Mar 2018 17:59:08 +0100 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: Odd hang in python waiting for child; strace wakes hung process? Message-ID: <20180322165908.GI6761@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <877eq5fedf DOT fsf AT Rainer DOT invalid> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="cWoXeonUoKmBZSoM" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) --cWoXeonUoKmBZSoM Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mar 21 23:41, Brian Inglis wrote: > On 2018-03-21 16:07, Dan Kegel wrote: > > On Wed, Mar 21, 2018 at 11:54 AM, Achim Gratz wrote: > >> Well, with the sporadic hanging/defunct processes at work my routine is > >> to send CONT to all Cygwin processes, then HUP/KILL to anything that's > >> still not live or gone and then another round of CONT. This works > >> _most_ of the time, anything more stubborn I /bin/kill -f usually. > >=20 > > Since I wrote, both bots hung again. This time I verified: > > 0) both had the defunct git process as expected > > 1) kill -CONT the-pid doesn't do anything, nor does kill -9. It's trul= y wedged. > > 2) the process stays in its spin hang until you ^C strace -p the-pid > > 3) ^C-ing the strace causes the process to terminate (strace alone does= n't) > > 4) taskkill /pid the-task /f also kills the process successfully. > >=20 > > So I could write a script that watched for defunct git processes > > and taskkilled their parent. Build jobs would fail, but at least > > the bot would stay up. Of course it would be much nicer if > > the cygwin python process didn't get wedged. > >=20 > > Alternately, I suppose I could try running native python... > > or cygwin's python3... but dangit, kill -9 should work. >=20 > Seems to be looping on access failure to a Windows mailslot; not sure wha= t this > feature is normally used for: dmesg/syslog messages/AF_UNIX sockets? /dev/kmsg is implemented using a mailslot under the hood. This feature is only used to log exceptions and for nothing else since nobody ever found another reason to use it for. It would be interesting to learn if the perl hangs have the same reason. I guess we can simply remove /dev/kmsg support completely and drop the mailslot code. I'm pretty sure nobody would miss it. Hardly anybody knows it exists... Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --cWoXeonUoKmBZSoM Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlqz4NwACgkQ9TYGna5E T6CXtA//XtUIoqaLZY4VXBCOUhTfId5Z+Qqka3cmJBo1njK5ZJJrxdOgE87GDJGw vf0YLHQ2QtmZE3/Khfu1XCqYS75PZxpM3uYgYO7MdchmQwufwUaDbforJQEYacTH 50o+Gg7aJ7lASmpewlvCgmptoPt07QQW8C6PPtdM5/iYP6GO37inCV8r4O/btMqv +5H62f5A8rxO7O6p9tQNvEQClGmGTyAvT3v+OQ/MmOjG7iBFWYfjpternvQ30hV9 9WuMFj3zd0Z9awOJ3c6PZkX6qb+121uPYzjj/XZT4nAQ1m/M01OsfzjIF9xnMunU x3I3uJBksB8l4CqqYwn7N1r1aXSxQnONhKh8lrPk7XGmFfGV+At4TL9BhyfTBw2h Qjt68uB/TxZkuhdidUxb7GlY954BpGANCbc6lbRBF5ZOneUJ8zeh308SESkkmWoT IbeFx1zPe37Hzu90LQmhB/Pb7MUhzDDJvniFMVrLdMNILYGKTqTXaL9nU+gG1msh cY9ajw1YTGQncUS50adB+p1MSwkF+sPFbYEk5lJPyAGlVDZRlnlbp3rkT4b1V2lH 37QRvIQzYj3pI1rFN3q8Tj8Scq1GQzPMxJ+VykID/m5TM3JbTpTtyqparesDpviz dzZmHzSYhrKU6EJ4/n5cnMDk5/i5CjhqzSw7BvC0+n7zqWt78aE= =h3Ho -----END PGP SIGNATURE----- --cWoXeonUoKmBZSoM--