home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
World of A1200
/
World_Of_A1200.iso
/
programs
/
disk
/
misc
/
dfrags
/
dfrags.doc
< prev
next >
Wrap
Text File
|
1995-02-27
|
16KB
|
379 lines
Disk Fragmentation Report Version 3.12
©1990-92 Custom Services
General:
This utility will read all the disk devices on your system and analyze the
BitMap for each partition. If the options are selected
It will also analyze the file system on each partition. The result for
the analysis will be the number of fragments on the disk(BitMap), and
file system(if selected). Several options exist to control how much is
reported. This is a CLI and Workbench utility.
This utility is released as shareware. If you
find it useful, please send the basic registration fee to Custom Services.
The Options for registration are:
Amount | Fee | Service
-------+----------+-------------------------------------------------------
$5 | Basic | Basic Registration fee, everyone must send this!
-------+----------+------------------------------------------------------
$7 | Updates | Update fee for future version if I supply disk
-------+----------+------------------------------------------------------
$5 | Updates | Update fee for future version if you send a disk
-------+----------+------------------------------------------------------
Send $5 for the basic registration plus $7 for updates will get you a
copy of the next version of this program. I will supply the disk. Sending
$10 will get you notification of updates. I include all my shareware
utilities on the disk.
Please send all registration and update fees of your choice to:
Custom Services
P. O. Box 254
Moorestown, NJ 08057
Compatibility:
This program is compatible with 1.3 and 2.xx versions of the operating
system. It has been tested with both operating systems. It should work
with any disk drive(either hard drive or floppy).
This program will not work on a CD-ROM drive, it is not compatible with
the CD-ROM filesystem or the disk format. It may someday become CD-ROM
smart, but for now it hangs.
Command from cli:
DFRAGS
From Workbench, just click on the icon.
Validation:
DFRAGS will validate ever part of the file system. It checks any and
all values. Error messages are issued for any problems found. Some errors
are considered severe enough that processing stops when they occur. Others
are considered errors, but not bad enough to stop the processing.
Disk Integrety:
o Blocks are only used once(linkage errors).
o Block zero must be either FFS or SFS.
o read errors.
o illegal block numbers(know as Key Invalid).
Root Directory Checks:
o Spare words must be zero
o OwnKey must be zero
o Sequence number must be zero
o Hash table size must be 72
o BitMap Valid flag must be valid, a -1.
o All words of the sector must add up to zero(zero sum checksum)
o read errors
Directory checks:
o Spare words must be zero
o OwnKey must be equal to block number
o Parent block number must be Parent's block number
o Hask index of this directory must be same as hashed name
o All words of the sector must add up to zero(zero sum checksum)
o read errors
File Header checks :
o Hask index of this directory must be same as hashed name
o Parent block number must be Parent's block number
o Spare words must be zero
o OwnKey must be equal to block number
o All words of the sector must add up to zero(zero sum checksum)
o read errors
Link Checks:
o Linked files and directories are checked the same as regular
files and directories except that no data is read for files and
directories are not traversed. All other checks occurs as
above.
Bitmap Checks:
o All words of the sector must add up to zero(zero sum checksum)
o read errors
o The BitMap is rebuilt whenever you use the File fragmentation
options. This will cause sectors to be checked to ensure that
no sector is incorrectly used more than once.
Options:
By default all the options are off. You select an option by clicking on
the gadget for it. There are the following command options:
Verbose option. Each file accessed will have one or more lines of
output. This will occur even if the file does not
have fragments.
File option Check file fragmentation and structure. This option
will cause the file system to be traversed. Each file
is checked for contiguous disk blocks and file system
errors. I suggest this option always be used.
1.3 optiom Assume the 1.3 file system. There is a difference in
the way that 1.3 and earlier file systems allocate files
versus the 2.xx file system.
The 1.3 file system will allocate the first block of a
file in one area and the rest in another. This option
will remove one fragment from the file total. Under 2.xx
the file system is a bit better, attempting to allocate
a file in one contiguous area.
Pause option If you leave the program running and unattended, you may
lose information as it scrolls off the screen. This option
will cause the program to pause at the end of a page of data
until you hit a key on the keyboard.
Debug option If you have a problem, you can use this option to see the
actual file system structures. Each non-data block is
identified and printed in a formatted manner.
I recommend the command options for full file checking. This will completely
validate the bitmap and check the file system structure.
Error Messages:
No Memory available for disk buffers
A memory allocation failed while trying to get buffers for the
disk. You will have to shutdown some of you other tasks and try
again.
Unable to get a Port from CreatePort
Unable to get pointer from CreateExtIO
Unable to Open device
These are messages that indicate that you have a very messed up
system! Your device tables may be corrupt. A re-boot is
in order!
Error Reading Block Zero, error = nnn
A read was done on the BootBlock of the current device. It failed
with the indicated error code. This could indicate a bad spot on the
device or even a possible viral infection in your system.
Boot Block for device/partition is invalid or non-dos
The data in the first four bytes of the Boot Block was not an
indicator for either type of file system(DOS^@(SFS) or DOS^A(FFS)).
This disk is either corrupt, damaged, contains a special boot
block, or it is a viral infection.
disk read error on Root block
The Root block was either not found or generated a disk error when
read from the disk.
Problem: Key value too large limit 0 to nnnnn, got mmmm for file/dir
This is a common corruption problem. A key(relative block number)
is out of range for a file or directory. You cannot delete the file
or directory in some cases because the block number is in a critical
location. This error will also generate a "false" disk read error
since the read could not occur. You may have lost linkages to data
of files with this error.
Root Block may be corrupt.... skipping
The Root Block failed several sanity checks. It may work ok, but is
corrupt. A backup, format and restore are probably indicated for this
partition or floppy.
Bit Map shows as invalid(nnn)
The Root Block indicator says that the current bit map may be in the
process of being updated. nnn is the current value which should be
either 0(if invalid), or -1(if valid). If other values show up, your
root block is corrupt.
CheckSum Error in Root Block, may be corrupt... skipping
The checksum for the Root block of the current device is non-zero.
This indicates a corrupt Root directory.
I/O error reading BitMap block:nnnn
An I/O error occurred during the bit map processing. The error will
prevent an accurate count of the fragmentation.
BitMap Checksum error: Block nnn may be invalid or corrupt
The checksum of a BitMap block is invalid, the BitMap may be corrupt.
Disk(u/f) vs files(u/f) Bitmap do not match for block nnn
After all the files were processed, a check is made against the
actual computed bitmap created from the files and the disk bitmap.
u/f is either "free" or "used" to indicate which thought the sector
was free.
Disk(Used) vs files(Free) Bitmap do not match for block nnn
This error indicates that the files did not use a sector that the
bitmap indicated was in use. This may be ok if you have used a tool
to mark sectors as bad by flagging the sectors as used.
Disk(Free) vs files(Used) Bitmap do not match for block nnn
This error indicates that the Bitmap does not have a sector marked
as used when one of your files thinks it is used. This is a bad
situations in that later you may try to use the sector again for
a new file. A backup/format/restore may be indicated here.
Used_Map system error: nnn mmm
Get_Map system error:nnn mmm
This usually means an illegal key value. One of your files has a
key value outside of the partition. This is probably an indicator
of a corrupted disk. It would be a good idea to use the -N option
to list the file/directory names while running to see what file or
directory has the problem.
Key already set: nnnn for file/dir
This is an indicator that you have some kind of linkage problem.
Two files or directories have the same sector in use. One of the
files is wrong, not nessecarily the one printed! The name displayed
is the the second file found using the sector indicated.
No Memory available for file/dir buffers at <name>
An Allocation of memory failed due to not enough memory. Shutting down
some other tasks will increase the memory available.
I/O error reading Dir/File block: nnnnn from <name>
A read error occurred while reading directory or file header
information.
Dir: <name> parent hash index (nn) not same as file hash index(nn)
File:<name> parent hash index (nn) not same as file hash index(nn)
The directory or file name hashes to a value that does not match the
location in the parent hash table. This probably indicates a corrupt
parent directory or the directory/file name is corrupted.
Dir: <name> parent (nnnn) not parent(mmmm) block
File:<name> parent (nnnn) not parent(mmmm) block
The block number of the parent directory(mmmm) does not match the
parent field in the directory or file header data. This indicates a
possible linkage problem or a corrupt disk.
Dir: <name> OwnKey (nnnn) not block number(mmmm)
File:<name> OwnKey (nnnn) not block number(mmmm)
The block number of the current file or directory does not match the
block number in the header data. This indicates a possible linkage
problem or corrupt disk.
Dir: <name> may be corrupt(spare words not zero)
Dir: <name> may be corrupt(checksum not zero)
File:<name> may be corrupt(spare words not zero)
File:<name> may be corrupt(checksum not zero)
The file header or directory block has failed one of the sanity checks
or the checksum is non-zero. This could indicate a corrupt disk.
File:<name> Extension(nnnn) not secondary Hdr
The current file is large enough to need a secondary header. The
sector pointed to in the file header is not a secondary header. The
file is corrupted.
Invalid block type in key nnnn for directory <name>
The directory has an entry for a sub-directory or file that is not
either. This is an indication of a corrupt disk.
I/O error reading File data in: <name> block:nnnn
While verifing the file data blocks an I/O error occured. The
file is damaged and cannot be read.
ShareWare:
This program, the documentation and all files in the archive are
copyrighted by Custom Services ©1990-94. All rights are reserved. No
commercial use or financial gain may be made using this product without
the consent of Custom Services. This archive may be redistributed in
any public domain collection or on any BBS provided all files are left
intact. Support Shareware. Amazing Computing has permission to distribute
this archive.
Future:
There are no additional checks that can be made. This program already
validates the file system to the fullest extent possible. Some additions
that can be made are:
-- Possible code optimizations,
-- Bug fixes if anyone reports any.
-- Support for the Intl file system .
-- Support for the disk caching file system.
Only a few people have registered this program even though on BIX over
500 people had downloaded it! I am not in this for the money, and would
like to see just a note indicating what you think of this.
History:
1.00 -- initial version.
1.01 -- fixed several small bugs
1.06 -- re-created all the 1.01 bug fixes to a pre 1.00 version due to
HD crash/source loss. Added several new features.
fixed a divide by zero error if no fragments on a device!
1.07 -- fixed a bug in the BitMap analysis. Fixed a debug output that
was not printing the whole bitmap(last word missing).
2.00 -- Added many sanity checks. Improved the BitMap fragmentation
removing several minor bugs. Fixed a bug that prevented the
processing of larger disk devices/partitions(53 meg limit).
Added error documentation. Added file data validation option.
Documentation updated, error information and new options added.
2.02 -- Corrected a couple of debug printouts to show the correct
information and updated the documentation.
2.06 -- Added additional validation checks and fixed a file bug where
a hash conflict caused a file chain to not be looked at. Added
support for 2.xx file and directory links. Added a formatted
output of root, file, and directory structures under debug or
if an error is found.
2.07 -- Minor bug fixes and clean up of debug code.
2.08 -- fixed resource allocation/return on ^C exit. The floppy drive
motor is shut off if you quit. Previous versions did not return
the buffers to the free memory pool.
2.10 -- Added full BitMap checking. Corrected the resource allocation
code where it lost memory for buffers currently in use.
Updated the docs with the new error messages. Added the problem
solving option "-N" to display the names of files as they are
processed(similar to "-I" except prints even if the fragments is
zero). Combined the regular file and link file processing.
2.12 -- Added checks for block numbers out of range. Fixed a minor bug
in the BitMap checking where a false error was generated. Added
a change in the size calculation to generate total blocks, not
to have K or M displayed.
2.13 - 3.03 Internal debug versions only released to testers.
3.04 -- Released version that works from the Workbench or CLI in the same
manner. Re-adjusted much of the output. Removed alot of the
unformatted output from the debug option. Removed the old cli
interface and replaced the options with gadgets.
3.05 -- changed to register parameters for a smaller, faster executable.
added an icon for use with the workbench(forgot it in 3.04).
3.12 -- minor bug fixes, adjustments for the interface.