From owner-freebsd-questions@FreeBSD.ORG Mon Mar 23 19:11:19 2015 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 52713FD9 for ; Mon, 23 Mar 2015 19:11:19 +0000 (UTC) Received: from mail-qg0-x22c.google.com (mail-qg0-x22c.google.com [IPv6:2607:f8b0:400d:c04::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 047B4DE0 for ; Mon, 23 Mar 2015 19:11:19 +0000 (UTC) Received: by qgep97 with SMTP id p97so30509478qge.1 for ; Mon, 23 Mar 2015 12:11:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=fogbsmPmgvLBbz4Q8vTAXeliwX87CMQ7G9qalVz2H84=; b=jKnYzX9ST52tqlSETlmBWI72NlqNb4+kySqcCArGhW2WfkmFF5ukjnDMTt6CI5GZ87 wGNzBAAcmUIJPsPY6jjGx32HZj2f7QZdfWRLr6KyuMqi1g52tS/TdW+X1SD2qE6r+QtH sWn/FtVQaG3ybinrVac+hZkLC2ddLAxZumnuZ4/6xxa0HkuzlkBLftKH2QcA1ElVn5Pv csVWEpJo3mdHfXioJv4y/9gHDcfy2u2FgH2MXe2Si2j1I5B+Ecw/00cEtPTzAOGjGVta Y1k7FkpLDKxfEhFaibixPSiDw7ygVQZkXOjvUCj80z6SIesldl4Ijax1Wu+uhUYAe0q5 i49Q== X-Received: by 10.141.18.208 with SMTP id u199mr836443qhd.47.1427137860892; Mon, 23 Mar 2015 12:11:00 -0700 (PDT) Received: from localhost.localdomain ([209.181.150.218]) by mx.google.com with ESMTPSA id 15sm1089054qhx.31.2015.03.23.12.10.59 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Mar 2015 12:11:00 -0700 (PDT) Message-ID: <55106542.6020503@gmail.com> Date: Mon, 23 Mar 2015 13:10:58 -0600 From: jd1008 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: freebsd-questions@freebsd.org Subject: Re: Un-kill-able process hang at umtxpi state with 100% cpu References: <1427109169038-5999345.post@n5.nabble.com> <1427134474819-5999426.post@n5.nabble.com> <5510594B.6010602@gmail.com> <1427135532406-5999436.post@n5.nabble.com> In-Reply-To: <1427135532406-5999436.post@n5.nabble.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Mar 2015 19:11:19 -0000 On 03/23/2015 12:32 PM, BBlister wrote: > The process named c1 in the home directory of that student, had an > accompanied c1.c file that actually is one that spawn many working pthreads > and synchronizes them at the end. I executed by a normal user > and nothing strange happened. > > So I assume that was a rare timing issue/race condition that triggered this > error. > I will have to upgrade of course to 9.3 in order to rule out old problems. > > So, the takeaway of this is that sometimes when kill -KILL does not work, > kill -STOP may do the job :) About signal 9 (SIGKILL) SIGKILL The SIGKILL signal is sent to a process to cause it to terminate immediately (*kill*). In contrast to SIGTERM and SIGINT, this signal cannot be caught or ignored, and the receiving process cannot perform any clean-up upon receiving this signal. So, the only way a process cannot be killed by a signal 9 is if it is sleeping on an uniterruptible priority (such as when it is holding a lock on a system resource, and sleeps waiting for an even from low lever driver or other process (thread) (which will send a wake signal to the sleeping process). And as soon it is awakened, it is killed and the resource is released. This is why that I suspect that signal STOP did not kill your process that was not killable by SIGKILL (9). What happened is that possibly, the process had woken and the system finally delivered the SIGKILL to to it. I believe you had a conicidence of sending the STOP and then you saw that the process had disappeared. As you know a lot of time can pass (as far as the cpu is concerned) between doing a ps command, seeing the process still running, and then issuing a kill command and then doing ps again to see that the process has disappeared. Cheers JD