From owner-freebsd-questions@FreeBSD.ORG Mon Mar 23 11:13:03 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 B4782233 for ; Mon, 23 Mar 2015 11:13:03 +0000 (UTC) Received: from mwork.nabble.com (mwork.nabble.com [162.253.133.43]) by mx1.freebsd.org (Postfix) with ESMTP id 9DD8D964 for ; Mon, 23 Mar 2015 11:13:03 +0000 (UTC) Received: from msam.nabble.com (unknown [162.253.133.85]) by mwork.nabble.com (Postfix) with ESMTP id 8B8A1185665F for ; Mon, 23 Mar 2015 04:13:04 -0700 (PDT) Date: Mon, 23 Mar 2015 04:12:49 -0700 (MST) From: BBlister To: freebsd-questions@freebsd.org Message-ID: <1427109169038-5999345.post@n5.nabble.com> Subject: Un-kill-able process hang at umtxpi state with 100% cpu MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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 11:13:03 -0000 Hi, On the FreeBSD multiuser student server that I administer, a student managed to created a program that takes 100% of one of the CPU cores with a process that cannot be killed. uname -a FreeBSD zafora 9.2-STABLE FreeBSD 9.2-STABLE #1 r264312: Thu Apr 10 15:25:33 EEST 2014 root@zafora.icte.uowm.gr:/usr/obj/usr/src/sys/zafora amd64 The process (uses 100% cpu): [root@zafora ~]# ps axuwww | grep 35662 ictest00301 35662 100.0 0.0 12684 1912 19- R Tue04PM 8343:29.56 ./c1 and [root@zafora ~]# procstat 35662 PID PPID PGID SID TSID THR LOGIN WCHAN EMUL COMM 35662 35661 35661 20142 20142 4 ictest00301 umtxpi FreeBSD ELF64 c1 which has the parent process of a make command (I killed the parent process, but nothing happened) ictest00301 35661 0.0 0.0 6280 320 19- I Tue04PM 0:00.01 make execute The specific process is blocked (cannot be killed) with the following wait channels: [root@zafora ~]# procstat -t 35662 PID TID COMM TDNAME CPU PRI STATE WCHAN 35662 100196 c1 - 2 122 sleep umtxpi 35662 100997 c1 - 0 122 sleep umtxpi 35662 101757 c1 - 1 122 sleep uwait 35662 102464 c1 - 2 120 run umtxpi Even though I have implemented resource limits in /etc/login.conf as to the CPU usage, they cannot be enforced, and the server's logfile is filled with messages: Mar 23 13:06:46 zafora kernel: pid 35662 (c1), uid 1100301, was killed: exceeded maximum CPU limit but nothing happens. Of course kill -9 35662 has not effect. How I can kill this process? If one student managed to make an un-killable process that gets 100% of the CPU with restrictions cannot be enforced, then soon the server will be filled with such processes, and a reboot will be mandatory. Thank you. -- View this message in context: http://freebsd.1045724.n5.nabble.com/Un-kill-able-process-hang-at-umtxpi-state-with-100-cpu-tp5999345.html Sent from the freebsd-questions mailing list archive at Nabble.com.