From owner-freebsd-hackers Wed Mar 31 15:58:25 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from gatekeeper.tsc.tdk.com (gatekeeper.tsc.tdk.com [207.113.159.21]) by hub.freebsd.org (Postfix) with ESMTP id 034341565F for ; Wed, 31 Mar 1999 15:58:23 -0800 (PST) (envelope-from gdonl@tsc.tdk.com) Received: from sunrise.gv.tsc.tdk.com (root@sunrise.gv.tsc.tdk.com [192.168.241.191]) by gatekeeper.tsc.tdk.com (8.8.8/8.8.8) with ESMTP id PAA26143; Wed, 31 Mar 1999 15:57:51 -0800 (PST) (envelope-from gdonl@tsc.tdk.com) Received: from salsa.gv.tsc.tdk.com (salsa.gv.tsc.tdk.com [192.168.241.194]) by sunrise.gv.tsc.tdk.com (8.8.5/8.8.5) with ESMTP id PAA10016; Wed, 31 Mar 1999 15:57:50 -0800 (PST) Received: (from gdonl@localhost) by salsa.gv.tsc.tdk.com (8.8.5/8.8.5) id PAA22770; Wed, 31 Mar 1999 15:57:48 -0800 (PST) From: Don Lewis Message-Id: <199903312357.PAA22770@salsa.gv.tsc.tdk.com> Date: Wed, 31 Mar 1999 15:57:48 -0800 In-Reply-To: Doug Rabson "Re: Panic in FFS/4.0 as of yesterday" (Feb 23, 8:54am) X-Mailer: Mail User's Shell (7.2.6 alpha(3) 7/19/95) To: Doug Rabson , Don Lewis Subject: Re: Panic in FFS/4.0 as of yesterday Cc: Terry Lambert , dillon@apollo.backplane.com, freebsd-hackers@FreeBSD.ORG Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Feb 23, 8:54am, Doug Rabson wrote: } Subject: Re: Panic in FFS/4.0 as of yesterday } On Mon, 22 Feb 1999, Don Lewis wrote: } } > On Feb 20, 10:52pm, Terry Lambert wrote: } > } Subject: Re: Panic in FFS/4.0 as of yesterday } > } > } > If it works, then changing lookup to not require locks on both vnodes at } > } > the same time would be a good thing. One of the reasons that NFS doesn't } > } > have proper node locks is that a dead NFS server can lead to a hung } > } > machine though a lock cascade from the NFS mount point. } > } > I suggested doing something like this, but only at mount points, which } > should be sufficient to fix the NFS problem. The only race conditions } > that would open would be for things you probably don't want to do } > at mountpoints anyway. } } It sounds as if it might work. Are you interested in coding this? ROFL. Look at how long it's taken me to just respond to this question. The only real downside of making this change that I am aware of is that you won't be able to rename mount points. That might be a feature, though, since renaming mount points causes the mount table to become out of sync with reality. Something else that would greatly help the lock cascade problem and likely help performance under normal circumstances would be to implement shared locks, and only use exclusive locks when something needs to be changed. When doing a pathname lookup, only the final vnode (if it was found) and it's parent directory (if LOCKPARENT was set) would be exclusively locked. The lookup would only use shared locks on the other directories that were traversed. In most cases this would prevent the lock cascade, but the cascade could still happen, probably under artificial circumstances. This change would also allow concurrent lookups in the same directory, which should help performance when multiple processes are active. I suspect this change would not be trivial to implement ... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message