This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cygwin 1.7.6: find skipping over some directories on NTFS mount points


On 2010-08-19 04:31, Corinna Vinschen wrote:
On Aug 18 18:50, Rolf Campbell wrote:
I have an 2nd NTFS disk mounted in a directory in my primary NTFS
disk.  When I use 'find' (with no arguments), it only displays a
small fraction of the files in the current directory.

Using cygwin 1.7.5, it displayed about 100,000 files.
Using cygwin 1.7.6, it only displays the content of the first
top-level directory and then just stops.

I tried out all the snapshots and narrowed it down to "20100618".
It worked correctly in "20100614" and does not work correctly in
"20100618".

If I mount the disk as a normal drive and access it using
"/cygdrive", it displays all 100,0000 files with both 1.7.5 and
1.7.6.

That narrows down the problem to a specific change, but unfortunately I can not reproduce the problem.

I assume, when you say you "mounted" the 2nd drive, you didn't mean a
Cygwin mount but rather a Windows junction point, so your drive doesn't
show up as D:, but as C:\DriveD in Windows, correct?

At least, that's what I tested.  The drive has 1577 files and
directories in multiple levels, and `find' always prints all of them,
regardless whether the drive is mounted as drive or as juntion point.
I also tried a Cygwin mount additionally, with the same result.

Here are a couple of questions.  They are all related to the mount
using a junction point.

- When you call `ls -l' in the top-level dir of the junction point,
   are directories recognized as directories?
   How many links do the directories supposedly have (should be 1)?

- Is it possible that this has something to do with permissions?
   "acl" vs. "noacl".  Your cygcheck output doesn't point that out,
   but who knows.

- Eventually, under Cygwin 1.7.6, can you please send us the output of
   `ls -l' of the top-level dir, and call `strace -o find.trace find' in
   the top-level dir and send the strace output?  Please don't try this
   with the *working* scenario, the strace of a find finding 100000 files
   would be a bit... swollen.


Corinna



NTFS Junction point: yes. I used the builtin windowns tool "mountvol" to mount the disk in an empty directory. It's technically mounted as "C:\.timemachine\3".


Output from "ls -l"
$ /bin/ls -l
total 6680
drwx------+ 1 Rolf None 0 2010-04-17 16:06 ATI
drwx------+ 1 Rolf None 0 2010-07-25 22:31 Books
drwx------+ 1 Rolf None 0 2010-08-12 22:41 Config.Msi
drwx------+ 1 Rolf None 0 2010-05-30 22:31 Documents and Settings
drwx------+ 1 Rolf None 0 2010-08-08 16:40 Lisa
drwx------+ 1 Rolf None 0 2010-07-28 09:18 Mail
drwx------+ 1 Rolf None 0 2010-05-24 23:18 Old
drwx------+ 1 Rolf None 0 2010-06-01 22:53 Pictures
drwx------+ 1 Rolf None 0 2010-08-11 21:46 Programs
drwx------+ 1 Rolf None 0 2010-08-18 22:11 RECYCLER
drwx------+ 1 Rolf None 0 2010-08-11 20:59 Saves
d---rwx---+ 1 Administrators SYSTEM 0 2010-06-19 19:09 System Volume Information
drwx------+ 1 Rolf None 0 2010-08-10 08:34 Torrent
drwx------+ 1 Rolf None 0 2010-06-08 21:49 cygwin
-rwx------+ 2 Rolf None 6839239 2010-08-19 08:43 list.txt
drwx------+ 1 Rolf None 0 2010-08-10 08:34 mp3
drwxr-xr-x+ 1 Rolf None 0 2010-05-22 14:52 shaRepot



I do not set the CYGWIN environmental variable when running find.


I noticed something of interest, if I run "find", then it only descends into the "ATI" directory. After exhausting every file/dir under ATI, it terminates. But, if I run "find -maxdepth 2", it shows all correct output (it correctly enters all top-level and 2nd level directories -- it does NOT stop after leaving ATI).

Also, ls -R works just fine (showing all 100,000 files).

I've attached the strace output from find (compressed because it was > 1Meg).

I tried different maxdepth settings, they all worked up until 6, then they fail as find exits the ATI directory.

Attachment: find.strace.bz2
Description: Binary data

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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]