Commit | Line | Data |
---|---|---|
e6817382 BJ |
1 | .TH ICHECK 1M |
2 | .SH NAME | |
3 | icheck \- file system storage consistency check | |
4 | .SH SYNOPSIS | |
5 | .B icheck | |
6 | [ | |
7 | .B \-s | |
8 | ] [ | |
9 | .B \-b | |
10 | numbers ] | |
11 | [ filesystem ] | |
12 | .SH DESCRIPTION | |
13 | .I Icheck | |
14 | examines a file system, | |
15 | builds a bit map of used blocks, | |
16 | and compares this bit map against | |
17 | the free list maintained on the file system. | |
18 | If the file system is not specified, | |
19 | a set of default file systems | |
20 | is checked. | |
21 | The normal output of | |
22 | .I icheck | |
23 | includes a report of | |
24 | .IP "" | |
25 | The total number of files and the numbers of | |
26 | regular, directory, block special and character special files. | |
27 | .IP "" | |
28 | The total number of blocks in use and the numbers of | |
29 | single-, double-, and triple-indirect blocks and directory blocks. | |
30 | .IP "" | |
31 | The number of free blocks. | |
32 | .IP "" | |
33 | The number of blocks missing; i.e. not in any file | |
34 | nor in the free list. | |
35 | .PP | |
36 | The | |
37 | .B \-s | |
38 | option causes | |
39 | .I icheck | |
40 | to ignore the actual free list and reconstruct a new one | |
41 | by rewriting the super-block of the file system. | |
42 | The file system should be dismounted while this is done; | |
43 | if this is not possible (for example if | |
44 | the root file system has to be salvaged) | |
45 | care should be taken that the system is quiescent and that | |
46 | it is rebooted immediately afterwards so that the old, bad in-core | |
47 | copy of the super-block will not continue to be used. | |
48 | Notice also that | |
49 | the words in the super-block | |
50 | which indicate the size of the free list and of the | |
51 | i-list are believed. | |
52 | If the super-block has been curdled | |
53 | these words will have to be patched. | |
54 | The | |
55 | .B \-s | |
56 | option | |
57 | causes the normal output reports to be suppressed. | |
58 | .PP | |
59 | Following the | |
60 | .B \-b | |
61 | option is a list of block numbers; | |
62 | whenever any of the named blocks turns up in a file, | |
63 | a diagnostic is produced. | |
64 | .PP | |
65 | .I Icheck | |
66 | is faster if the raw version of the special file is used, | |
67 | since it reads the i-list many blocks at a time. | |
68 | .SH FILES | |
69 | Default file systems vary with installation. | |
70 | .SH "SEE ALSO" | |
71 | dcheck(1), ncheck(1), | |
72 | filsys(5), clri(1) | |
73 | .SH DIAGNOSTICS | |
74 | For duplicate blocks | |
75 | and bad blocks (which lie outside the file system) | |
76 | .I icheck | |
77 | announces the difficulty, the i-number, and the kind of block involved. | |
78 | If a read error is encountered, | |
79 | the block number of the bad block is printed and | |
80 | .I icheck | |
81 | considers it to contain 0. | |
82 | `Bad freeblock' means that | |
83 | a block number outside the available space was encountered in the free list. | |
84 | `\fIn\fR dups in free' | |
85 | means that | |
86 | .IR n "" | |
87 | blocks were found in the free list which | |
88 | duplicate blocks either in some file or in the earlier part of the free list. | |
89 | .SH BUGS | |
90 | Since | |
91 | .I icheck | |
92 | is inherently two-pass in nature, extraneous diagnostics | |
93 | may be produced if applied to active file systems. | |
94 | .br | |
95 | It believes even preposterous super-blocks and | |
96 | consequently can get core images. |