UTERMINAL
TERMINAL
NEXT
$V1$
PAUSE
ENCORE5
ENCORE
BOX
COMMAND
GO
fsck
SYNTAX
fsck [-y] [-n] [-sX] [-t file]
[-q] [-D] [-f] [file systems]
/etc/fsck -p [file system(s)] OR
/etc/fsck [-b block#] [-y] [-n] [file system]
FUNCTION
fsck - performs several checks on a file system
and interactively repairs inconsistent
conditions for UNIX system files.
If the file system is consistent, then the
number of files, number of blocks used, and
number of blocks free are reported.
If the file system is inconsistent, the
operator is prompted for concurrence before
each correction is attempted.
NOTE
In the process of correction, some data may be lost.
The default action for each correction is to wait for
a yes or no response from the operator. When the
operator does not have write permission, fsck defaults
to the no action.
If you are not certain what a yes response will delete,
do not use it!
When fsck is invoked without arguments,
it looks into the file /etc/checklist in order
to determine which file systems to check!
it looks into the file /etc/fstab in order
to determine which file systems to check!
SOME OPTIONS
y - assume a yes response to all questions
n - assume a no response to all questions
-sX - ignore the actual free list and (unconditionally)
reconstruct a new one by rewriting the superblock
of the file system
-SX - conditionally rebuild the free list, i.e.,
only if there are no discrepancies discovered
-t file - use file as scratch file for rebuilding tables
-q - perform fsck quietly
-D - check Directories for bad blocks
-f - performs a fast bad block check
-p - reads /etc/fstab to determine which file system to
check and checks only a restricted class of
inconsistencies
-b block# - use specified block as the superblock
Let us get a feel for how fsck works on
a consistent file system by executing the command
fsck /dev/rgb0a
fsck -p /dev/rxy0a!
$PROMPT$
That is correct!
You've got it on the 2nd try.
Good, you understand the concept.
Please enter fsck /dev/rgb0a
Please enter fsck /dev/rgb0a
Please enter fsck -p /dev/rxy0a
Please enter fsck -p /dev/rxy0a
You will be helped this time.
$PROMPT$
FORGET1
fsck /dev/rgb0a
fsck -p /dev/rxy0a
Observe the result on the terminal
/dev/rgb0a
/dev/rxy0a
Last Mounted on /
** Phase 1 - Check Blocks and Sizes
** Phase 2 - Check Pathnames
** Phase 3 - Check Connectivity
** Phase 4 - Check Reference Counts
** Phase 5 - Check Free List
** Phase 5 - Check Cyl Groups
3734 files 18256 blocks 21744 free
567 files, 6375 used, 1070 free (30 frags, 260 blocks)
$PROMPT$
If there were inconsistencies reported and
corrected, you would have to reboot the system
to erase the in memory tables, otherwise
no changes would take place.