From owner-freebsd-questions@FreeBSD.ORG Wed Sep 11 14:26:09 2013 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 36837603 for ; Wed, 11 Sep 2013 14:26:09 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx02.qsc.de (mx02.qsc.de [213.148.130.14]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id EED1D2EB9 for ; Wed, 11 Sep 2013 14:26:08 +0000 (UTC) Received: from r56.edvax.de (port-92-195-74-65.dynamic.qsc.de [92.195.74.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx02.qsc.de (Postfix) with ESMTPS id 055CF27E53; Wed, 11 Sep 2013 16:26:00 +0200 (CEST) Received: from r56.edvax.de (localhost [127.0.0.1]) by r56.edvax.de (8.14.5/8.14.5) with SMTP id r8BEPrZI005530; Wed, 11 Sep 2013 16:25:53 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Wed, 11 Sep 2013 16:25:53 +0200 From: Polytropon To: Pawel Sulewski Subject: Re: question Message-Id: <20130911162553.51478c63.freebsd@edvax.de> In-Reply-To: <000301ceaec2$55848640$008d92c0$%sulewski@samsung.com> References: <000301ceaec2$55848640$008d92c0$%sulewski@samsung.com> Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Sep 2013 14:26:09 -0000 On Wed, 11 Sep 2013 09:41:31 +0200, Pawel Sulewski wrote: > How to recognize kernel panic and dump memory state onto USB device using C > language? The kernel has its own crash handling and will initiate the writing of the proper image automatically. It will be stored on the partition designated by the /etc/rc.conf setting dumpdev="", usually a swap partition, and at next boot time that image will be written to a file in /var/crash, if nothing else has been defined with dumpdir="" (same file; see "man rc.conf" and /etc/defaults/rc.conf for details). If you want to coredump to a USB device, you need to configure this accordingly. You can find more information about this topic in the following manual pages: "man 2 sigaction", "man 8 crash", and "man 5 core". -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...