|
|
coherent
floppy disks Technical Information floppy disks
The COHERENT system lets you read or write to floppy disks, using
a variety of different formats. You can choose the format that
best suits the task at hand.
***** Disks Supported *****
COHERENT lets you use either 3.5-inch or 5.25-inch disks, in
either high or low density; what you use depends upon the type of
hardware that you have. The following table gives some commonly
used diskette device names and formats:
_D_e_v_i_c_e _n_a_m_e_S_e_c_t_o_r_s/_T_r_a_c_k _H_e_a_d_s _S_e_c_t_o_r_s _B_y_t_e_s_F_o_r_m_a_t
/dev/f9a0 9 2 720 360 KB5.25"
/dev/f9a1 9 2 720 360 KB5.25"
/dev/fqa0 9 2 1440 720 KB 3.5"
/dev/fqa1 9 2 1440 720 KB 3.5"
/dev/fha0 15 2 2400 1.2 MB5.25"
/dev/fha1 15 2 2400 1.2 MB5.25"
/dev/fva0 18 2 2880 1.44 MB3.5"
/dev/fva1 18 2 2880 1.44 MB3.5"
Device names ending in `0' indicate drive A:, names ending in `1'
indicate drive B:. For a fuller description of COHERENT's
floppy-disk devices, see the Lexicon entry for ffdd.
***** MS-DOS Format *****
COHERENT lets you read or write to floppy disks that contain MS-
DOS file systems. Both tasks use the command ddooss. This command
is discussed in full in its Lexicon entry.
To read files from a MS-DOS disk, use the ddooss command's -xx
option, with the appropriate device name for the floppy-disk
device that you will be using (as given in the above table). For
example, to read file ffrreedd.eexxee from a low-density, 5.25-inch MS-
DOS floppy disk in drive A, use the following command:
dos -x /dev/f9a0 fred.exe
The following command reads all files from a high-density, 5.25-
inch MS-DOS floppy disk in drive B:
dos -x /dev/fha1
To write a file to a preformatted MS-DOS floppy disk, use the -rr
option to the MS-DOS command. For example, to write file
ffrreedd.mmss, which contains text, to a low-density, 5.25-inch MS-DOS
floppy disk in drive A, use the following command:
COHERENT Lexicon Page 1
floppy disks Technical Information floppy disks
dos -ra /dev/f9a0 fred.ms
Note that the `a' flag in the command line tells COHERENT to
convert linefeeds to the linefeed/carriage return combination, as
used by MS-DOS. You will want to use this flag _o_n_l_y when
transferring text files to or from an MS-DOS floppy disk.
The following command copies all files in the current directory
to a high-density, 3.5-inch MS-DOS floppy disk in drive B:
dos -r /dev/fva1
Note that when you copy a file to an MS-DOS floppy disk, COHERENT
observes the MS-DOS file-name conventions: it permits only eight
characters to the left of the period, and only three characters
to the right of it.
(It should be noted in passing that you can use the ddooss command
to read files from or write files to an MS-DOS partition on your
hard disk. All that is necessary is to replace the name of
floppy-disk device with that of the hard-disk device for the
partition in question. See the Lexicon entry for aatt for a list
of hard-disk devices; see the entry for ffddiisskk for information on
how to read the layout of your hard disk; and see the entry for
ddooss for details of how to use the command.)
Finally, COHERENT lets you format a floppy disk and create an MS-
DOS file system on it. To do so, you must use the command
ffddffoorrmmaatt as well as ddooss. ffddffoorrmmaatt is described in detail in its
Lexicon article.
To format a high-density, 5.25-inch floppy disk in drive B and
write an MS-DOS file system onto it, use the following commands:
/etc/fdformat -av /dev/fha1
dos -F /dev/fha1
To write files to your newly created file system, use the -rr
option to the ddooss command, as described above.
***** COHERENT Format *****
If you wish, you can create a COHERENT file system on a floppy
disk, mount it, and manipulate the files on it with standard
COHERENT commands. This is a good illustration of the fact that
to COHERENT a file system is a file system, whether it resides on
a hard, a floppy disk, or any other mass-storage device. You can
use such mountable floppy disks as an easy method of backing up
COHERENT Lexicon Page 2
floppy disks Technical Information floppy disks
files, or as a flexible extension to any other file system that
you have currently mounted.
To create a COHERENT file system on a floppy disk, you must use
the commands ffddffoorrmmaatt, bbaaddssccaann, and mmkkffss. Each is described in
detail in its own Lexicon article. The following example creates
a COHERENT file system on a high-density, 3.5-inch floppy disk
placed in drive B:
/etc/fdformat -a /dev/fva1
/etc/badscan -v -o proto /dev/fva1 2880
/etc/mkfs /dev/fva1 proto
rm proto
In this example, command ffddffoorrmmaatt formatted the disk. bbaaddssccaann
then scanned the disk for any bad blocks, and wrote its results
into file pprroottoo. Finally, command mmkkffss reads pprroottoo and used its
contents to create a COHERENT file system on the disk.
Now that the file system is created on the disk, you must mount
it. While it is customary to mount file systems under directory
`/', you are not required to do it. For example, if your login
identifier is ffrreedd and your home directory is /uussrr/ffrreedd, you can
mount the floppy disk's file system onto a subdirectory of
/uussrr/ffrreedd and so make the floppy disk, in effect, an extension of
your home directory. The following command does this for the 3.-
5-inch disk we formatted in the above example:
/etc/mount /dev/fva1 /usr/fred/temp
Now, all files you copy into directory /uussrr/ffrreedd/tteemmpp using the
ccpp command will be written directly onto the floppy disk. Note
that you may need to log in as the superuser rroooott and use the
command cchhoowwnn to ensure that ffrreedd owns the file system on that
floppy disk. For details on cchhoowwnn, see its entry in the Lexicon.
One last point about mounting file systems: before you remove a
COHERENT-formatted floppy disk from its drive, you mmuusstt first use
the command /eettcc/uummoouunntt to unmount its file system. If you do
not, all data that COHERENT has stored in its buffers will not be
written to the disk, and may be lost. Worse, if you remove one
COHERENT disk and insert another without unmounting the old disk
and mounting the new one, COHERENT will write all data in its
buffers onto the new disk without regard for what that disk
contains; in all likelihood, this will trash the file system on
the new disk and render its data unreadable. So, the lesson is:
_a_l_w_a_y_s _u_n_m_o_u_n_t _a _f_l_o_p_p_y _d_i_s_k _b_e_f_o_r_e _y_o_u _r_e_m_o_v_e _i_t!. To unmount
the floppy disk we used in our previous example, use the command:
COHERENT Lexicon Page 3
floppy disks Technical Information floppy disks
/etc/umount /dev/fva1
By the way, that's not a misprint: the command is uummoouunntt, not
``unmount''.
***** Raw Format *****
Finally, COHERENT lets you use floppy disks in their raw form as
a backup medium, much as you would use magnetic tape on a larger
computer. You must first use the command ffddffoorrmmaatt with the -vv
option to format the floppy disks you will be using; it is also
wise to label and number the disks so you can keep them in some
reasonable order. Then you can use any of COHERENT's archiving
utilities, such as uussttaarr, ccppiioo, or dduummpp to archive directories or
entire file systems onto the disks. It is recommended that you
format a generous supply of floppy disks before you begin; if you
run short of disks while archiving your files, you will have to
abort, format more disks, and begin again. For details on how to
use the archiving programs, see their respective entries in the
Lexicon.
***** See Also *****
bbaaddssccaann, ccppiioo, ddooss, dduummpp, ffdd, ffddffoorrmmaatt, mmkkffss, mmoouunntt, tteecchhnniiccaall
iinnffoorrmmaattiioonn, uummoouunntt, uussttaarr
COHERENT Lexicon Page 4
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.