Stuck CLOSED sockets / sshd / zombies...

John Baldwin jhb at freebsd.org
Thu Apr 3 15:03:59 UTC 2014


On Thursday, April 03, 2014 4:02:21 am Karl Pielorz wrote:
> 
> --On 02 April 2014 14:05 -0400 John Baldwin <jhb at freebsd.org> wrote:
> 
> > Grr, I guess that's what I should have expected.  Was sort of hoping to
> > be able to see which socket it was blocked on.  Can you run 'kgdb' as root
> > (no args), then do 'proc 4346' and 'bt'?  If you are familiar with gdb,
> > walk up to the frame that in sys_read and do 'p *uap' so we can see which
> > fd is being read.
> 
> Ok, think I've done this right (if not, let me know what I should be doing 
> :)
> 
> "
> ...
> (kgdb) up
> #9  0xffffffff80903133 in sys_read (td=<value optimized out>, uap=<value 
> optimized out>) at ../../../kern/sys_generic.c:171
> 171             error = kern_readv(td, uap->fd, &auio);
> (kgdb) p *uap
> $1 = {fd_l_ = 0xfffff800238bb920 "\b\021I\201ÿÿÿÿ", fd = -2125917944, 
> fd_r_ = "ÿÿÿÿ", buf_l_ = 0xfffff800238bb928 "", buf = 
> 0xfffff800237a1000,
>   buf_r_ = 0xfffff800238bb930 "", nbyte_l_ = 0xfffff800238bb930 "", nbyte = 
> 0, nbyte_r_ = 0xfffff800238bb938 "\020\020z#"}

Hmm, that fd value doesn't make any sense now.  Do you have the backtrace for
that process?  The fd may show up in the arguments to kern_readv().

-- 
John Baldwin


More information about the freebsd-hackers mailing list