From owner-freebsd-questions@FreeBSD.ORG Sun May 20 18:34:48 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1A6AA16A421; Sun, 20 May 2007 18:34:48 +0000 (UTC) (envelope-from youshi10@u.washington.edu) Received: from mxout2.cac.washington.edu (mxout2.cac.washington.edu [140.142.33.4]) by mx1.freebsd.org (Postfix) with ESMTP id E503913C4AD; Sun, 20 May 2007 18:34:47 +0000 (UTC) (envelope-from youshi10@u.washington.edu) Received: from smtp.washington.edu (smtp.washington.edu [140.142.33.7] (may be forged)) by mxout2.cac.washington.edu (8.13.7+UW06.06/8.13.7+UW07.03) with ESMTP id l4KIYlPn025400 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sun, 20 May 2007 11:34:47 -0700 X-Auth-Received: from [192.168.10.45] (c-67-166-149-71.hsd1.ca.comcast.net [67.166.149.71]) (authenticated authid=youshi10) by smtp.washington.edu (8.13.7+UW06.06/8.13.7+UW07.03) with ESMTP id l4KIYkJw018091 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sun, 20 May 2007 11:34:47 -0700 Message-ID: <465094C6.9090602@u.washington.edu> Date: Sun, 20 May 2007 11:34:46 -0700 From: Garrett Cooper User-Agent: Thunderbird 2.0.0.0 (Windows/20070326) MIME-Version: 1.0 To: freebsd-questions@freebsd.org, freebsd-python@freebsd.org References: <46508D23.2040003@xs4all.nl> <20070520183306.GA25051@ayn.mi.celestial.com> In-Reply-To: <20070520183306.GA25051@ayn.mi.celestial.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-PMX-Version: 5.3.1.294258, Antispam-Engine: 2.5.1.298604, Antispam-Data: 2007.5.20.112134 X-Uwash-Spam: Gauge=IIIIIII, Probability=7%, Report='__C230066_P5 0, __CP_URI_IN_BODY 0, __CT 0, __CTE 0, __CT_TEXT_PLAIN 0, __HAS_MSGID 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __SANE_MSGID 0, __USER_AGENT 0' Cc: Subject: Re: kill won't kill X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 May 2007 18:34:48 -0000 Bill Campbell wrote: > On Sun, May 20, 2007, Remko Cijffers wrote: >> Hi, >> >> I'm running a python script which has stopped responding. Killing off >> the process doesn't work: >> >>> # ps -ax | grep nzb | grep -v grep >>> 48426 p1 TLs 136:51.62 /usr/local/bin/python /usr/local/bin/hellanzb.py >>> # kill -SIGKILL 48426 >>> # ps -ax | grep nzb | grep -v grep >>> 48426 p1 TLs 136:51.62 /usr/local/bin/python /usr/local/bin/hellanzb.py >> The only tip I could find seems to reference the 'wait for lock' flag >> ('L' in ps output). A lock could come from samba but restarting the >> daemon doesn't solve the problem. > > Typically unkillable processes are the result of hanging on some file or > device that's waiting on kernel services which never return. > > Using ``lsof -p pid'' to see that the process is using at may give a hint > as to what it's hanging on. > > On Linux systems I frequently use ``strace -p pid'' to see what a process > is doing. I don't know the FreeBSD equivalent of strace. > > Bill > -- > INTERNET: bill@Celestial.COM Bill Campbell; Celestial Software LLC > URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way > FAX: (206) 232-9186 Mercer Island, WA 98040-0820; (206) 236-1676 > > ``We maintain that the very foundation of our way of life is what we call > free enterprise,'' said Cash McCall, "but when one of our citizens > show enough free enterprise to pile up a little of that profit, we do > our best to make him feel that he ought to be ashamed of himself." > -- Cameron Hawley That would be truss(1). strace is also in ports if you prefer to use it. -Garrett