From owner-freebsd-questions Thu Mar 22 0: 3: 0 2001 Delivered-To: freebsd-questions@freebsd.org Received: from lsmls01.we.mediaone.net (lsmls01.we.mediaone.net [24.130.1.20]) by hub.freebsd.org (Postfix) with ESMTP id B859A37B71A for ; Thu, 22 Mar 2001 00:02:54 -0800 (PST) (envelope-from ericmlogan@mediaone.net) Received: from mediaone.net (we-24-130-92-248.we.mediaone.net [24.130.92.248]) by lsmls01.we.mediaone.net (8.11.1/8.11.1) with ESMTP id f2M82re05354; Thu, 22 Mar 2001 00:02:53 -0800 (PST) Message-ID: <3AB9B07F.E6F9D481@mediaone.net> Date: Wed, 21 Mar 2001 23:57:51 -0800 From: Eric M Logan X-Mailer: Mozilla 4.75 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Mike Meyer Cc: questions@freebsd.org Subject: Re: ramdisks and mfs... References: <15033.28284.778431.468125@guru.mired.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG First, thanks for your quick reply. Just one last thing, actually two. Am I correct in assuming that a "pure" ramdisk from /dev/md* is faster than a pseudo ramdisk backed by a swap partition? And, what's the point of the former since it relies on a slow hd? Shouldn't the latter be the preferred way to do ramdisks? Thanks again. Mike Meyer wrote: > Eric M Logan types: > > Is there a difference between /dev/md* and mounting a partition from > > swap. Let me elaborate. I have a swap partition mounted and I have > > /tmp mounted using the same address as that swap partition. Anything I > > put in /tmp will therefore be gone upon reboot. Is this what's > > considered a ramdisk in Freebsd? Or, is using /dev/md* mounted > > somewhere what's known as a ramdisk in FreeBSD? In Linux, it's the > > latter. Any help would be appreciated, thanks. > > I assume you're using mfs for /tmp. Yes, that qualifies as a ramdisk, > even though it's backed by swap. If you don't need the memory back, > it'll act just like a ramdisk. If you do need the memory for something > else, your data will be paged out to swap, and have to be read back > from disk. md isn't backed by swap, so the data is always in ram, > meaning the memory isn't usable by anything else. > > -- > Mike Meyer http://www.mired.org/home/mwm/ > Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message