X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:to:subject:message-id:reply-to
	:references:mime-version:content-type:in-reply-to; q=dns; s=
	default; b=Si+CUuBXV6gDCJJAo7iYbHE8NF7cZeWvRwFdFjg1nqYRhGsBmimp7
	IJjMQm79I2Dv2OyDsZoZtX0XB5nXa8BzAtJ8Wy8PKBaZCnJPAISb2odGSnkiAHKR
	loXacjF/KD6z2ylRkYF3gDeELEMdgLOIe2omn470d3JJIi4b+NzoFM=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:date:from:to:subject:message-id:reply-to
	:references:mime-version:content-type:in-reply-to; s=default;
	 bh=OANJiwVUStHJwHBOTamw02jM7ZQ=; b=IY9/bC87b2d7ni/5ZdTQ38e2qrnB
	aeAqCF9Bmv24B9L1BOhzwuxjqYraMyEjI3dWjf2+zsFInO12U4Z21cG72Vo5FQ7B
	MmmaveJr12PcAAtSJcd8V8wsQwkX1MLDRts2/YwMUwLl9fqc0azfQoDxCoQlYVC6
	E8+kdTYIQDc0NnY=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-92.8 required=5.0 tests=AWL,BAYES_50,KAM_LAZY_DOMAIN_SECURITY,KHOP_DYNAMIC,RCVD_IN_BRBL_LASTEXT,RCVD_IN_PBL,RDNS_DYNAMIC,USER_IN_WHITELIST autolearn=no version=3.3.2 spammy=prudent, Maintainer, opens, H*f:sk:8737tpq
X-HELO: calimero.vinschen.de
Date: Sat, 23 Jan 2016 18:35:52 +0100
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: Performance of "ls -F"
Message-ID: <20160123173552.GE3268@calimero.vinschen.de>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <loom.20160121T163405-489@post.gmane.org> <CAH5rLZVWiGz2n-3Ru-C0_5KU-Cc4NipJPn1NQVphN2UetUK4iA@mail.gmail.com> <3a9ff6ec2d5e4e64a96a8f8e31d12f22@ntmaexbe04.bedford.progress.com> <loom.20160122T082744-501@post.gmane.org> <20160122201418.GC3268@calimero.vinschen.de> <8737tpqqb6.fsf@Rainer.invalid>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha256;	protocol="application/pgp-signature"; boundary="5oH/S/bF6lOfqCQb"
Content-Disposition: inline
In-Reply-To: <8737tpqqb6.fsf@Rainer.invalid>
User-Agent: Mutt/1.5.24 (2015-08-30)

--5oH/S/bF6lOfqCQb
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Jan 22 22:04, Achim Gratz wrote:
> Corinna Vinschen writes:
> > Just a hint:  ls -F requires to stat every single file.  stat in turn
> > requires to load not only the usual metadata but also to fetch the ACL
> > and convert it to POSIX permissions.
>=20
> The timings are from shares mounted with the noacl option, so that bit
> of code shouldn't be involved.  I will try the same operations on an ACL
> enabled mount of the same share later and I also need to find a share
> that is exported from a true NTFS server for comparison.
>=20
> > Assuming this slow access only occurs under 2.4.0,
>=20
> No, the behaviour is quite a bit older, although I didn't time it since
> I didn't recognize the connection to the aliased ls.  In any case, it
> really is just the determination of whether or not the file is
> executable that takes up all that time.

In the noacl case, Cygwin tries to find out if files are scripts.  It
opens the file and checks the first two bytes in the file for a shebang
(and other stuff).  This may take a lot of time, more so on network
drives.  Can you try adding the "notexec" mount option to the "noacl"
share and see if that helps?

This test is done for a looong time to accommodate FAT filesystems in
the first place.  It might be prudent to disable it by default these
days...


Corinna

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--5oH/S/bF6lOfqCQb
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWo7n4AAoJEPU2Bp2uRE+g3CgP/jY/5z7pSXLVokYxhfTO1ZIO
SjZcs895qgT67dMa1o/IOmwnrXtmliIYNbwRh6NqbTYuyfI8oeY38SuRx2csOnGB
U73q5wNsBsnVg4w34/egxrgv6Q8ib0aMtxVSDT99+0SMenZyFtHVkOFF5Qt82N8A
GKfkZaYRo0+bGG4tRdQXGi/gFbizx/CfceEk7mQQwsoCZYZqfFFzmLsqOxW/FDjr
/5UgN6Ga7izL526Fc6Ug/kFl7NtF6O+5Oc4lgIxhnpGhzpa1nBsbGHzgdRoOMxYP
Ao2jHpdueYuTT64JRXtsAsaIZXY9whl1KsLhB6rQLpaK2RPGg0WJ73Hl40x0N9Qu
4AFhwSBOaLs3oIBnsIw6J5RJTvmPJ1poof32Zy+girWjmCcFhaw9r15MpUM7VE4h
0V1OVKFYBqbmxeUt8MGUy+IbDDdr2ksgAt59iMTRQArNVgtfqST2ib2ys3ecwx5V
o+2+XTmzZKPIwVJJwlrp5raZpTamtbM2ryRoC+xP9RnsLVSZWFvMXHPLEEiMass9
WGMAuZpa2eYXW9v4AivXYyypi17HE4XTzAf8qhRjYQMFQcL5VtjMkWcJRJzb0Ce/
LY6sZwBWiwZdvu4rtsDH+eNnfAqE+d0xO4gQFY7VEzv2yq4UwKiClW1WcwdfwqZZ
9PMgrLgnQ0i04+q1oMtU
=m/jv
-----END PGP SIGNATURE-----

--5oH/S/bF6lOfqCQb--
