Obscure DOS question

Eric Smith eric at brouhaha.com
Mon Mar 28 18:06:46 CST 2005


Sellam wrote:
> MS-DOS 3.3 has a limit of 512 entries in the root directory.  I have a
> need to put more than this.

Hey!  Weren't you one of the people complaining that cctalk isn't
a PC support forum?

Anyhow, I think you can do it if you use something other than the DOS
format command to create the filesystem.  For instance, with the Linux
utility "mkdosfs", you can specify "-r root-dir-entries".  The man page
says that the default is 112 or 224 for floppies, and 512 for hard disks.
It doesn't say anything about what the upper limit might be.

I just tried it using a floppy image file rather than a real floppy
disk.  I created the image file like this:

$ dd if=/dev/zero of=floppy.img bs=1024 count=1440
1440+0 records in
1440+0 records out

First I tried the default format:

$ /sbin/mkdosfs -v floppy.img
mkdosfs 2.8 (28 Feb 2001)
floppy.img has 2 heads and 18 sectors per track,
logical sector size is 512,
using 0xf0 media descriptor, with 2880 sectors;
file system has 2 12-bit FATs and 1 sector per cluster.
FAT size is 9 sectors, and provides 2847 clusters.
Root directory contains 224 slots.
Volume ID is 42489a44, no volume label.

The I tried using the "-r" option to specify more root directory
entries:

$ /sbin/mkdosfs -v -r 1024 floppy.img
mkdosfs 2.8 (28 Feb 2001)
floppy.img has 2 heads and 18 sectors per track,
logical sector size is 512,
using 0xf0 media descriptor, with 2880 sectors;
file system has 2 12-bit FATs and 1 sector per cluster.
FAT size is 9 sectors, and provides 2797 clusters.
Root directory contains 1024 slots.
Volume ID is 42489a4e, no volume label.

I don't have a real blank floppy disk handy to test, so I did the
next best thing.  I mounted the image as a virtual drive A with
VMware.  Windows XP sees it as a floppy just fine.

In a Linux directory that is exported as a Samba share, I created
676 files that each contain one byte:

$ dd if=/dev/zero bs=1 count=676 | split -b 1
676+0 records in
676+0 records out

In Windows, I copied the 676 files to the A drive.  It worked fine.
So Windows XP apparently can deal with a floppy with a root
directory larger than 512 entries, if you can create one somehow.

If you aren't able to run the Linux mkdosfs command yourself, I can
send you a ZIP file containing an otherwise empty floppy image
created as described above, and you can use rawrite.exe or equivalent
to write it onto a real floppy disk.

Eric



More information about the cctalk mailing list