From owner-freebsd-stable@FreeBSD.ORG Tue Feb 27 21:03:32 2007 Return-Path: X-Original-To: stable@freebsd.org Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 32DD016A403 for ; Tue, 27 Feb 2007 21:03:32 +0000 (UTC) (envelope-from mi+kde@aldan.algebra.com) Received: from aldan.algebra.com (aldan.algebra.com [216.254.65.224]) by mx1.freebsd.org (Postfix) with ESMTP id D188413C4B8 for ; Tue, 27 Feb 2007 21:03:31 +0000 (UTC) (envelope-from mi+kde@aldan.algebra.com) Received: from aldan.algebra.com (aldan [127.0.0.1]) by aldan.algebra.com (8.13.8/8.13.8) with ESMTP id l1RL3VS4038490 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 27 Feb 2007 16:03:31 -0500 (EST) (envelope-from mi+kde@aldan.algebra.com) Received: from localhost (localhost [[UNIX: localhost]]) by aldan.algebra.com (8.13.8/8.13.8/Submit) id l1RL3Ux5038489; Tue, 27 Feb 2007 16:03:30 -0500 (EST) (envelope-from mi+kde@aldan.algebra.com) From: Mikhail Teterin To: Alex Kozlov Date: Tue, 27 Feb 2007 16:03:30 -0500 User-Agent: KMail/1.9.5 References: <20070227205351.GA72597@ravenloft.kiev.ua> In-Reply-To: <20070227205351.GA72597@ravenloft.kiev.ua> X-Face: %UW#n0|w>ydeGt/b@1-.UFP=K^~-:0f#O:D7whJ5G_<5143Bb3kOIs9XpX+"V+~$adGP:J|SLieM31VIhqXeLBli" Cc: stable@freebsd.org Subject: Re: panic: kmem_malloc(16384): kmem_map too small: md-mounted /tmp filled up X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Feb 2007 21:03:32 -0000 On Tuesday 27 February 2007 15:53, Alex Kozlov wrote: = > Yes, I switched to swap-backed md already. But the malloc-based variety is = > currently the _default_ (see /etc/defaults/rc.conf)... = Bad default. Filing a PR. = > Creation of a 2Gb malloc-based md should've failed on a machine with = > 768Mb of RAM, shouldn't it have? = Only if you set '-o reserve'. Memory for malloc-based md was allocated = dynamically. But malloc can only allocate from RAM, right? So the amount of RAM is the hard limit, which a malloc-based md can not exceed even in theory. This means, md-creation should've failed... In fact, the limit should, of course, be even lower -- and mdmfs should be smart enough to substract the sizes of other kernel memory chunks from the maximum. Since even that would still not be a guarantee against running out, the system should be able to recover gracefully instead of panicing. Do you agree? -mi