From owner-svn-src-head@FreeBSD.ORG Tue Dec 18 20:44:52 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7F1451A3; Tue, 18 Dec 2012 20:44:52 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 4D2CB8FC0C; Tue, 18 Dec 2012 20:44:52 +0000 (UTC) Received: from pakbsde14.localnet (unknown [38.105.238.108]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id AC24CB94B; Tue, 18 Dec 2012 15:44:51 -0500 (EST) From: John Baldwin To: Pawel Jakub Dawidek Subject: Re: svn commit: r244320 - head/sbin/savecore Date: Tue, 18 Dec 2012 14:08:17 -0500 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p22; KDE/4.5.5; amd64; ; ) References: <201212162306.qBGN6CZR069280@svn.freebsd.org> In-Reply-To: <201212162306.qBGN6CZR069280@svn.freebsd.org> MIME-Version: 1.0 Message-Id: <201212181408.18179.jhb@freebsd.org> Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Tue, 18 Dec 2012 15:44:51 -0500 (EST) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Dec 2012 20:44:52 -0000 On Sunday, December 16, 2012 6:06:12 pm Pawel Jakub Dawidek wrote: > Author: pjd > Date: Sun Dec 16 23:06:12 2012 > New Revision: 244320 > URL: http://svnweb.freebsd.org/changeset/base/244320 > > Log: > Implement -m option to savecore(8) that allows to limit number of kernel > dumps stored. Once the limit is reached it restarts from 0. Why restart at zero? The old behavior is that if you rm'd /var/crash/vmcore.0 then new dumps would just get increasing numbers. That seems fine (just delete the "oldest" core dumps if you are out of room). I guess the restarting lets you be lazy and avoid finding the "oldest" dump via a glob, but: The real feature request was not a limit on the number of core dumps IIRC, but a way to specify a minimum amount of free space in the partition and to delete tne oldest dump if the new dump would put the partition over the limit. To do this you have to be able to find the "oldest" dump, so if you solve this you no longer have to rely on rotating names (and no longer need a 'last' link). -- John Baldwin