delorie.com/archives/browse.cgi | search |
DKIM-Filter: | OpenDKIM Filter v2.11.0 delorie.com 45UDuTOe409542 |
Authentication-Results: | delorie.com; |
dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=sbsJ9Xx4 | |
X-Recipient: | archive-cygwin AT delorie DOT com |
DKIM-Filter: | OpenDKIM Filter v2.11.0 sourceware.org 2D7BE3877021 |
DKIM-Signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; |
s=default; t=1719755787; | |
bh=ftZrOnfhxkxUSZOypVS3eWCoHIbZHLpQVZQ2diEBr/Y=; | |
h=Date:To:Cc:Subject:In-Reply-To:References:List-Id: | |
List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: | |
From:Reply-To:From; | |
b=sbsJ9Xx4SAMP9k7dIIIzIsvCcWgozzwJKvD8CRYD6xztwntc/UIaX3SgvTu1s+dEE | |
2ntKE86cRB0yHF9m+nodWt+j1rpG0+hOJSnPMnQiA4cEHZXgG5FoP6hBNnJwlmoGn5 | |
Wi+azKFdxCKeIUfwzHo3VcFU+MzwhgFtqEVEHvNc= | |
X-Original-To: | cygwin AT cygwin DOT com |
Delivered-To: | cygwin AT cygwin DOT com |
DMARC-Filter: | OpenDMARC Filter v1.4.2 sourceware.org 3C2F53858C33 |
ARC-Filter: | OpenARC Filter v1.0.0 sourceware.org 3C2F53858C33 |
ARC-Seal: | i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1719755727; cv=none; |
b=m6mvnvI23umwzbQW+sSAQbMwcHr3LCkhjhR6bQkPM4Lep2VRZfyY7Im/klii0pFApkKLGW7zilzdynPX/gskcxf7MAws5GPWuTSy/KnrtJiqMWb9IoycSur7Vcqw/yrFe6Z/ntOoy6C+Rp0hAi0c2dO59cLmDUtRpEXlBUUM+Pw= | |
ARC-Message-Signature: | i=1; a=rsa-sha256; d=sourceware.org; s=key; |
t=1719755727; c=relaxed/simple; | |
bh=k7u5EdJOjHhcYAUsPNnsIMjdxXBvrBCCGj8MT7/xFEM=; | |
h=Date:From:To:Subject:Message-Id:Mime-Version:DKIM-Signature; | |
b=AIIea6QVUIZppiABg+6pPa9ANkJPOGD0wsU9bm108p0nldXN22nCApwyQryXAQZ8mt8XQLBM4m7YLQ7aYBF+0wjCbmEsaTv2l9PTKQdG/makQFM8Wz7FeHffTeV/6r0bFJGPSghCe1LDP/PM7FPIVIk14uAdSOiDdE/433oDGOM= | |
ARC-Authentication-Results: | i=1; server2.sourceware.org |
Date: | Sun, 30 Jun 2024 22:55:22 +0900 |
To: | cygwin AT cygwin DOT com |
Cc: | jojelino <jojelino AT gmail DOT com> |
Subject: | Re: ssh-add -l hangs under cygwin test 3.6.0-0.139.g... |
Message-Id: | <20240630225522.98d50536be104a7425a97394@nifty.ne.jp> |
In-Reply-To: | <19c300bb-97ff-4dee-be8c-2215b38f0a1c@gmail.com> |
References: | <bd97f4a1-0298-4422-8594-40f0989d13ce AT SystematicSW DOT ab DOT ca> |
<19c300bb-97ff-4dee-be8c-2215b38f0a1c AT gmail DOT com> | |
X-Mailer: | Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) |
Mime-Version: | 1.0 |
X-Spam-Status: | No, score=-4.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, |
DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, | |
RCVD_IN_VALIDITY_RPBL, SPF_HELO_PASS, SPF_PASS, TXREP, | |
WEIRD_PORT autolearn=ham autolearn_force=no version=3.4.6 | |
X-Spam-Checker-Version: | SpamAssassin 3.4.6 (2021-04-09) on |
server2.sourceware.org | |
X-BeenThere: | cygwin AT cygwin DOT com |
X-Mailman-Version: | 2.1.30 |
List-Id: | General Cygwin discussions and problem reports <cygwin.cygwin.com> |
List-Unsubscribe: | <https://cygwin.com/mailman/options/cygwin>, |
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe> | |
List-Archive: | <https://cygwin.com/pipermail/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-request AT cygwin DOT com?subject=help> |
List-Subscribe: | <https://cygwin.com/mailman/listinfo/cygwin>, |
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe> | |
From: | Takashi Yano via Cygwin <cygwin AT cygwin DOT com> |
Reply-To: | Takashi Yano <takashi DOT yano AT nifty DOT ne DOT jp> |
Errors-To: | cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com |
Sender: | "Cygwin" <cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com> |
On Sun, 30 Jun 2024 20:33:19 +0900 jojelino wrote: > On 6/29/2024 2:39 PM, Brian Inglis via Cygwin wrote: > > Reran cygport --debug upload and command hanging was ssh-add -l! > > > 296 72109 [main] ssh-add 63275 win32env_to_cygenv: 0xA000232E0: > TERM_PROGRAM=mintty > 189 72298 [main] ssh-add 63275 win32env_to_cygenv: 0xA00023300: > TERM_PROGRAM_VERSION=3.7.1 > > I was able to reproduce this problem by entering below command with > ffmpeg from https://www.gyan.dev/ffmpeg/builds/ , this ffmpeg build > spams putc. So, without piping its output to `tee', It would not > possible track down any cause among lengthy trace output. > > strace mintty -e /bin/timeout 10 sh -c './ffmpeg -h full|& tee' > > In summary, When `timeout' expires, `timeout' signals SIGHUP to pgrp of > itself, btw some member of the pgrp may have acquired any of > synchronization object of some part of cygwin internal when a member > process of the pgrp did encounter the signal interrupt from `timeout'. > In my case it was output_mutex of pty. > > 1565 10693297 [main] timeout 745 kill_pgrp: pid 0, signal 15 > 2701 15224348 [main] mintty 744 > fhandler_pty_master::process_slave_output: bytes read 256 > 1736 9525442 [sig] sh 746 proc_subproc: args: 4, 1 > 3137 6700294 [main] tee 748 fhandler_pty_slave::write: pty5, > write(0x7FFFFC780, 1024) > 1347 9526789 [sig] sh 746 proc_subproc: clear waiting threads > 2084 15226432 [main] mintty 744 > fhandler_pty_master::process_slave_output: returning 256 > 1110 6701404 [main] tee 748 fhandler_pty_slave::write: (1267): pty > output_mutex (0x4C0): waiti > -1 ms > 732 9527521 [sig] sh 746 checkstate: child_procs count 2 > 3648 10696945 [main] timeout 745 open_shared: name cygpid.724, shared > 0x1A0050000 (wanted 0x1A > 0000), h 0x16C, m 6, created 0 > 1055 6702459 [main] tee 748 fhandler_pty_slave::write: (1267): pty > output_mutex: acquired > > 2092 15753306 [main] mintty 744 fhandler_pty_master::close: (2095): > pty output_mutex (0x4AC): > ting -1 ms > > And below is a location where `tee' did hang. > > #3 0x00007ffd0e408fdf in fhandler_pty_slave::write (this=0x800009a10, > ptr=0x7ffffc780, len=<optimized out>) > at ../../.././winsup/cygwin/fhandler/pty.cc:1268 > 1268 if (!process_opost_output (get_output_handle (), ptr, towrite, > false, > (gdb) li > 1263 termios_printf ("pty%d, write(%p, %lu)", get_minor (), ptr, len); > 1264 > 1265 push_process_state process_state (PID_TTYOU); > 1266 > 1267 acquire_output_mutex (mutex_timeout); > 1268 if (!process_opost_output (get_output_handle (), ptr, towrite, > false, > 1269 get_ttyp (), is_nonblocking ())) > > > I ended up prepending two CancelIo call just above of > acquire_output_mutex located in fhandler_pty_master::close of pty.cc. > > > CancelIo(get_ttyp()->to_master()); > > CancelIo(get_ttyp()->to_master_nat()); > acquire_output_mutex (mutex_timeout); > > Hope it helps I cannot reproduce the issue. 1) Which cygwin version do you use? 2) Is this really the same problem with the problem original post reported? (i.e. reproducible with 3.6.0-0.139 and not reproduced with 3.5.3) -- Takashi Yano <takashi DOT yano AT nifty DOT ne DOT jp> -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |