From: jqb AT netcom DOT com (Jim Balter) Subject: Re: du does not find all directories 8 Feb 1997 08:20:22 -0800 Approved: cygnus DOT gnu-win32 AT cygnus DOT com Distribution: cygnus Message-ID: <32FC4776.7BC7.cygnus.gnu-win32@netcom.com> References: <0000C37D DOT 1408 AT softart DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 3.01Gold (WinNT; I) Original-To: MLDickey AT softart DOT com Original-CC: "'Ken Evans'" , Sergey Okhapkin , "'gnu-win32 AT cygnus DOT com'" Original-Sender: owner-gnu-win32 AT cygnus DOT com MLDickey AT softart DOT com wrote: > > The cluster size under Win95 is dependent on the size of the partition in > question. I think I have some rough numbers ... nope can't find them. > > I don't remember where I've seen them, but it's true. The larger the > partition size, the larger the cluster size. The table is ROUGHLY like > this: > > 0-200M 4k > 201-500M 8k > 500-1000M 16k > 1000-2000M 32k > > Again, these are rough -- from memory not from valid source. It's more useful to understand how things work than to memorize tables. A FAT16 filesystem stores cluster numbers in 16 (funny thing) bits, so a cluster can be at most /2^16 bytes. If you want to turn that into a table, you get: cluster size partition size 512 0-32M(-1) 1K 32M-64M(-1) 2K 64M-128M(-1) 4K 128M-256M(-1) 8K 256M-512M(-1) 16K 512M-1G(-1) etc. (note that DOS can't handle partitions >= 1G) Note, though, that the cluster size has NOTHING WHATSOEVER to do with the numbers reported by ls and du; under cygwin, they report strictly based upon the file size, but they report half as many blocks as they should. The fact that they don't know about clusters makes them not very useful, even if they did report the right numbers; if you have 1000 100 byte files on a 512M partition, you are actually using 15.6M, but a "working" du would think you are only using 500K. Now you know where your disk space is going! If a 32:1 disk space usage for small files isn't what you had in mind, consider switching to NTFS (or FAT32 if you have it). There's even a freeware NTFS redirector that you can run under Windows 95, though I haven't tried it and don't know how reliable it is (it was created by reverse engineering NTFS, the precise details of which seems to be on of those MS "secrets", though there is a pointer to the redirector on one of MS' own pages). -- - For help on using this list, send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".