Re: random(4) related panic: sleeping without a mutex

From: Simon L. Nielsen <simon_at_FreeBSD.org>
Date: Mon, 12 Apr 2004 10:59:55 +0200
On 2004.04.12 00:59:23 +0100, Mark Murray wrote:
> "Simon L. Nielsen" writes:
> > I getting the following panic on my Soekris Net4801 box right after init
> > has been started:
> > 
> > Mounting root from ufs:/dev/ad0s1a
> > start_init: trying /sbin/init
> > panic: sleeping without a mutex
> > at line 144 in file /data/nanobsd/src/sys/kern/kern_synch.c
> > Debugger("panic")
> > Stopped at      Debugger+0x45:  xchgl   %ebx,in_Debugger.0
> 
> Could you please try the enclosed patch?

It fixes the panic, but now it just hangs after init.  I think it's when
creating the /etc memory disk.  I can continue by pressing ctrl-c so
it's not totally hung.  The last part of the boot message with a few
ctrl-t's :

Mounting root from ufs:/dev/ad0s1a                                              
load: 0.46  cmd: newfs 63 [block] 0.00u 0.06s 0% 776k
load: 0.42  cmd: newfs 63 [block] 0.00u 0.06s 0% 776k
load: 0.12  cmd: newfs 63 [block] 0.00u 0.06s 0% 776k

I tried to boot both my working kernel (Apr 4) and the new one in single
user mode.  The sysctl output for kern.random looks interesting since
the old one was seeded, and the new one isn't:

FreeBSD 5.2-CURRENT #6: Sun Apr  4 16:56:40 CEST 2004
# sysctl kern.random
kern.random.sys.seeded: 1
kern.random.sys.harvest.ethernet: 0
kern.random.sys.harvest.point_to_point: 0
kern.random.sys.harvest.interrupt: 0
kern.random.sys.harvest.swi: 0
kern.random.yarrow.gengateinterval: 10
kern.random.yarrow.bins: 10
kern.random.yarrow.fastthresh: 192
kern.random.yarrow.slowthresh: 256
kern.random.yarrow.slowoverthresh: 2

FreeBSD 5.2-CURRENT #1: Mon Apr 12 10:00:00 CEST 2004 :
# sysctl kern.random
kern.random.yarrow.gengateinterval: 10
kern.random.yarrow.bins: 10           
kern.random.yarrow.fastthresh: 192
kern.random.yarrow.slowthresh: 256
kern.random.yarrow.slowoverthresh: 2
kern.random.sys.seeded: 0
kern.random.sys.harvest.ethernet: 0
kern.random.sys.harvest.point_to_point: 0
kern.random.sys.harvest.interrupt: 0     
kern.random.sys.harvest.swi: 0      

Since it doesn't harvest I guess it's not that strange that it isn't
seeded, but since it worked before something must have changed.

-- 
Simon L. Nielsen
FreeBSD Documentation Team

Received on Sun Apr 11 2004 - 23:59:58 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:50 UTC