Path: utzoo!attcan!uunet!husc6!ukma!rutgers!mcdchg!chinet!ward From: ward@chinet.chi.il.us (Ward Christensen) Newsgroups: comp.sys.ibm.pc Subject: Re: Large number of files slows machine. Message-ID: <7255@chinet.chi.il.us> Date: 23 Dec 88 05:06:48 GMT References: <8545@j.cc.purdue.edu> <7192@chinet.chi.il.us> <1078@pilchuck.Data-IO.COM> Reply-To: ward@chinet.chi.il.us (Ward Christensen) Organization: Chinet - Public Access Unix Lines: 28 In article <1078@pilchuck.Data-IO.COM> del@pilchuck.Data-IO.COM (Erik Lindberg) writes about... (attributions getting too lengthy, Pruned) The original article wondered why a disk with >650 files/subdir was slow doing DIR and other things. I stated: >> What is happening is the fragmentation of your directory resulting in >>many seeks while processing the directory. while Erik stated "This might SEEM to be what is happening on your system, but it isn't right", and said that in a case where his directories completely fit in cache (eliminating seek time), he found "a massive increase in file access time when the number of files in a subdirectory exceeds 512." To defend my initial comment (but not say Erik is wrong the way he said I was): my Compuserve capture directory slowed WAY down at one time, and I finally traced it. Deleting files from the directory didn't help, so I looked - and found my directory in 3 extents "all across the disk" (say, at 1/4, 1/2, and 3/4 the way across). By copying the files in the 3rd extent to a temp directory, then manually patching the FAT to not point to the 3rd extent, then copying the file back - so I had the SAME NUMBER of files but in 2 extents instead of 3, the speed improvement was very significant. So, Erik in MY case, the NUMBER OF DIRECTORY EXTENTS was VERY significant - probably due to the slow seek time. In YOUR case it was the sheer number of files. We're both right - like a car that can mis-fire from either fuel or electrical problems, a hard disk can slow down from either too many files or too many directory extents (and probably more things). Happy Holly-Daze to you all.