Windows NT 4.0 source code leak
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

112 lines
5.3 KiB

This note describes the functionality of format and chkdsk in the
Disk Administrator.
=================================================================
Format
------
Select a volume and choose "Change Format" from the context menu. You
can specify the new format as any of FAT, HPFS, NTFS, or OFS, and choose
a label. You can specify whether or not to "quick format" the volume.
If you've selected a fault-tolerant volume (stripe with parity or
mirror), then "quick format" is disabled.
When formatting, a "thermometer" displays the percentage of formatting
completed. A "Stop" button allows you to cancel the formatting.
If "Stop" is chosen, a confirmation dialog appears. A message informs
the user that stopping formatting early is inadvisable. The user can
choose "Stop" to confirm the original "stop" desire, "continue"
(the default) to continue formatting where formatting left off, or
help.
Cancelling format is disabled when quick formatting.
After formatting completes, a summary is printed detailing the amount of
disk space is on the volume, and the available disk space (with
thousands separators!).
Chkdsk
------
Select a volume and choose "Check for Errors..." from the context menu. You
can choose one of three levels of operation: (1) read-only, or don't
fix; (2) fix (i.e., chkdsk /F); or (3) scan for bad sectors (i.e.,
chkdsk /R).
If the user hits "OK" and the current level of operation choice is
"don't fix", then a confirmation dialog is displayed, warning the user
that no error repair actions will be taken, and the reported actions describe
what would be done in a "fix" case.
When checking a volume, a "thermometer" displays the percentage of checking
that has been completed in a particular phase. Note that this percentage
is not the percentage of all checking completed, which is usually
difficult or impossible information to determine before checking
begins. Above the thermometer appears a title stating what is currently
being checked. The thermometer is implemented to not update more than
10 times a second (unless the value is 0% or 100%). This is done to avoid
having the UI thread fall very far behind the worker thread which may
generate many more messages than that.
Note that % done information is currently only implemented for NTFS and
FAT, not for OFS. (Implementation note: Bob Duke, who originally wrote
chkdsk for OFS, strongly resisted adding % done information due to the
incredible complexity of OFS and the lack of an easy means to predetermine
the total amount of work.)
For the "Do not fix errors" case, a "Stop" button allows you to cancel
the formatting. If "Stop" is chosen, a confirmation dialog appears. A
message informs the user that stopping checking early is inadvisable. The
user can choose "Stop" to confirm the original "stop" desire, "continue"
(the default) to continue checking where checking left off, or help.
For the other cases, there is no "stop" button; the volume check engines
don't support stopping in the "fix" cases. (Note that for chkdsk.exe,
Ctrl-C --- the "stop" mechanism for the command line --- is disabled in
the fix cases.)
After a successful, complete volume check, a "results" dialog appears.
Within this dialog is an edit control with any interesting information
generated by the volume check. For successful checks, this is simply a
summary of total disk space, the space in user files, the space used by
the system, etc. Buttons exist to allow this information to be printed
or logged to a file. The title to this dialog is different in the "don't
fix" and "fix" cases. In particular, in the "don't fix" case the message
makes clear that any error repair actions only describe what *would be*
done, not what *was* done.
This dialog is resizable, to allow the user to easily use more screen
space where necessary to view the results data, instead of forcing the
user to use scrollbars (which also are available).
Any number of copies---collated or not---can be printed to the default
printer. The common Print dialog is used, so the printer can be set up
before printing, if necessary. Printing can be cancelled, as well.
The results of the check can also be saved to a file by choosing the
"Log..." button. The common "Save As" dialog is used. The suggested file
name is "check-X.log" where "X:" is the volume that was checked, and the
directory that is suggested is the system directory, e.g. "c:\winnt". As
this is a common dialog, the user can choose a network drive (and even
connect to one).
Since a standard edit control is used to display the results information,
the user can select text there via either the keyboard or a mouse, and
copy it to the clipboard. It can then be pasted in an application like
notepad when writing a report, for example.
If a volume is to be checked in a "fix" mode, then the volume must be
opened for exclusive access. If this cannot occur due to the volume
being in use, then a message appears asking whether the user would like
to schedule the check for the next system reboot. (For instance, a
volume can be locked by simply opening a command window and setting the
current drive to it). The user can choose either yes or no. If the user
chooses "no", then the check simply ends without performing any work. If
the user chooses "yes", then a confirmation message box appears stating
that the check has been scheduled (or could not be scheduled).