From owner-cvs-all Mon Dec 18 22:32:53 2000 From owner-cvs-all@FreeBSD.ORG Mon Dec 18 22:32:50 2000 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from beastie.mckusick.com (beastie.mckusick.com [209.31.233.184]) by hub.freebsd.org (Postfix) with ESMTP id 3100337B400; Mon, 18 Dec 2000 22:32:50 -0800 (PST) Received: from beastie.mckusick.com (localhost [127.0.0.1]) by beastie.mckusick.com (8.9.3/8.9.3) with ESMTP id WAA29113; Mon, 18 Dec 2000 22:32:47 -0800 (PST) (envelope-from mckusick@beastie.mckusick.com) Message-Id: <200012190632.WAA29113@beastie.mckusick.com> To: Alfred Perlstein Subject: Re: cvs commit: src/sys/ufs/ffs ... Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org In-Reply-To: Your message of "Wed, 13 Dec 2000 00:54:20 PST." <20001213005420.Z16205@fw.wintelcom.net> Date: Mon, 18 Dec 2000 22:32:47 -0800 From: Kirk McKusick Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Date: Wed, 13 Dec 2000 00:54:20 -0800 From: Alfred Perlstein To: Kirk McKusick Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/ufs/ffs ... Possible, but this doesn't seem like it will always do the job. Why not implement a max amount of requests and block processes who want to add until the threshhold goes below some mark? -- -Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org] "I have the heart of a child; I keep it in a jar on my desk." At the time that we are trying to allocate a soft dependency structure, we are deep in the filesystem code holding one or more vnodes locked. If we hold up a process for more than a short time, we run the risk of getting a lock race to the root. For this reason, it is not really possible to hold up any given process for more than a few tens of milliseconds. What this code does accomplish is to ensure that at a time of excessive resouce usage, we free at least as many structures as we allocate (and usually free more than we allocate). So, on each pass into the filesystem things can get no worse and typically get better. This code has been tested on some phenominally busy servers at Yahoo and has made it through comfortably, so I am pretty confident that it will do the right thing. Kirk To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message