From owner-freebsd-stable@FreeBSD.ORG Wed Mar 19 17:47:17 2014 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D6CC2831 for ; Wed, 19 Mar 2014 17:47:17 +0000 (UTC) Received: from mail.bsdinfo.com.br (mail.bsdinfo.com.br [67.212.89.78]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9FF997A2 for ; Wed, 19 Mar 2014 17:47:17 +0000 (UTC) Received: from mail.bsdinfo.com.br (mail.bsdinfo.com.br [127.0.0.1]) by mail.bsdinfo.com.br (Postfix) with ESMTP id 4998C139C4 for ; Wed, 19 Mar 2014 17:49:52 -0300 (BRT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=bsdinfo.com.br; h=content-transfer-encoding:content-type:content-type :in-reply-to:references:subject:subject:to:mime-version :user-agent:from:from:date:date:message-id; s=dkim; t= 1395262190; x=1396126191; bh=nBjC0V6ut+IU2Id4zbB2mGc+AUTeWJ/lVBb ULkOc54M=; b=I/rkT2nGSGiVK4uIolOx7JpQrMcxCzUP0WJ1AdS3lHiX5KvF+Fr uWeMTTalh9GRyHnucS/MXv2gfqva9kALzDNkQKt3z02YlI0pIMxKPbtWGhcK9DH1 eoM1i7IpZ2loBHH7Yj1sA16HuYeGw355XKDMgwB5CQLsXD1ToHNJj+1Y= X-Virus-Scanned: amavisd-new at mail.bsdinfo.com.br Received: from mail.bsdinfo.com.br ([127.0.0.1]) by mail.bsdinfo.com.br (mail.bsdinfo.com.br [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id R_KPBVH3pwLs for ; Wed, 19 Mar 2014 17:49:50 -0300 (BRT) Received: from MacBook-de-Gondim-2.local (unknown [186.193.48.8]) by mail.bsdinfo.com.br (Postfix) with ESMTPSA id B2F68139C3 for ; Wed, 19 Mar 2014 17:49:49 -0300 (BRT) Message-ID: <5329D81E.7040709@bsdinfo.com.br> Date: Wed, 19 Mar 2014 14:47:10 -0300 From: Marcelo Gondim User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 MIME-Version: 1.0 To: FreeBSD Stable Mailing List Subject: Re: sshd with zombie process on FreeBSD 10.0-STABLE - workaround References: <53016D97.5030909@bsdinfo.com.br> <53066B59.5000709@yandex.ru> <531A6C66.2010101@bsdinfo.com.br> <53298445.90706@bsdinfo.com.br> <532994EA.9090300@bsdinfo.com.br> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Mar 2014 17:47:17 -0000 Em 19/03/14 13:01, Kevin Oberman escreveu: > On Wed, Mar 19, 2014 at 6:00 AM, Marcelo Gondim wrote: > >> Hi all, >> >> While the solution does not appear, did the script below and put it in >> crontab to automatically delete zombie sshd processes. >> >> the_walking_dead.sh: >> >> #!/bin/sh >> kill -9 `ps afx|grep sshd|grep unknown|awk '{print $1}'` >> >> >> Put this in /etc/crontab: >> >> 00 1 * * * root the_walking_dead.sh >> >> > If 'kill -9' works, the process is not really a zombie. It simply still has > a socket open and is waiting for it to be closed before exiting. > > You might takes a look at network sockets with sockstat(1) and see if you > can get any indication of why these sockets are not being closed. It may be > that the issue is not sshd but some other issue in the OS leaving sockets > open. > Hi Kevin, My ps -afx below: [...] 42139 - Is 0:00.01 sshd: unknown [priv] (sshd) 42140 - Z 0:00.01 42141 - IW 0:00.00 sshd: unknown [pam] (sshd) 58445 - Is 0:00.01 sshd: unknown [priv] (sshd) 58446 - Z 0:00.02 58447 - IW 0:00.00 sshd: unknown [pam] (sshd) 65635 - Is 0:00.01 sshd: vinicius [priv] (sshd) 65636 - Z 0:00.01 [...] # sockstat | grep 42140 # # sockstat | grep 58446 # # sockstat | grep 65636 # No associated socket with zombie process.