delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2015/11/26/15:16:03

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=htQwcc+NzW7m3SDBeCWBL5MlGhM9dKCLoZJUNP5BJS2LAwYQB41ss
hqASqljgaUp4l1MqRoYwmE9YgbCEdVohx8IpI0PTwx90x3Pf3X4x9YE3OOX4raut
niagysdoTpSzJioW/S3dnsAdc0LzhSgWDyNIeEh5/PFfYjSn6N6X9s=
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=WpoL7KEyC2Ej5Ik5SuZUPSNF6TY=; b=Y+thJOZzMrnv5Gb3r/XCivcPs1s9
fbkMq4lfrtf7cwB+SjgJVxFx4TvTwOTPREj+EiQqifiOO1BVIgFjNE4gGFuiMsFn
nC0k6B3IiEAS0WRAKZSOf05PcCb5MTDg79jFL+0ulymmjJWkA2pp2byZVJ/leqgH
ih5UOjPRfeppvLw=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
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=-5.4 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2
X-HELO: calimero.vinschen.de
Date: Thu, 26 Nov 2015 21:15:46 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: 64bit cygwin 2.4.0-0.4 hangs when pinging unresponsive host
Message-ID: <20151126201546.GQ2755@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <01f501d12701$d5af6fb0$810e4f10$@vianet.ca> <5654E4E3 DOT 8050605 AT gmail DOT com> <56555DF4 DOT 9090804 AT towo DOT net> <56559566 DOT 7070808 AT gmail DOT com> <565621A3 DOT 3090706 AT gmail DOT com>
MIME-Version: 1.0
In-Reply-To: <565621A3.3090706@gmail.com>
User-Agent: Mutt/1.5.23 (2014-03-12)

--yK/6QRnH3Zanb0EF
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Nov 25 22:01, Marco Atzeri wrote:
>=20
>=20
> On 25/11/2015 12:03, Marco Atzeri wrote:
> >On 25/11/2015 08:06, Thomas Wolff wrote:
> >>Am 24.11.2015 um 23:29 schrieb Marco Atzeri:
> >>>
> >
> >>>...
> >>>I assume it is an interaction with mintty.
> >>Many problems of that kind attributed to mintty are actually problems
> >>with cygwin or especially pty.
> >>Please test also with another terminal (xterm, rxvt, ...).
> >>Also some more details could be helpful as I cannot reproduce the issue
> >>(output of `type ping`, actual host pinged).
> >>------
> >>Thomas
> >
> >you are right is not a mintty only issue.
> >Same happens in xterm
> >
> >
> >$ which ping
> >/usr/bin/ping
> >
> >$ ping 2.2.2.2
> >PING 2.2.2.2 (2.2.2.2): 56 data bytes
> >
> >It sticks here forever, CTRL+C ineffective.
> >Process Explorer or Task Manager are needed to kill the process.
> >Also kill -9 PID is ineffective
> >
> >On the old cygwin.bat (aka windows cmd)
> >CTRL+C is effective
> >
> >  64 $ ping 2.2.2.2
> >PING 2.2.2.2 (2.2.2.2): 56 data bytes
> >
> >----2.2.2.2 PING Statistics----
> >2 packets transmitted, 0 packets received, 100.0% packet loss
>=20
>=20
> the problem seems restricted to the 64bit test version of cygwin.

I think this is pure coincidence.  After some hours debugging this
problem it seems it's a race condition, architecture-independent and
present since quite a while in Cygwin.  In case of ping the race leads
to a blocking socket function missing a signal arrived, thus the
signal is never handled.  This in turn blocks the next signal from being
delivered.

I have a potential fix, but I have to test it a bit.  The signal code
is pretty complicated...


Corinna

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--yK/6QRnH3Zanb0EF
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWV2hyAAoJEPU2Bp2uRE+gh3wQAIRcBW+hLzje2hRnQp5B6u4S
F9sC9Kss1l1DwgiJ47bblaJfR3EVA0f05hADS3JZZOqv/ALotT8rIjONlF3ABOKx
lkZgyw9c9DSqlrqZg4qFsFCpWXtVonedvX5gwk9yp9/NBaAZcGykrx9kZK7dTrH6
2GGEXOzocX+IBW9tXg+4cjQhyr3G6drb5PhuC3VtRhQLAnmKPHUqQwSr0HLlaUCu
+G6lkACHog7CpfmRyQeBJ3CJ01K/qz1Na70B50bf83vhTf0L+1FiSK4Z9ZK4Wkf0
+jXGy2kpVF5hePFvYE6Nifo2lX4Q06z9IDdtu0PnWSbFoAGThWW6uHsZKNhGclal
yUHmyEXGKA2B5dD61D0fF9bldrmQjZWumjwnfjvy6f8vwl980S5SSArVvf7ont+4
IUhs9zhFyeen9jc405qcgjWn3rVZs0doZKXIR6+QyaCSSbwF86dvhYU/5BC7kPYv
3HkO5QVR5dy3xDyzsF4K1E7vC5LB/FkfRbF/Q8bA/AoqzQHoH/CAPEHlQXWovDw7
IXexnMgzypbD8T083qMEA6jRGk8+HbxrYlRzW7+/5Rb2s2WsSW3YmRheBuXWf0Bf
JoTF7IoCtjOK3PLfORrAYwgx81qxCqTYgiLfLC5zSiiJTeQasutYpO7W3yb82fEq
K9GHL54jNGcvW6YAt0j7
=cy9u
-----END PGP SIGNATURE-----

--yK/6QRnH3Zanb0EF--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019