home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.msdos.misc
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!att!cbfsb!cbnewsg.cb.att.com!rnichols
- From: rnichols@cbnewsg.cb.att.com (robert.k.nichols)
- Subject: Re: Hard drive utility (re-post with corrections)
- Message-ID: <1992Aug23.192452.21739@cbfsb.cb.att.com>
- Summary: Large clusters unavoidable in large partitions
- Keywords: cluster partition
- Sender: news@cbfsb.cb.att.com
- Organization: AT&T
- References: <1992Aug23.102643.28898@usenet.ins.cwru.edu>
- Distribution: na
- Date: Sun, 23 Aug 1992 19:24:52 GMT
- Lines: 51
-
- In article <1992Aug23.102643.28898@usenet.ins.cwru.edu> as789@cleveland.Freenet.Edu (Francisco J. Diaz) writes:
- >
- >Hi All! I'm looking for a utility that can change my sector size
- >in my 150 Megs ESDI HD. It is 4k each sector and recently I have
- >found that such a size represents a lot of wasted space due to
- >all the slack that is left over in tiny. As I understand, even if
- >the file is just a few bytes long it will occupy the whole 4k
- >sector thereby wasting space. I have been told that I can make
- >different partitions to reduce the sector size but I'd rather
- >leave it as it is (1 partition) ...
-
- I believe you are referring to CLUSTER size, not SECTOR size. Last I knew,
- BIOS and DOS were pretty well hard-wired to a 512-byte sector size. Since
- a cluster is the minimum allocation unit, though, everything you said is,
- in effect, true.
-
- Now for the bad news. Linking information for the chain of clusters that
- contain a file is kept on disk in the File Allocation Table (FAT), which,
- on a large hard drive, has a 16-bit entry for each cluster to indicate
- the next cluster in the chain. This means that there can be at most
- 65518 clusters (64K less a few values which have special meaning). So,
- for a given cluster size, there is a maximum partition size. DOS requires
- that the number of sectors per cluster be a power of 2 (I just verified
- that by playing with the boot record on a floppy), so the max partition
- sizes for each permissible cluster size are as shown below (in round
- numbers):
-
- Sectors/Cluster Bytes/Cluster Max. Partition
- 1 512 32MB
- 2 1024 64MB
- 4 2048 128MB
- 8 4096 256MB
-
- Thus, the minimum cluster size for a 150MB drive is 4906 bytes -- just what
- you have now.
-
- Splitting the disk into two equal partitions would allow 2048-byte clusters,
- which is about as low as you would want to go. Smaller clusters means
- more overhead accessing large files as well as more opportunity for
- fragmentation. In addition, this eats up memory since, while a disk is in
- use, DOS keeps the entire FAT in memory.
-
- Perhaps the simplest way to go would be to split the drive into 2
- partitions (BACK IT UP FIRST -- a high-level reformat will be required
- on each partition). You can then use the JOIN command to make the
- second partition appear as a subdirectory on the first.
-
- Clear as mud, right?
-
- Bob Nichols
- rnichols@ihlpm.ih.att.com
-