From owner-freebsd-hackers@FreeBSD.ORG Thu Nov 14 11:34:09 2013 Return-Path: Delivered-To: freebsd-hackers@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 ESMTPS id 836F18BF; Thu, 14 Nov 2013 11:34:09 +0000 (UTC) Received: from mail-ve0-x236.google.com (mail-ve0-x236.google.com [IPv6:2607:f8b0:400c:c01::236]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 3391A2280; Thu, 14 Nov 2013 11:34:09 +0000 (UTC) Received: by mail-ve0-f182.google.com with SMTP id pa12so1722011veb.13 for ; Thu, 14 Nov 2013 03:34:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=CzthCXx/jdIOgJ1rpigDrsfnHfUfIXqjybQBZOMF+uo=; b=XYUIxg8EAc20+rPPXNV0PGo8K9GldHK7JZ/rr+mvtaH3a7NtnDtXHbI25kqw6HtWRT DyAFcXLSGBG5JnFPD0XXFDC0rU/WUyTF5zJCJDBCFZUvnqBFZinVRrSxIMrH6FbZrk4G rjeIZPinHt7iGePauU+7VZghR54aoFSpg7lLYsxue6csUOtSnplxm8z9NBk+0XqLHon6 poRZ4ttB/m8Lf7cQxBx/gxdaAPk5tFQ8AFBC9T0IA61sxD/CwlDxup+7+nTrFOUPA7MP XnWjAQrpLsQI9L5Qsw3GnFP0lnY6Po7pv+Tm8T2R9w8ZhqXas9fPrDk8k6yQxj4WE63F vVzw== MIME-Version: 1.0 X-Received: by 10.52.177.166 with SMTP id cr6mr339685vdc.26.1384428848367; Thu, 14 Nov 2013 03:34:08 -0800 (PST) Received: by 10.220.1.17 with HTTP; Thu, 14 Nov 2013 03:34:08 -0800 (PST) In-Reply-To: References: Date: Thu, 14 Nov 2013 12:34:08 +0100 Message-ID: Subject: Re: Automated submission of kernel panic reports: sysutils/panicmail From: Carlos Jacobo Puga Medina To: freebsd-hackers@freebsd.org, cperciva@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.16 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Nov 2013 11:34:09 -0000 Well, I realized that savecore(8) doesn't work as it should. It's clear that after apply the patch, it changes adequately the order of scripts as follow: % rcorder /etc/rc.d/* | less /etc/rc.d/sysctl /etc/rc.d/hostid /etc/rc.d/zvol /etc/rc.d/dumpon /etc/rc.d/ddb /etc/rc.d/initrandom /etc/rc.d/geli /etc/rc.d/gbde /etc/rc.d/ccd /etc/rc.d/savecore /etc/rc.d/encswap /etc/rc.d/swap1 % swapinfo Device 1K-blocks Used Avail Capacity /dev/ada0p3.eli 3907584 0 3907584 0% Also, /dev/dumpdev is pointing to /dev/ada0p3 % ll /dev/dumpdev lrwxr-xr-x 1 root wheel 11 13 nov 23:51 /dev/dumpdev@ -> /dev/ada0p3 I created a crash dump using "reboot -d" but I see these messages related to savecore at boot stage: savecore: reboot savecore: unable to write to bounds file: Read-only file system savecore: info.0: Read-only file system savecore: unsaved dumps found but not saved No crash dumps in /var/crash. Any suggestions? --CJPM 2013/11/7 Carlos Jacobo Puga Medina > At last, I realized how to solved this inconvenient. Digging a bit I found > what I needed. All is summarized in the pr124747 which describes perfectly > this problem and attached a patch to fix it. > > I add the modified patch according to current rc.d scripts included. > > diff -ur encswap.orig encswap > --- encswap.orig 2013-11-06 23:31:43.000000000 +0100 > +++ encswap 2013-11-07 00:14:03.000000000 +0100 > @@ -3,8 +3,8 @@ > # $FreeBSD: release/9.2.0/etc/rc.d/encswap 180563 2008-07-16 19:22:48Z > dougb $ > # > > -# PROVIDE: disks > -# REQUIRE: initrandom > +# PROVIDE: encswap > +# REQUIRE: initrandom disks > # KEYWORD: nojail > > . /etc/rc.subr > diff -ur savecore.orig savecore > --- savecore.orig 2013-11-06 23:32:21.000000000 +0100 > +++ savecore 2013-11-07 00:14:18.000000000 +0100 > @@ -4,7 +4,7 @@ > # > > # PROVIDE: savecore > -# REQUIRE: dumpon ddb syslogd > +# BEFORE: encswap > # KEYWORD: nojail > > . /etc/rc.subr > diff -ur swap1.orig swap1 > --- swap1.orig 2013-11-06 23:32:28.000000000 +0100 > +++ swap1 2013-11-07 00:14:29.000000000 +0100 > @@ -4,7 +4,7 @@ > # > > # PROVIDE: localswap > -# REQUIRE: disks > +# REQUIRE: encswap disks > # KEYWORD: nojail shutdown > > . /etc/rc.subr > > I tested it and now it works like a charm. > > > 2013/11/5 Carlos Jacobo Puga Medina > >> Add missing thread related to Pawel's proposal [1] >> >> [1] >> http://lists.freebsd.org/pipermail/freebsd-fs/2010-September/009256.html >> >> >> 2013/11/5 Carlos Jacobo Puga Medina >> >>> Seems that rc.d scripts order doesn't allow geli-encrypted swap and >>> dumpdev to cooperate together. For this reason, I wonder what happens in >>> such cases, is not possible to use panicmail unless Pawel's proposal [1] >>> which argued to obtain and save crash info in memory somewhere before we >>> configure swap and copy it to /var/crash/ once we mount it. >>> >>> Is sustainable this proposal or is there yet another alternative to >>> consider for those who use an encrypted GELI swap? >>> >>> --CJPM >>> >> >> >