X-Spam-Check-By: sourceware.org Message-ID: X-Sender: sbremal AT hotmail DOT com From: "B. S." To: cygwin AT cygwin DOT com Subject: bash + defunct processes Date: Fri, 06 Oct 2006 08:48:12 +0000 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm 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 Hi, For a few days I have been struggling with bash scripts leaving defunct processes behind. The scripts are kicked off from crontab and are running in the background. $ ps PID PPID PGID WINPID TTY UID STIME COMMAND 1744 4384 1688 1744 ? 156894 18:26:16 1224 1960 1736 3228 ? 156894 18:26:16 4212 1 4212 4212 con 156894 18:26:31 /usr/bin/bash 4488 4992 3480 8056 ? 156894 18:27:14 8968 3340 6548 3968 ? 156894 18:28:15 7112 8624 1872 5492 ? 156894 18:39:16 9152 5048 9700 1980 ? 156894 18:38:35 320 4212 320 3556 con 156894 18:46:16 /usr/bin/ps Funny is that the script gets stuck at various points: $ more /proc//winexename C:\cygwin\bin\lynx.exe C:\cygwin\bin\xmllint.exe C:\cygwin\bin\rm.exe C:\cygwin\bin\cp.exe C:\cygwin\bin\date.exe For each process there are 4-5 threads, one in state Wait::Executive and others in Wait::UserRequest (according to Process Explorer). Have you got any idea what goes wrong? (On top of this writing an automatic script to regularly clean up zombie processes is not straightforward since ps returns process IDs which are not accepted by kill...) Any help is highly appreciated. Cheers, Balazs _________________________________________________________________ Don't just search. Find. Check out the new MSN Search! http://search.msn.com/ -- 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/