From owner-freebsd-bugs@FreeBSD.ORG Sat Mar 8 20:48:03 2008 Return-Path: Delivered-To: freebsd-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 C7E961065671; Sat, 8 Mar 2008 20:48:03 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B77C18FC22; Sat, 8 Mar 2008 20:48:03 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from freefall.freebsd.org (rwatson@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m28Km3A6064392; Sat, 8 Mar 2008 20:48:03 GMT (envelope-from rwatson@freefall.freebsd.org) Received: (from rwatson@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m28Km3Sc064388; Sat, 8 Mar 2008 20:48:03 GMT (envelope-from rwatson) Date: Sat, 8 Mar 2008 20:48:03 GMT Message-Id: <200803082048.m28Km3Sc064388@freefall.freebsd.org> To: thomas.stratmann@ruhr-uni-bochum.de, rwatson@FreeBSD.org, freebsd-bugs@FreeBSD.org From: rwatson@FreeBSD.org Cc: Subject: Re: kern/24882: ktrace not syncing .out file before panic X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Mar 2008 20:48:03 -0000 Synopsis: ktrace not syncing .out file before panic State-Changed-From-To: open->closed State-Changed-By: rwatson State-Changed-When: Sat Mar 8 20:44:37 UTC 2008 State-Changed-Why: First off, apologies for the several years it has taken for someone to look at this PR. Unfortunately, I'm going to go ahead and close it, and point you at the kern.sync_on_panic sysctl, which determines whether or not the system tries to sync file systems on panic. As you point out, it is a constant trade-off between performance and stability of data, and ktrace is not generally a tool that is intended to operate properly in the presence of kernel data corruption/panic. What we might want to consider doing is allowing a bound on the amount of un-written ktrace data, sized by data or time, but I'm not sure that will necessarily help the case of usin ktrace to debug things leading up to a panic. Recent FreeBSD versions include a tool, KTR, to help trace those scenarios, and shortly DTrace will also be available. http://www.freebsd.org/cgi/query-pr.cgi?pr=24882