Re: Panic in kern_access

From: Alexander Leidinger <Alexander_at_Leidinger.net>
Date: Tue, 15 Sep 2009 14:24:35 +0200
Quoting Mel Flynn <mel.flynn+fbsd.current_at_mailing.thruhere.net> (from  
Tue, 15 Sep 2009 14:03:50 +0200):

> On Tuesday 15 September 2009 13:14:31 Kostik Belousov wrote:
>> On Mon, Sep 14, 2009 at 08:24:49PM +0200, Mel Flynn wrote:
>> > Hi,
>> >
>> > below some crash info. However, since kib_at_ made some fixes that seem
>> > to relate to this, I shall rebuild my kernel with new sources.
>>
>> No my fixes were related to the issue, AFAIR.
>>
>> > At the time I was building various ports in a jail and asleep, so no
>> > other contributing factors.
>> >
>> > panic: free: address 0xc62e0e00(0xc62e0000) has not been allocated.
>> >
>> > #0  doadump () at pcpu.h:246
>> > 246   pcpu.h: No such file or directory.
>> >    in pcpu.h
>> > (kgdb) #0  doadump () at pcpu.h:246
>> > #1  0xc0642b57 in boot (howto=260) at
>> > /usr/src/sys/kern/kern_shutdown.c:416 #2  0xc0642e49 in panic
>> > (fmt=Variable "fmt" is not available.
>> > ) at /usr/src/sys/kern/kern_shutdown.c:579
>> > #3  0xc062fcfe in free (addr=0x0, mtp=0xc091c330)
>> >     at /usr/src/sys/kern/kern_malloc.c:444
>> > #4  0xc063b018 in crfree (cr=0xc795ea80) at
>> > /usr/src/sys/kern/kern_prot.c:1840
>>
>> I want to see the output of
>> p/x cr
>> and
>> p/x cr->cr_groups
>> from the frame 4.
>
> (kgdb) p/x cr
> $1 = 0xc795ea80
> (kgdb) p/x cr->cr_groups
> $2 = 0xc62e0e00
> (kgdb) p/x *cr->cr_groups
> $3 = 0x0
> (kgdb) p/x *cr
> $4 = {cr_ref = 0x0, cr_uid = 0x0, cr_ruid = 0x0, cr_svuid = 0x0,  
> cr_ngroups = 0x2,
>   cr_rgid = 0x0, cr_svgid = 0x0, cr_uidinfo = 0xc5523380,  
> cr_ruidinfo = 0xc5523380,
>   cr_prison = 0xcc3a0800, cr_pspare = 0x0, cr_flags = 0x0,  
> cr_pspare2 = {0x0, 0x0},
>   cr_label = 0x0, cr_audit = {ai_auid = 0xffffffff, ai_mask =  
> {am_success = 0x0,
>       am_failure = 0x0}, ai_termid = {at_port = 0x0, at_type = 0x4,  
> at_addr = {0x0, 0x0,
>         0x0, 0x0}}, ai_asid = 0x0, ai_flags = 0x0}, cr_groups = 0xc62e0e00,
>   cr_agroups = 0x10}
>
>
> Hmm, since this is in credentials, would it be relevant that I have  
> patched kern_jail.c
> to allow /dev/io access? I don't touch credentials,though and X  
> wasn't running in the jail

I would be very surprised if this is related.

> at the crash time. Just in case, patch is below.

I have a similar patch:  
http://www.leidinger.net/FreeBSD/current-patches/jail.diff

This patch does not contain the necessary change to the DRI driver,  
currently (HEAD) it uses a generic priv, not a dedicated one like in  
my patch. When I tried the DRI stuff my system paniced, I hadn't time  
yet to investigate further. Did you trace hald/X to see what's the  
reason for the long startup time of X in a jail?

Bye,
Alexander.

-- 
If a can of Alpo costs 38 cents, would it cost .50 in Dog Dollars?

http://www.Leidinger.net    Alexander _at_ Leidinger.net: PGP ID = B0063FE7
http://www.FreeBSD.org       netchild _at_ FreeBSD.org  : PGP ID = 72077137
Received on Tue Sep 15 2009 - 10:24:48 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:55 UTC