filesystem consistency check and interactive repair
fsck [-F ufs]
[generic_options] [special ...]
fsck [-F ufs]
[-o p,b=blkno] [-w]
[special . . .]
are options supported by the generic fsck command.
audits and interactively repairs inconsistent conditions on
In this case, it asks for confirmation before attempting
Inconsistencies other than those mentioned above
can often result in some loss of data.
The amount and severity of data
lost can be determined from the diagnostic output.
corrects innocuous inconsistencies such as: unreferenced inodes,
incorrect link count of inodes, missing blocks in the
free list, blocks appearing in the free list and also
in files, or incorrect counts in the super block, automatically.
It displays a message for each inconsistency corrected that
identifies the nature of, and file system on which, the correction
is to take place.
After successfully correcting a filesystem,
prints the number of files on that filesystem,
the number of used and free blocks,
and the percentage of fragmentation.
The default action for each correction is to wait for the operator to
If the operator does not have write permission on the filesystem,
will default to a
(no corrections) action.
Inconsistencies checked are as follows:
Orphaned files and directories (allocated but unreferenced) are,
with the operator's concurrence, reconnected by
placing them in the lost+found directory.
The name assigned is the inode number.
If the lost+found
directory does not exist, it is created.
If there is insufficient space its size is increased.
Blocks claimed by more than one inode or the free list.
Blocks claimed by an inode or the free list outside
the range of the file system.
Incorrect link counts.
Incorrect directory sizes.
Bad inode format.
Blocks not accounted for anywhere.
Directory checks, file pointing to unallocated inode,
inode number out of range, absence of ``.'' and ``..''
as the first two entries in each directory.
Super Block checks:
more blocks for inodes than there are in the filesystem.
Bad free block list format.
Total free block and/or free inode count incorrect.
A filesystem may be specified by giving the name of the
block or character special device
on which it resides, or by giving the name of its mount point.
Specify the ufs FSType. If -F ufs
is not specified heuristics similiar to those used
are used to determine the file
This command executes faster if it is not required
to autodetect file system types. If possible, specify
the -F ufs.
-y | -Y
Assume a yes response to all questions asked by fsck.
-n | -N
Assume a no response to all questions asked by fsck;
do not open the filesystem for writing.
Specify the options specific to the ufs filesystem.
These options can be any combination of the
Check the filesystem non-interactively.
Exit if there is a problem requiring intervention.
Use blkno as the super block for the filesystem.
Block 32 is always an alternate super block.
Only check writeable filesystems.
Checking the character special device is almost always faster.
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004