Figure 10-4.Disk pack access arm seeking cylinder 20.
Root Directory Formatting a disk creates the
root directory. This directory is limited in size
according to the type of disk you have and what
version of DOS you are using. With a DOS version of
3.x or greater, all floppy disks and 10M fixed disks
have 128 entries in the root directory. Fixed disks with
20M+ capacity have a root directory with space for 512
entries.
Subdirectories Subdirectories are directories
that are treated as data files. There is no limit on how
many entries they can have. To help you keep data
organized, you can also make subdirectories for
subdirectories.
Table 10-1 illustrates a typical directory tree for a
fixed disk.
In table 10-1, the directories \DOS, /DATABASE,
and \WORDPROC are subdirectories of the root
directory C:\. The directory WILES is a subdirectory
of \WORDPROC.
Table 10-1.A Typical Directory Tree
10-5
DOS stores files in these directories. When you
create a file, you must give the file a name to store it.
The name can be up to eight characters in length,
followed by a period and a three character extension.
The file extension is used to help identify the type of
file. Program file extensions are .EXE (execute) or
.COM (command). A .BAT extension designates a
batch file.
Looking at a directory entry, you will find that each
entry is 32 bytes long. Table 10-2 illustrates the
breakdown of a DOS directory entry.
File attributes designate whether the file has been
marked by the creator as a read-only file, a hidden file,
a system file, or a subdirectory, or if the file has been
archived.
Table 10-2.DOS Directory Entry