From nobody@FreeBSD.org  Sun Aug  8 06:43:14 2010
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 5945E106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Aug 2010 06:43:14 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 2D23E8FC14
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Aug 2010 06:43:14 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o786hDxA091759
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 8 Aug 2010 06:43:13 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id o786hDwB091758;
	Sun, 8 Aug 2010 06:43:13 GMT
	(envelope-from nobody)
Message-Id: <201008080643.o786hDwB091758@www.freebsd.org>
Date: Sun, 8 Aug 2010 06:43:13 GMT
From: Sergey <s@swa.org.ru>
To: freebsd-gnats-submit@FreeBSD.org
Subject: writing to the net/samba* share on any sysutils/fusefs-* resource leads to kernel panic
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         149411
>Category:       ports
>Synopsis:       sysutils/fusefs-unionfs: writing to the net/samba* share on any sysutils/fusefs-* resource leads to kernel panic
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    clsung
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Aug 08 06:50:04 UTC 2010
>Closed-Date:    Wed Feb 09 01:30:13 UTC 2011
>Last-Modified:  Wed Feb 09 01:30:13 UTC 2011
>Originator:     Sergey
>Release:        8.0-8.1
>Organization:
ARB Consulting
>Environment:
FreeBSD office.a-r-b.ru 8.0-STABLE FreeBSD 8.0-STABLE #0: Thu Mar 18 00:18:04 YEKT 2010     root@arb:/data/obj/usr/src/sys/arb  i386
reproduced on amd64 aswell
>Description:
I'm getting kernel panics everytime I try to write a file to samba share which is a fuse mount.
I tried samba 3.0.37, 3.3.13, 3.4.8

Fatal trap 12: page fault while in kernel mode
cpuid = 0; apic id = 00
fault virtual address   = 0x0
fault code              = supervisor read, page not present
instruction pointer     = 0x20:0x0
stack pointer           = 0x28:0xe67bbc44
frame pointer           = 0x28:0xe67bbc68
code segment            = base 0x0, limit 0xfffff, type 0x1b
                        = DPL 0, pres 1, def32 1, gran 1
processor eflags        = interrupt enabled, resume, IOPL = 0
current process         = 1237 (smbd)
trap number             = 12
panic: page fault
cpuid = 1
Uptime: 14m23s
Physical memory: 1011 MB
Dumping 73 MB: 58panic: bufwrite: buffer is not busy???
cpuid = 1
 42 26 10

Reading symbols from /usr/local/modules/fuse.ko...done.
Loaded symbols for /usr/local/modules/fuse.ko
#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  0xc08a1d47 in boot (howto=260) at /usr/src/sys/kern/kern_shutdown.c:416
#2  0xc08a1fa9 in panic (fmt=Variable "fmt" is not available.
) at /usr/src/sys/kern/kern_shutdown.c:590
#3  0xc0bd72bc in trap_fatal (frame=0xe67bbc04, eva=0)
    at /usr/src/sys/i386/i386/trap.c:938
#4  0xc0bd7540 in trap_pfault (frame=0xe67bbc04, usermode=0, eva=0)
    at /usr/src/sys/i386/i386/trap.c:851
#5  0xc0bd7e85 in trap (frame=0xe67bbc04) at /usr/src/sys/i386/i386/trap.c:533
#6  0xc0bb9e7c in calltrap () at /usr/src/sys/i386/i386/exception.s:166
#7  0x00000000 in ?? ()
Previous frame inner to this frame (corrupt stack?)
(kgdb) 
>How-To-Repeat:
1. Install /usr/ports/net/samba34, /usr/ports/sysutils/fusefs-unionfs
2. Add to default samba config:
security = user
[test]
path = /test
public = yes
writeable = yes

3. unionfs -o allow_other /tmp /test
4. smbclient //IP/test
put <some file>

There we get a panic
>Fix:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->clsung 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Sun Aug 8 19:18:26 UTC 2010 
Responsible-Changed-Why:  
Attempt to guess which port is causing the problem, and assign. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=149411 

From: Sergey Nikolenko <s@swa.org.ru>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/149411: sysutils/fusefs-unionfs: writing to the net/samba*
 share on any sysutils/fusefs-* resource leads to kernel panic
Date: Thu, 23 Sep 2010 17:26:26 +0600

 Looks like http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/149674 
 solves the problem
State-Changed-From-To: open->closed 
State-Changed-By: clsung 
State-Changed-When: Wed Feb 9 01:29:34 UTC 2011 
State-Changed-Why:  
Closed. Solved via ports/149674 (fix on sysutils/fusefs-kmod). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=149411 
>Unformatted:
