From owner-freebsd-questions@FreeBSD.ORG Thu Jun 28 23:41:19 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7326816A46D for ; Thu, 28 Jun 2007 23:41:19 +0000 (UTC) (envelope-from pieter@degoeje.nl) Received: from smtp.utwente.nl (smtp2.utsp.utwente.nl [130.89.2.9]) by mx1.freebsd.org (Postfix) with ESMTP id EBAA013C469 for ; Thu, 28 Jun 2007 23:41:18 +0000 (UTC) (envelope-from pieter@degoeje.nl) Received: from lux.student.utwente.nl (lux.student.utwente.nl [130.89.170.81]) by smtp.utwente.nl (8.12.10/SuSE Linux 0.7) with ESMTP id l5SNf7Ug032323; Fri, 29 Jun 2007 01:41:08 +0200 From: Pieter de Goeje To: freebsd-questions@freebsd.org Date: Fri, 29 Jun 2007 01:41:06 +0200 User-Agent: KMail/1.9.6 References: <4D15FF0C-0531-4455-9631-F60D939F9EB2@falconknight.com> In-Reply-To: <4D15FF0C-0531-4455-9631-F60D939F9EB2@falconknight.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200706290141.07063.pieter@degoeje.nl> X-UTwente-MailScanner-Information: Scanned by MailScanner. Contact helpdesk@ITBE.utwente.nl for more information. X-UTwente-MailScanner: Found to be clean X-UTwente-MailScanner-From: pieter@degoeje.nl X-Spam-Status: No Cc: Shawn O'Connor Subject: Re: mdconfig using malloc() X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jun 2007 23:41:19 -0000 On Thursday 28 June 2007, Shawn O'Connor wrote: > Guys, > > I'm trying to do the following: > > mdconfig -a -t malloc -o reserve -s 2g You really don't want to do this. mdconfig will try to allocate 2G of wired memory, which will obviously fail, because you really don't have that much kernel memory available. This might work (with some tweaks) on a 64bit platform however. > > Which fails saying it can't: > > mdconfig: ioctl(/dev/mdctl): Cannot allocate memory > > I saw some old post advocated using -t swap instead, saying that swap > probably wouldn't be used until real memory was consumed. But, on my > 6.2 machine that immediately raises the swap usage to 2GB and does > use disk instead of RAM when I test using it. That's because you used -o reserve. Leave it out and it'll be fine. > > Is there any way I can get 2GB of physical memory actually allocated? > > As a last resort, would upgrading to -CURRENT get this to work? Assuming you want to use the device for a filesystem, you could use tmpfs which is new in current. > > Many thanks! > > -Shawn HTH, Pieter de Goeje