From: Jeff Moyer Subject: Re: stat of /users/no-such-user takes 15 seconds Date: Wed, 30 Nov 2005 22:39:09 -0500 Message-ID: <17294.28765.283390.141086@segfault.boston.redhat.com> References: <1132670358.4039.37.camel@brilong-lnx> <17283.17854.189791.135878@segfault.boston.redhat.com> <17292.42845.186329.808676@segfault.boston.redhat.com> <17294.3164.781525.150155@segfault.boston.redhat.com> Reply-To: jmoyer@redhat.com Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: autofs-bounces@linux.kernel.org Errors-To: autofs-bounces@linux.kernel.org Content-Type: text/plain; charset="us-ascii" To: Ian Kent Cc: autofs@linux.kernel.org ==> Regarding Re: [autofs] stat of /users/no-such-user takes 15 seconds; Ian Kent adds: raven> On Wed, 30 Nov 2005, Jeff Moyer wrote: >> ==> Regarding Re: [autofs] stat of /users/no-such-user takes 15 seconds; >> Ian Kent adds: >> raven> On Tue, 29 Nov 2005, Jeff Moyer wrote: >> >> ==> Regarding Re: [autofs] stat of /users/no-such-user takes 15 >> seconds; >> Ian Kent adds: >> >> raven> On Tue, 22 Nov 2005, Jeff Moyer wrote: >> >> >> ==> Regarding Re: [autofs] stat of /users/no-such-user takes 15 >> >> seconds; Ian Kent adds: >> >> >> >> >> raven> Could you review this patch please Jeff. >> >> After reviewing this further, I did find a problem. See below. >> raven> All good points and the test is wrong. I'll update the patch and raven> post another. >> raven> That just leaves the re-read for the other cases which may be raven> causing a long delay. I'm not sure this slows the lookup unless raven> sending the signal is causing starvation of cpu cycles some raven> how. Perhaps the change from cache_add to cache_update will help raven> more than I think. >> Ian, >> >> The patch I'm attaching is the one against the RHEL autofs package. >> This is what I have come up with, and it is WRONG. =) It causes a >> regression in the case where there are multiple keys of the same name in >> a map; the patched automounter will always use the last key instead of >> the first. Remember dealing with this back in February? Fun. >> >> I'll keep poking at it, I just wanted to make you aware of the problem. raven> I'll check that when I make the patch but I'm fairly sure that I raven> changed the cache code to prevent this at some point. If I can raven> identify that I'll post it and specify it as a pre-patch. I also raven> seem to remember that LDAP lookups were an issue and I still needed raven> to deal with that. Well, ldap maps get tricky, since they don't guarantee the order of the results. Aside from that, I'm not sure what you mean. ;) Basically, you really shouldn't have multiple entries with the same key when using ldap. -Jeff