X-Spam-Check-By: sourceware.org Date: Wed, 26 Apr 2006 17:40:08 -0500 From: mwoehlke Subject: Re: "Ghost" processes on Cygwin In-reply-to: <444FF238.40906@scytek.de> To: cygwin AT cygwin DOT com Reply-to: cygwin AT cygwin DOT com Message-id: <444FF6C8.50707@tibco.com> MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7BIT User-Agent: Thunderbird 1.5 (X11/20051201) References: <444FF04F DOT 20109 AT tibco DOT com> <444FF238 DOT 40906 AT scytek DOT de> Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Unsubscribe: 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 Volker Quetschke wrote: > mwoehlke wrote: >> I'm seeing something funny. While trying to build a large program on >> Cygwin using cl.exe (i.e. I am building a non-Cygwin app; just using >> Cygwin to drive 'make'), every now and then, cl.exe hangs. Before you >> tell me I'm on the wrong list :-), here's the funny part. If I do 'ps' >> in Cygwin, I can see the 'cl' process, along with its WINPID. However, >> it doesn't show up in task manager! Also, there are about five >> processes that are clearly Cygwin processes (bash.exe or sh.exe) that >> do NOT show up in Cygwin's 'ps'. > Can you enter > $ ls /proc/*/fd > in another cygwin console and report if it helps? It might unhang the stuck > process. Hmm... nope. In fact, that got stuck too. 'ls /proc/2072' dies and must be 'kill -9'd. 'ps | grep 2072' says: PID PPID PGID WINPID TTY UID STIME COMMAND 2072 1 1876 2072 con 1003 Apr 21 /usr/bin/bash 'ls /proc//fd' failed to revive it. If I cat it's cmdline (in its /proc), I see that it matches what 'make' is claiming it ran. Something a little suspicious(?); fd's 5-7 are all pointing at the same place and that place is a directory. Also, 255 is pointing at the shell script (/w32dev/cl32.exe) that launched (exec()'d) the process. If it's relevant, 'make' (which does show up as the parent) actually launched 'cl'; it exec()'d through 3-4 scripts to get to the actual binary. >> Is there any logic to this that I'm missing? I want to attach a >> debugger (probably devenv, since gdb - unsurprisingly - doesn't seem >> to work) to cl.exe to try to find out why it's hung, but I can't find >> the pid to attach to! (Also, for the sake of brevity, please don't quote my cygcheck.out! :-) Um... PCYMTNQTA? ;-) (TA=Text Attachments)) -- Matthew All of my signatures are 100% original. Including this one. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/