From owner-freebsd-hackers Fri Jul 5 14:29:31 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DDCE437B401 for ; Fri, 5 Jul 2002 14:29:28 -0700 (PDT) Received: from ns.aus.com (adsl-64-175-247-226.dsl.sntc01.pacbell.net [64.175.247.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 72F0043E31 for ; Fri, 5 Jul 2002 14:29:28 -0700 (PDT) (envelope-from rsharpe@ns.aus.com) Received: from localhost (rsharpe@localhost) by ns.aus.com (8.11.6/8.11.6) with ESMTP id g65MfPS03996; Sat, 6 Jul 2002 08:11:25 +0930 Date: Sat, 6 Jul 2002 08:11:25 +0930 (CST) From: Richard Sharpe To: Garance A Drosihn Cc: Subject: Re: Adding readdir entries to the name cache ... In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 5 Jul 2002, Garance A Drosihn wrote: > At 6:29 AM +0930 7/6/02, Richard Sharpe wrote: > >Hmmm, I think that the major part of the problem there was that, > >for what ever reason, Barry Feigenbaum of IBM, declined to add > >a Change Working Directory or Set Working Diretory command to > >the SMB protocol. > > > >Thus, at least for the SMB protocol, and maybe generally, Windows > >clients must always send the full pathname for every file they > >want, unless it happens to be at the root of the share. > > Could the unix process for samba fake that? Keep track of the > most recently used directory, and when a new request comes in > split it into "directory" plus "filename", and if the directory > is the same as the previous one, then just access the filename. > If the directory is different, try to do a chdir() to the new > directory, and if that succeeds then save that as the "previous" > directory. Yes it can do that, and should do that. I will have to check what Samba does. I know I proposed adding a path cache to smbclient/smbtar so that it could avoid repeatedly, and even a cache of one path could make a big difference. > Or is that more trouble than it's worth? No, I think it is worth a lot. I suspect Samba already does that. There is just so much code to look at. Regards ----- Richard Sharpe, rsharpe@ns.aus.com, rsharpe@samba.org, sharpe@ethereal.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message