delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/03/19/15:49:35

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=0.1 required=5.0 tests=AWL,BAYES_40,J_CHICKENPOX_66
X-Spam-Check-By: sourceware.org
Message-ID: <49C2AFD1.6060000@princeton.edu>
Date: Thu, 19 Mar 2009 16:49:21 -0400
From: Vinod Gupta <vinod AT Princeton DOT EDU>
User-Agent: Thunderbird 1.5.0.12 (X11/20090107)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: ls -lR too slow
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

> Dave Korn wrote:
>> Vinod Gupta wrote:
>>
>>> When I do "ls -lR /cygdrive/z" it takes very long.
>>> There are only about 700 files on Z: totalling only 100 MB. When I
>>> monitor network counters on laptop, I see that a whopping 90 MB were
>>> downloaded for a payload (file list) of only 60 KB. Out of curiosity, I
>>> did the same experiment between two linux machines configured as NFS
>>> client+server. 
>>
>>   Perhaps more instructive would be to compare with typing "DIR Z:" 
>> in a DOS
>> prompt.  How much time does that take, and how much network traffic 
>> does it
>> generate, by comparison?
>
> If the OP is looking for truer comparisons with Linux, I would say that
> using SAMBA on Linux is a better test than NFS.  Of course, Cygwin is
> expected to be slower than Linux regardless.
>
> In terms of overall time/traffic with Cygwin, I'd recommend comparing the
> results of "DIR Z:" that Dave recommends above to "ls /cygdrive/z" (or
> "DIR /S Z:" to "ls -R /cygdrive/z").  If you need to use "-l" with "ls"
> and remote SAMBA shares, I'd recommend adding "smbntsec" to your "CYGWIN"
> environment variable.  This should limit file accesses that "-l" (and 
> other
> flags) can require.  See the link below for more info:
>
> <http://cygwin.com/cygwin-ug-net/using-cygwinenv.html>
>
> -- 
> Larry Hall                              http://www.rfk.com
> RFK Partners, Inc.                      (508) 893-9779 - RFK Office
> 216 Dalton Rd.                          (508) 893-9889 - FAX
> Holliston, MA 01746
>
> _____________________________________________________________________

"smbntsec" made a huge difference, a factor of 10x! "ls -lR /cygdrive/z" 
still transferred 10 MB, 50x more than "DIR /S Z:" but far better than 
400x it was doing with "nosmbntsec". It improves rsync too which does 
some thing similar to "ls -lR" to get file mtime and size etc to filter 
files. I think 50x factor sounds still too high. I thought the Cygwin 
overheads were of the order of 3x or so. Can we squeeze another order of 
magnitude?

Thanks Larry,
Vinod


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019