Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 31 May 2007 21:05:55 +0300
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        Robert Watson <rwatson@freebsd.org>
Cc:        current@freebsd.org
Subject:   Re: watch(8) stuck in devdrn
Message-ID:  <20070531180555.GA10910@kobe.laptop>
In-Reply-To: <20070531183719.B77697@fledge.watson.org>
References:  <20070531183719.B77697@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2007-05-31 18:38, Robert Watson <rwatson@freebsd.org> wrote:
> I was using watch(8) this afternoon, and on trying to quit, ran into this:
>
>   peppercorn:~> ps axl | grep watch
>     0 14200 14194   0  -8  0  3416  1056 devdrn D     p2-   0:00.01 watch -W tt
>
> It was running on a pty, but the target tty was ttyv1.

If you have kern.pts.enable=1 you may have to use:
http://hg.hellug.gr/freebsd/src-keramida/file/944ac3982de1/pty-devdrn

Without this patch and kern.pts.enable=1 all ptys seem to get stuck in
devdrn on process exit.  AFAIK, Kostik Belousov and Tor Egge know this
and are already working on a fix:

% Date: Fri, 6 Apr 2007 13:10:48 +0300
% Message-ID: <20070406101048.GK308@deviant.kiev.zoral.com.ua>
% From: Kostik Belousov
% Subject: Re: pty releasing but with kern.pts.enable=1?
% To: Giorgos Keramidas
% 
% [-- The following data is signed --]
% 
% On Fri, Apr 06, 2007 at 03:45:29AM +0300, Giorgos Keramidas wrote:
% > Hi Konstantin,
% >
% > Kris Kennaway suggested I contact you, to ask about a possible pty bug
% > in FreeBSD CVS HEAD.  Without the patch below, every time I exit from a
% > process using pty's the process blocks forever.
% >
% > http://people.freebsd.org/~keramida/ptsbug.diff
% >
% > Do you have any idea why dev->si_threadcount never reaches zero for pty
% > devices, or how I can statr troubleshooting this further?
% 
% Yes, the issue is known (drivers must not call destroy_dev() from d_close
% method). The patch is being worked on with the help of Tor Egge.
% 
% [-- End of signed data --]



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070531180555.GA10910>