From stephane@freebsd-fr.org  Wed Dec  8 23:43:29 2004
Return-Path: <stephane@freebsd-fr.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id D1CBF16A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Wed,  8 Dec 2004 23:43:29 +0000 (GMT)
Received: from postfix4-2.free.fr (postfix4-2.free.fr [213.228.0.176])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 78B3943D54
	for <FreeBSD-gnats-submit@freebsd.org>; Wed,  8 Dec 2004 23:43:28 +0000 (GMT)
	(envelope-from stephane@freebsd-fr.org)
Received: from sequoia.mondomaineamoi.megalo (lns-vlq-17f-81-56-170-180.adsl.proxad.net [81.56.170.180])
	by postfix4-2.free.fr (Postfix) with ESMTP id A2F8B24D52F
	for <FreeBSD-gnats-submit@freebsd.org>; Wed,  8 Dec 2004 22:16:48 +0100 (CET)
Received: from sequoia.mondomaineamoi.megalo (localhost.mondomaineamoi.megalo [127.0.0.1])
	by sequoia.mondomaineamoi.megalo (8.13.1/8.13.1) with ESMTP id iB8LGkT4075149
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 8 Dec 2004 22:16:46 +0100 (CET)
	(envelope-from stephane@sequoia.mondomaineamoi.megalo)
Received: (from stephane@localhost)
	by sequoia.mondomaineamoi.megalo (8.13.1/8.13.1/Submit) id iB8LGksh075148;
	Wed, 8 Dec 2004 22:16:46 +0100 (CET)
	(envelope-from stephane)
Message-Id: <200412082116.iB8LGksh075148@sequoia.mondomaineamoi.megalo>
Date: Wed, 8 Dec 2004 22:16:46 +0100 (CET)
From: Stephane Legrand <stephane@freebsd.org>
Reply-To: Stephane Legrand <stephane@freebsd.org>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: Panic after halting the system - vrele: negative ref cnt
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         74877
>Category:       kern
>Synopsis:       Panic after halting the system - vrele: negative ref cnt
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Dec 08 23:50:27 GMT 2004
>Closed-Date:    Sat Nov 17 20:43:06 UTC 2007
>Last-Modified:  Sat Nov 17 20:43:06 UTC 2007
>Originator:     Stephane Legrand
>Release:        FreeBSD 5.3-STABLE i386
>Organization:
>Environment:

System: FreeBSD 5.3-STABLE #10: Fri Nov 26 19:49:00 CET 2004 i386

>Description:

After halting my system, i get the following panic: 

#halt
...
syncing disks, vnodes remaining... 1 1 0 0 0 done
No buffers busy after final sync
ad6: TIMEOUT - READ_DMA retrying (2 retries left) LBA = 15667327
ad6: FAILURE - READ_DMA timed out
panic: vrele: negative ref cnt
KDB: enter: panic
[thread 100191]
stopped at kdb_enter + 0x30: leave
db>trace
kdb_enter (c06b227d, c0702f80, c06b6c8b, d2630bbc, d2630ba8) at kdb_enter + 0x30
panic (c06b6c8b, c20cf190, d2630bb0, c06d4760, c1741600) at panic + 0xd5
vrele (c17d8b58, 1, 0, c20cf190, 0) at vrele + 0x2dc
ffs_unmount (c173f800, 80000, c20cf190, c20cf190, 0) at ffs_unmount + 0x19a
dounmount (c173f800, 80000, c20cf190, c7111aec, 0) at dounmount + 0x284
vfs_unmountall (c7111d68, 0, d2630cbc, c04f4dc6, c0702dc0) at vfs_unmountall + 0x5e
boot (8, 1, c20cd710, c20cf190, 0) at boot + 0x537
reboot (c20cf190, d2630d14, 4, d2630d3c, c0518916) at reboot + 0x67
syscall (2f, 2f, 2f, 0, 650a) at syscall + 0x330
Xint0x80_syscall() at Xint0x80_syscall + 0x1f
---syscall (55, FreeBSD ELF 32, reboot), eip = 0x280ac25b,
   esp = 0xbfbfed1c, ebp = 0xbfbfed68 ---
db>


Note that the ad6 disk was certainly in a standby mode.

# atacontrol cap 3 0
ATA channel 3, Master, device ad6:

Protocol              ATA/ATAPI revision 4
device model          IBM-DJNA-371350
serial number         GM0GMF06050
firmware revision     J76OA30K
cylinders             16383
heads                 16
sectors/track         63
lba supported         26520480 sectors
lba48 not supported       
dma supported
overlap not supported

Feature                      Support  Enable    Value   Vendor
write cache                    yes      yes
read ahead                     yes      yes
dma queued                     yes      yes     31/0x1F
SMART                          yes      yes
microcode download             yes      yes
security                       yes      no
power management               yes      yes
advanced power management      no       no      0/0x00
automatic acoustic management  no       no      0/0x00  0/0x00


>How-To-Repeat:

Don't know. I will see if i get the same panic at my next halt.

>Fix:

Don't know.
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: kmacy 
State-Changed-When: Fri Nov 16 07:20:31 UTC 2007 
State-Changed-Why:  

Sounds like bgfsck + SU. Do you still see this on RELENG_6 after doing a full fsck  
in single user mode? 

http://www.freebsd.org/cgi/query-pr.cgi?pr=74877 
State-Changed-From-To: feedback->closed 
State-Changed-By: kmacy 
State-Changed-When: Sat Nov 17 20:42:42 UTC 2007 
State-Changed-Why:  

Submitter does not see this on RELENG_7. 

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