From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Aug 16 00:50:09 2011 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A333C106566B for ; Tue, 16 Aug 2011 00:50:09 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 7EF478FC0C for ; Tue, 16 Aug 2011 00:50:09 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p7G0o9rq077627 for ; Tue, 16 Aug 2011 00:50:09 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p7G0o9bl077626; Tue, 16 Aug 2011 00:50:09 GMT (envelope-from gnats) Resent-Date: Tue, 16 Aug 2011 00:50:09 GMT Resent-Message-Id: <201108160050.p7G0o9bl077626@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, John Hickey Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E5B9F1065674 for ; Tue, 16 Aug 2011 00:45:52 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id BB1598FC14 for ; Tue, 16 Aug 2011 00:45:52 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id p7G0jqRD042482 for ; Tue, 16 Aug 2011 00:45:52 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id p7G0jqb0042474; Tue, 16 Aug 2011 00:45:52 GMT (envelope-from nobody) Message-Id: <201108160045.p7G0jqb0042474@red.freebsd.org> Date: Tue, 16 Aug 2011 00:45:52 GMT From: John Hickey To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/159807: RC file for mrouted causes kernel panic by running before devd is up. X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Aug 2011 00:50:09 -0000 >Number: 159807 >Category: ports >Synopsis: RC file for mrouted causes kernel panic by running before devd is up. >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Aug 16 00:50:09 UTC 2011 >Closed-Date: >Last-Modified: >Originator: John Hickey >Release: 8.2-STABLE >Organization: ISI - USC >Environment: FreeBSD router 8.2-STABLE FreeBSD 8.2-STABLE #1: Fri Jul 29 18:42:53 UTC 2011 root@router:/usr/obj/usr/src/sys/ROUTER i386 >Description: mrouted gets started before devd. This results in a kernel panic: .... <118>em3: flags=8843 metric 0 mtu 1500 <118> options=9b <118> ether 00:0c:29:88:f7:ce <118> inet 192.168.254.254 netmask 0xffffff00 broadcast 192.168.254.255 <118> media: Ethernet autoselect (1000baseT ) <118> status: active <118>Additional routing options: <118> IP gateway=YES <118>. <118>Starting mrouted. <118>Starting devd. 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:0xc095c1f8 stack pointer = 0x28:0xe6c3eb30 frame pointer = 0x28:0xe6c3eb30 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 = 543 (devd) trap number = 12 panic: page fault cpuid = 0 KDB: stack backtrace: #0 0xc08ec597 at kdb_backtrace+0x47 #1 0xc08bcbf7 at panic+0x117 #2 0xc0bfc043 at trap_fatal+0x323 #3 0xc0bfc2a0 at trap_pfault+0x250 #4 0xc0bfc7c3 at trap+0x443 #5 0xc0be364c at calltrap+0x6 #6 0xc08e6ae3 at devread+0x193 #7 0xc087836c at giant_read+0x8c #8 0xc083c5ae at devfs_read_f+0x7e #9 0xc08fca96 at dofileread+0x96 #10 0xc08fce18 at kern_readv+0x58 #11 0xc08fcf0f at read+0x4f #12 0xc08f8b79 at syscallenter+0x329 #13 0xc0bfc2f4 at syscall+0x34 #14 0xc0be36b1 at Xint0x80_syscall+0x21 Uptime: 11s Physical memory: 1007 MB Dumping 59 MB: 44 28 12 #0 doadump () at pcpu.h:231 231 pcpu.h: No such file or directory. in pcpu.h (kgdb) >How-To-Repeat: Enable mrouted in rc.conf. Reboot system. Panic ensues. >Fix: We need to make sure that the rc script for mrouted depends on devd. diff -u mrouted.in.orig mrouted.in --- mrouted.in.orig 2011-08-15 17:39:01.000000000 -0700 +++ mrouted.in 2011-08-15 17:39:07.000000000 -0700 @@ -5,7 +5,7 @@ # # PROVIDE: mrouted -# REQUIRE: netif routing cleanvar +# REQUIRE: netif routing cleanvar devd # KEYWORD: nojail . /etc/rc.subr >Release-Note: >Audit-Trail: >Unformatted: