From owner-freebsd-stable Sun Apr 5 19:24:18 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id TAA00303 for freebsd-stable-outgoing; Sun, 5 Apr 1998 19:24:18 -0700 (PDT) (envelope-from owner-freebsd-stable@FreeBSD.ORG) Received: from implode.root.com (implode.root.com [198.145.90.17]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id TAA00249; Sun, 5 Apr 1998 19:24:01 -0700 (PDT) (envelope-from root@implode.root.com) Received: from implode.root.com (localhost [127.0.0.1]) by implode.root.com (8.8.5/8.8.5) with ESMTP id TAA17549; Sun, 5 Apr 1998 19:22:47 -0700 (PDT) Message-Id: <199804060222.TAA17549@implode.root.com> To: "David E. Tweten" cc: Dan Swartzendruber , dyson@FreeBSD.ORG, dag-erli@ifi.uio.no, stable@FreeBSD.ORG Subject: Re: swap-leak in 2.2.5 ? In-reply-to: Your message of "Sun, 05 Apr 1998 18:40:39 PDT." <199804060140.SAA03046@ns.frihet.com> From: David Greenman Reply-To: dg@root.com Date: Sun, 05 Apr 1998 19:22:47 -0700 Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk >dswartz@druber.com said: >>Here's an off-the-cuff idea: since the confusing usage of swap as a >>caching mechanism is only a performance optimization, how bogus would >>it be to not report it. Lie. If my workstation has 64MB of swap set >>up, 8 of which is being used for real backing store, and 12 of which >>is being used to cache filesystem pages, have swapinfo lie and report >>only 8MB in use. > >The 4.4 BSD interaction between physical pages used for virtual memory and >physical pages used for file system cache doesn't work that way, and I can't >imagine the FreeBSD core team adding in such a botch. It is never a good >idea to send a dirty file system cache page to swap. ...and of course we didn't. I don't know where the confusion started on this, but what we page out to swap is the same thing we've always paged out to swap: 'anonymous' memory that is not backed by a file. Modified file pages (non-COW) are backed by the file and are never written to swap. >What you see in swap under heavy I/O load, is dirty process virtual memory >pages moved out of real memory to make way for an expanding file system >cache. There's no reason to read them back until the process faults for >them; it might exit first, allowing you to just abandon them. Right. -DG David Greenman Core-team/Principal Architect, The FreeBSD Project To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message