From owner-freebsd-small Sun Feb 11 16:58:50 2001 Delivered-To: freebsd-small@freebsd.org Received: from peorth.iteration.net (peorth.iteration.net [208.190.180.178]) by hub.freebsd.org (Postfix) with ESMTP id BC78637B401; Sun, 11 Feb 2001 16:58:45 -0800 (PST) Received: by peorth.iteration.net (Postfix, from userid 1001) id CC8A657650; Sun, 11 Feb 2001 18:58:52 -0600 (CST) Date: Sun, 11 Feb 2001 18:58:52 -0600 From: "Michael C . Wu" To: "Forrest W. Christian" Cc: freebsd-small@freebsd.org, dillon@freebsd.org Subject: Re: Sans-Swap VM Subsystem Questions Message-ID: <20010211185852.F19845@peorth.iteration.net> Reply-To: "Michael C . Wu" Mail-Followup-To: "Michael C . Wu" , "Forrest W. Christian" , freebsd-small@freebsd.org, dillon@freebsd.org References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from forrestc@imach.com on Sun, Feb 11, 2001 at 12:13:24AM -0700 X-PGP-Fingerprint: 5025 F691 F943 8128 48A8 5025 77CE 29C5 8FA1 2E20 X-PGP-Key-ID: 0x8FA12E20 Sender: owner-freebsd-small@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG The general idea is that many parts of FreeBSD sometimes count on having swap and such. Can you use some part of the flash disk for swap? i.e. if (no_swap == TRUE) {bad_things_happen(); return ENOTVERYGOOD;} On Sun, Feb 11, 2001 at 12:13:24AM -0700, Forrest W. Christian scribbled: | I asked this (phrased differently) over in -hackers as I thought the | people who would know were likely among that crowd. I didn't get a | response, and in retrospect, it's probably better asked here anyways. | | I'm currently working on a system with a rather large flash disk, Limited | RAM, and absolutely no swap. | | Some background first: | | The FreeBSD VM subsystem in it's "normal" state understands that if it | loads a program off of disk and then gets tight on memory that it can free | the memory consumed by the non-changed code of the program without | swapping to disk as it knows that it can just re-load it from the disk | where it found it. | | In my system, since I don't have swap, and limited memory, I would like to | ensure that the above described piece of the VM subsystem continues to | work. That way, it can effectively "run from flash" if necessary. | However, as memory is (always) tight in this environment, I would | also like to remove the SWAPPING code (as opposed to the "free" code | described above) from the kernel. I believe there is a NO_SWAP option in LINT/NOTES. However, I remember Peter Wemm stating in a certain forum that do such things is BAD(TM). | So, my question was what, if anything, does "options NO_SWAPPING" (or | whatever the exact option is) do in regards to the vm "free" chunk of | code? Same thing as you want. | I'd also like to hear people's experience with running with and without | the two swap-related kernel variables turned on without swap. I realize The performance decreases drastically with no VM on. I am not the VM expert, but I think it is true. I have CC'ed Matt Dillon, our VM guru, just to make sure. :) | that the general consensus is to "enable" both delay and disable swap | pagesouts. -- +------------------------------------------------------------------+ | keichii@peorth.iteration.net | keichii@bsdconspiracy.net | | http://peorth.iteration.net/~keichii | Yes, BSD is a conspiracy. | +------------------------------------------------------------------+ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-small" in the body of the message