File: fsck.ocfs2.checks.8.in

package info (click to toggle)
ocfs2-tools 1.8.5-7
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 7,828 kB
  • sloc: ansic: 85,876; sh: 5,775; python: 2,380; makefile: 1,281
file content (1193 lines) | stat: -rw-r--r-- 45,985 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
.TH "fsck.ocfs2.checks" "8" "January 2012" "Version @VERSION@" "OCFS2 Manual Pages"
.SH "NAME"
fsck.ocfs2.checks \- Consistency checks that 
.BR fsck.ocfs2(8)
performs and its means for fixing inconsistencies.
.SH "DESCRIPTION"
.PP 
.BR fsck.ocfs2(8)
is used to check an OCFS2 file system.  It performs many consistency checks
and will offer to fix faults that it finds.  This man page lists the problems
it may find and describes their fixes.  The problems are indexed by the error
number that 
.BR fsck.ocfs2(8)
emits when it describes the problem and asks if it should be fixed.

The prompts are constructed such that answering 'no' results in no changes
to the file system.  This may result in errors later on that stop 
.BR fsck.ocfs2(8)
from proceeding.

.SH "CHECKS"

\" escape.c

.SS "EB_BLKNO"
Extent blocks contain a record of the disk block where they are located.  An
extent block was found at a block that didn't match its recorded location.

Answering yes will update the data structure in the extent block to reflect
its real location on disk.

.SS "EB_GEN"
Extent blocks are created with a generation number to match the generation
number of the volume at the time of creation.  An extent block was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number is correct and that the
extent block is from a previous file system.  The extent block will be
ignored and the file that contains it will lose the data it referenced.

.SS "EB_GEN_FIX"
Extent blocks are created with a generation number to match the generation
number of the volume at the time of creation.  An extent block was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number in the extent block is
incorrect and that the extent block is valid.  The generation number in the
block is updated to match the generation number in the volume.

.SS "EXTENT_MARKED_UNWRITTEN"
An extent record has the UNWRITTEN flag set, but the filesystem
feature set does not include unwritten extents.

Answering yes clears the UNWRITTEN flag.  This is safe to do; as the
feature is disabled anyway.

.SS "EXTENT_MARKED_REFCOUNTED"
An extent record has the REFCOUNTED flag set, but neither the filesystem
nor the file has the REFCOUNTED flag set.

Answering yes clears the REFCOUNTED flag.

.SS "EXTENT_BLKNO_UNALIGNED"
The block that marks the start of an extent should always fall on the start
of a cluster.  An extent was found that starts part-way into a cluster.

Answering yes moves the start of the extent back to the start of the addressed
cluster.  This may add data to the middle of the file that contains this
extent.

.SS "EXTENT_CLUSTERS_OVERRUN"
An extent was found which claims to contain clusters which are beyond the
end of the volume.

Answering yes clamps the extent to the end of the volume.  This may result
in a reduced file size for the file that contains the extent, but it
couldn't have addressed those final clusters anyway.  One can imagine this
problem arising if there are problems shrinking a volume.

.SS "EXTENT_EB_INVALID"
Deep extent trees are built by forming a tree out of extent blocks.  An
extent tree references an invalid extent block.

Answering yes stops the tree from referencing the invalid extent block.  This
may truncate data from the file which contains the tree.

.SS "EXTENT_LIST_DEPTH"
Extent lists contain a record of their depth in the tree.  An extent list
was found whose recorded depth doesn't match the position they have in the
tree.

Answering yes updates the depth field in the list to match the tree on disk.

.SS "EXTENT_LIST_COUNT"
The number of entries in an extent list is bounded by either the size of the 
inode or the size of the block which contains it.  An extent list was found
which claims to have more entries than would fit in its container.

Answering yes updates the count field in the extent list to match the
container. Answering no to this question may stop further fixes from being
done because the count value can not be trusted.

.SS "EXTENT_LIST_FREE"
The number of free entries in an extent list must be less than the total
number of entries in the list.   A list was found which claims to have more
free entries than possible entries.

Answering yes sets the number of free entries in the list equal to the total
possible entries.

.SS "EXTENT_BLKNO_RANGE"
An extent record was found which references a block which can not be
referenced by an extent.  The referenced block is either very early in the
volume, and thus reserved, or beyond the end of the volume.

Answering yes removes this extent record from the tree.  This may remove data
from the file which owns the tree but any such data was inaccessible.

.SS "CHAIN_CPG"
The bitmap inode indicates a different clusters per group than the group
descriptor. This value is typically static and only modified by tunefs during
volume resize and that too only on volumes having only one cluster group.

Answering yes updates the clusters per group on the bitmap inode to the
corresponding value in the group descriptor.

.SS "SUPERBLOCK_CLUSTERS"
The super block indicates a different total clusters value than the global
bitmap. This is only possible due to a failed volume resize operation.

Answering yes updates the total clusters in the super block to the value
specified in the global bitmap.

.SS "FIXED_CHAIN_CLUSTERS"
The global bitmap inode was repaired, resulting in a change to the total
cluster count of the filesystem.

Answering yes updates the total clusters in the super block to the value
specified in the global bitmap.

\" pass0.c

.SS "GROUP_UNEXPECTED_DESC"
The group descriptors that make up the global bitmap chain allocator reside
at predictable locations on disk.  A group descriptor was found in the global
bitmap allocator which isn't at one of these locations and so shouldn't
be in the allocator.

Answering yes removes this descriptor from the global bitmap allocator.

.SS "GROUP_EXPECTED_DESC"
The group descriptors that make up the global bitmap chain allocator reside
at predictable locations on disk.  A group descriptor at one of these
locations was not linked into the global bitmap allocator.

Answering yes will relink this group into the allocator.

.SS "GROUP_GEN"
A group descriptor was found with a generation number that doesn't match
the generation number of the volume.

Answering yes sets the group descriptor's generation equal to the generation
number in the volume.

.SS "GROUP_PARENT"
Group descriptors contain a pointer to the allocator inode which contains
the chain they belong to.  A group descriptor was found in an allocator
inode that doesn't match the descriptor's parent pointer.

Answering yes updates the group descriptor's parent pointer to match the inode
it resides in.

.SS "GROUP_DUPLICATE"
Group descriptors contain a pointer to the allocator inode which contains
the chain they belong to.  A group descriptor was found in two allocator
inodes so it may be duplicated.

Answering yes removes the group descriptor from current allocator inode.

.SS "GROUP_BLKNO"
Group descriptors have a field which records their block location on disk.  A
group descriptor was found at a given location but is recorded as being
located somewhere else.

Answering yes updates the group descriptor's recorded location to match where
it actually is found on disk.

.SS "GROUP_CHAIN"
Group descriptors are found in a number of different singly-linked chains
in an allocator inode.  A group descriptor records the chain number that it
is linked in.  A group descriptor was found whose chain field doesn't match
the chain it was found in.

Answering yes sets the group descriptor's chain field to match the chain
it is found in.

.SS "GROUP_FREE_BITS"
A group descriptor records the number of bits in its bitmap that are free.
A group descriptor was found which claims to have more free bits than are
valid in its bitmap.

Answering yes decreases the number of recorded free bits so that it equals
the total number of bits in the group descriptor's bitmap.

.SS "GROUP_CHAIN_LOOP"
A chain may loop if the next field of the group descriptor points to one of
the previous group descriptors in the chain. This causes the ocfs2 code, both
user space and kernel module to loop forever.

Answering yes breaks the loop at an optimum location so that all the existing
group descriptors are in the chain. However, it cannot re-connect stray group
descriptors and must rely on the rest of the fsck code to fix it.

.SS "CHAIN_COUNT"
The chain list embedded in an inode is limited by the block size and the
number of bytes consumed by the rest of the inode.  A chain list header was
found which claimed that there are more entries in the list then could 
fit in the inode.

Answering yes resets the header's cl_count member to the maximum size allowed
by the block size after accounting for the space consumed by the inode.

.SS "CHAIN_NEXT_FREE"
This is identical to CHAIN_COUNT except that it is testing and fixing the
pointer to the next free list entry recorded in the cl_next_free_rec member
instead of the total number of entries. 

.SS "CHAIN_EMPTY"
Chain entries need to be packed such that there are no chains without 
descriptors found before the chain that is marked as free by the chain header.
A chain without descriptors was found found before that chain that was
marked free.

Answering yes will remove the unused chain and shift the remaining chains
forward in the list.

.SS "CHAIN_I_CLUSTERS"
Chain allocator inodes have an i_clusters value that represents the number
of clusters used by the allocator.  An inode was found whose i_clusters
value doesn't match the number of clusters its chains cover.

Answering yes updates i_clusters in the inode to reflect what was actually
found by walking the chain.

.SS "CHAIN_I_SIZE"
Chain allocator inodes multiply the number of bytes per cluster
by the their i_clusters value and store it in i_size.  An inode was found
which didn't have the correct value in its i_size.

Answering yes updates i_size to be the product of i_clusters and the cluster
size.  Nothing else uses this value, and previous versions of tools didn't
calculate it properly, so don't be too worried if this error appears.

.SS "CHAIN_GROUP_BITS"
The inode that contains an embedded chain list has fields which record the
total number of bits covered by the chain as well as the amount free.  These 
fields didn't match what was found in the chain. 

Answering yes updates the fields in the inode to reflect what was actually
found by walking the chain.

.SS "CHAIN_HEAD_LINK_RANGE"
The header that starts a chain tried to reference a group descriptor at
a block number that couldn't be valid.

Answering yes will clear the reference to this invalid block and truncate
the chain that it started.

.SS "CHAIN_LINK_GEN"
A reference was made to a group descriptor whose generation number doesn't
match the generation of the volume.

Answering yes to this question implies that the group descriptor is invalid
and the chain is truncated at the point that it referred to this invalid
group descriptor.  Answering no to this question considers the group
descriptor as valid and its generation may be fixed.

.SS "CHAIN_LINK_MAGIC"
Chains are built by chain headers and group descriptors which are linked
together by block references.  A reference was made to a group descriptor
at a given block but a valid group descriptor signature wasn't found
at that block.

Answering yes clears the reference to this invalid block and truncates the
chain at the point of the reference.

.SS "CHAIN_LINK_RANGE"
Chains are built by chain headers and group descriptors which are linked
together by block references.  A reference a block was found which
can't possibly be valid because it was either too small or extended beyond the
volume.

Answering yes truncates the chain in question by zeroing the invalid block
reference.  This shortens the chain in question and could result in more
fixes later if the part of the chain that couldn't be referenced was valid
at some point.

.SS "CHAIN_BITS"
A chain's header contains members which record the total number of bits in the
chain as well as the number of bits that are free.  After walking through a
chain it was found that the number of bits recorded in its header don't match
what was found by totalling up the group descriptors.

Answering yes updates the c_total and c_free members of the header to reflect
what was found in the group descriptors in the chain.

.SS "DISCONTIG_BG_DEPTH"
A discontiguous block group has an extent list which records all the clusters
allocated to it.  Discontiguous block groups only support extent lists with
a tree depth of 0.  A block group claims to have a tree depth greater than 0.

Answering yes will set the tree depth of the extent list to 0.

.SS "DISCONTIG_BG_COUNT"
A discontiguous block group has an extent list which records all the clusters
allocated to it. A block group claims to have more records than can actually
fit.

Answering yes will set the record count to the maximum possible.

.SS "DISCONTIG_BG_REC_RANGE"
Block groups set aside clusters to be used for metadata.  A discontiguous
block group claims to contain clusters beyond the end of the volume.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_CORRUPT_LEAVES"
A discontiguous block group has an extent list which records all the clusters
allocated to it.  A group has more than one extent claiming to have an
impossible number of clusters.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_CLUSTERS"
Extent records in a discontiguous block group were found having more clusters
allocated then a block group can have.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_LESS_CLUSTERS"
Extent records in a discontiguous block group were found having less clusters
allocated then a block group can have.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_NEXT_FREE_REC"
A discontiguous block group has an extent list which records all the clusters
allocated to it. A group was found with fewer filled in extents than it claims
to have.  The filled in extents describe a complete and correct group.

Answering yes will set the used extent count to the number of filled extents.

.SS "DISCONTIG_BG_LIST_CORRUPT"
A discontiguous block group has an extent list which records all the clusters
allocated to it.  The group claims to have more extents than is possible, and
the existing extents contain errors.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_REC_CORRUPT"
A discontiguous block group has a extent list which records all the clusters
allocated to it.  A group was found with one extent claiming too many
clusters but the sum of the remaining extents are equal to the total clusters
a group must have.

Answering yes will remove the block group.

.SS "DISCONTIG_BG_LEAF_CLUSTERS"
A discontiguous block group has a extent list which records all the clusters
allocated to it.  A group was found with one extent claiming too many
clusters, but the remaining extents are correct.

Answering yes will set the number of the clusters on the broken extent
to the difference between the total clusters a group must have and the
sum of the remaining extents.

\" pass1.c

.SS "INODE_ALLOC_REPAIR"
The inode allocator did not accurately reflect the set of inodes that are
free and in use in the volume.

Answering yes will update the inode allocator bitmaps.  Each bit that
doesn't match the state of its inode will be inverted.

.SS "INODE_SUBALLOC"
Each inode records the node whose allocator is responsible for the inode.  An
inode was found in a given node's allocator but the inode itself claimed to
belong to a different node.

Answering yes will correct the inode to point to the node's allocator that it
belongs to.

.SS "LALLOC_SIZE"
Each node has a local allocator contained in a block that is used to allocate
clusters in batches.  A node's local allocator claims to reflect more bytes
than are possible for the volume's block size.

Answering yes decreases the local allocator's size to reflect the volume's
block size.

.SS "LALLOC_NZ_USED"
A given node's local allocator isn't in use but it claims to have bits
in use in its bitmap.

Answering yes zeros this used field.

.SS "LALLOC_NZ_BM"
A given node's local allocator isn't in use but it has a field which records
the bitmap as starting at a non-zero cluster offset.

Answering yes zeros the bm_off field.

.SS "LALLOC_BM_OVERRUN"
Each local allocator contains a reference to the first cluster that its bitmap
addresses.  A given local allocator was found which references a starting
cluster that is beyond the end of the volume.

Answering yes resets the given local allocator.  No allocated data will
be lost.

.SS "LALLOC_BM_SIZE"
The given local allocator claims to cover more bits than are possible for the
size in bytes of its bitmap.

Answering yes decreases the number of bits the allocator covers to reflect
the size in bytes of the bitmap and resets the allocator.  No allocated
data will be lost.

.SS "LALLOC_BM_STRADDLE"
The given local allocator claims to cover a region of clusters which extents
beyond the end of the volume.

Answering yes resets the given local allocator.  No allocated data will
be lost.

.SS "LALLOC_USED_OVERRUN"
The given local allocator claims to have more bits in use than it has total
bits in its bitmap.

Answering yes decreases the number of bits used so that it equals the total
number of available bits.

.SS "LALLOC_CLEAR"
A local allocator inode was found to have problems.  This gives the operator
a chance to just reset the local allocator inode. 

Answering yes clears the local allocator.  No information is lost but the
global bitmap allocator may need to be updated to reflect clusters that were
reserved for the local allocator but were free.

.SS "DEALLOC_COUNT"
The given truncate log inode contains a count that is greater than the 
value that is possible given the size of the inode.

Answering yes resets the count value to the possible maximum.

.SS "DEALLOC_USED"
The given truncate log inode claims to have more records in use than
it is possible to store in the inode.

Answering yes resets the record of the number used to the maximum 
value possible.

.SS "TRUNCATE_REC_START_RANGE"
A truncate record was found which claims to start at a cluster that is beyond
the number of clusters in the volume.

Answering yes will clear the truncate record.  This may result in previously
freed space being marked as allocated.  This will be fixed up later as the
allocator is updated to match what is used by the file system.

.SS "TRUNCATE_REC_WRAP"
Clusters are recorded as 32bit values.  A truncate record was found which
claims to have enough clusters to cause this value to wrap.  This could
never be the case and is a sure sign of corruption.

Answering yes will clear the truncate record.  This may result in previously
freed space being marked as allocated.  This will be fixed up later as the
allocator is updated to match what is used by the file system.

.SS "TRUNCATE_REC_RANGE"
A truncate record was found which claims to reference a region of clusters
which partially extends beyond the number of clusters in the volume.

Answering yes will clear the truncate record.  This may result in previously
freed space being marked as allocated.  This will be fixed up later as the
allocator is updated to match what is used by the file system.

.SS "INODE_GEN"
Inodes are created with a generation number to match the generation
number of the volume at the time of creation.  An Inode was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number is correct and that the
inode is from a previous file system.  The inode will be recorded as free.

.SS "INODE_GEN_FIX"
Inodes are created with a generation number to match the generation
number of the volume at the time of creation.  An inode was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number in the inode is
incorrect and that the inode is valid.  The generation number in the
inode is updated to match the generation number in the volume.

.SS "INODE_BLKNO"
Inodes contain a field that must match the block that they reside in. 
An inode was found at a block that doesn't match the field in the inode.

Answering yes updates the field to match the inode's position on disk.

.SS "ROOT_NOTDIR"
The super block contains a reference to the inode that contains the root
directory.  This block was found to contain an inode that isn't a directory.

Answering yes clears this inode.  The operator will be asked to recreate
the root directory at a point in the near future.

.SS "INODE_NZ_DTIME"
Inodes contain a field describing the time at which they were deleted.  This
can not be set for an inode that is still in use.  An inode was found
which is in use but which contains a non-zero dtime.

Answering yes implies that the inode is still valid and resets its dtime
to zero.

.SS "LINK_FAST_DATA"
The target name for a symbolic link is stored either as file contents for
that inode or in the inode structure itself on disk.  Only small destination
names are stored in the inode structure.  The i_blocks field of the inode 
indicates that the name is stored in the inode when it is zero.  An inode
was found that has both i_blocks set to zero and file contents. 

Answering yes clears the inode and so deletes the link.

.SS "LINK_NULLTERM"
The targets of links on disk must be null terminated.  A link was found
whose target wasn't null terminated. 

Answering yes clears the inode and so deletes the link.

.SS "LINK_SIZE"
The size of a link on disk must match the length of its target string.
A link was found whose size does not.

Answering yes updates the link's size to reflect the length of its target
string.

.SS "LINK_BLOCKS"
Links can not be sparse.  There must be exactly as many blocks allocated
as are needed to cover its size.  A link was found which doesn't have enough
blocks allocated to cover its size.

Answering yes clears the link's inode thus deleting the link.

.SS "DIR_ZERO"
Directories must at least contain a block that has the "." and ".." entries.
A directory was found which doesn't contain any blocks.

Answering yes to this question clears the directory's inode thus
deleting the directory.

.SS "INODE_SIZE"
Certain inodes record the size of the data they reference in an i_size field.
This can be the number of bytes in a file, directory, or symlink target
which are stored in data mapped by extents of clusters.  This error occurs
when the extent lists are walked and the amount of data found does not match
what is stored in i_size.

Answering yes to this question updates the inode's i_size to match the amount
of data referenced by the extent lists.  It is vitally important that i_size
matches the extent lists and so answering yes is strongly encouraged.

.SS "INODE_SPARSE_SIZE"
Certain inodes record the size of the data they reference in an i_size field.
This can be the number of bytes in a file, directory, or symlink target
which are stored in data mapped by extents of clusters. This error occurs when
a sparse inode was found that had data allocated past its i_size.

Answering yes to this question will update the inode's i_size to cover all of
its allocated storage.  It is vitally important that i_size matches the extent
lists and so answering yes is strongly encouraged.

.SS "INODE_INLINE_SIZE"
Inodes can only fit a certain amount of inline data.  This inode has its data
inline but claims an i_size larger than will actually fit.

Answering yes to this question updates the inode's i_size to the maximum available
inline space.

.SS "INODE_CLUSTERS"
Inodes contain a record of how many clusters are allocated to them.  An inode
was found whose recorded number of clusters doesn't match the number of blocks
that were found associated with the inode.

Answering yes resets the inode's number of clusters to reflect the number
of blocks that were associated with the file.

.SS "INODE_SPARSE_CLUSTERS"
Inodes contain a record of how many clusters are allocated to them.  An sparse
inode was found whose recorded number of clusters doesn't match the number of
blocks that were found associated with the inode.

Answering yes resets the inode's number of clusters to reflect the number
of blocks that were associated with the file.

.SS "INODE_INLINE_CLUSTERS"
Inlined inode should not have allocated clusters.  An inode who has inline data
flag set was found with clusters allocated.

Answering yes resets the inode's number of clusters to zero.

.SS "LALLOC_REPAIR"
An active local allocator did not accurately reflect the set of clusters that
are free and in use in its region.

Answering yes will update the local allocator bitmap.  Each bit that doesn't
match the use of its cluster will be inverted.

.SS "LALLOC_USED"
A local allocator records the number of bits that are used in its bitmap.  An
allocator was found whose used value doesn't reflect the number of bits that
are set in its bitmap.

Answering yes sets the used value to match the number of bits set in the 
allocator's bitmap.

.SS "CLUSTER_ALLOC_BIT"
A specific cluster's use didn't match the setting of its bit in the cluster
allocator.

Answering yes will invert the bit in the allocator to match the use of the
cluster -- either allocated and in use or free.

.SS "REFCOUNT_FLAG_INVALID"
Refcount file can only exist in a volume with refcount supported, Fsck has
found that a file in a non-refcount volume has refcount flag set.

Answering yes remove this flag from the file.

.SS "REFCOUNT_LOC_INVALID"
Refcount loc can only be valid if the file has refcount flag set. Fsck has
found that a file has refcount loc while it doesn't have refcount flag set.

Answering yes reset refcount loc to zero for the file.

.SS "RB_BLKNO"
refcount blocks contain a record of the disk block where they are located.
An refcount block was found at a block that didn't match its recorded location.

Answering yes will update the data structure in the refcount block to reflect
its real location on disk.

.SS "RB_GEN"
Refcount blocks are created with a generation number to match the generation
number of the volume at the time of creation.  An refcount block was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number is correct and that the
refcount block is from a previous file system.  The refcount block will be
removed and the file that uses it will lose the refcounted information, but
it may be regenerated later.

.SS "RB_GEN_FIX"
Refcount blocks are created with a generation number to match the generation
number of the volume at the time of creation.  An refcount block was found which
contains a generation number that doesn't match.

Answering yes implies that the generation number in the refcount block is
incorrect and that the refcount block is valid.  The generation number in the
block is updated to match the generation number in the volume.

.SS "RB_PARENT"
refcount blocks contain a record of the parent this disk block belongs to.
An refcount block was found storing a wrong parent location.

Answering yes will update the data structure in the refcount block to reflect
its parent's real location on disk.

.SS "REFCOUNT_LIST_COUNT"
The number of entries in a refcount list is bounded by the size of the block
which contains it.  An refcount list was found which claims to have more
entries than would fit in its container.

Answering yes updates the count field in the refcount list to match the
container. Answering no to this question may stop further fixes from being
done because the count value can not be trusted.

.SS "REFCOUNT_LIST_USED"
The number of free entries in a refcount list must be less than the total
number of entries in the list.   A list was found which claims to have more
free entries than possible entries.

Answering yes sets the number of free entries in the list equal to the total
possible entries.

.SS "REFCOUNT_CLUSTER_RANGE"
A refcount record was found which references a cluster which can not be
referenced by a refcount.  The referenced cluster is either very early in the
volume, and thus reserved, or beyond the end of the volume.

Answering yes removes this refcount record from the tree.

.SS "REFCOUNT_CLUSTER_COLLISION"
A refcount record was found which references a cluster which has a collision
with the previous valid refcount record.

Answering yes removes this refcount record from the tree.

.SS "REFCOUNT_LIST_EMPTY"
A refcount list was found which has no refcount record in it. It is normally
caused by a corrupted refcount record.

Answering yes removes this refcount block from the tree. It will be
re-generated in refcounted extent records handler if all the other
information is sane.

.SS "REFCOUNT_BLOCK_INVALID"
Refcount block stores the refcount record for physical clusters of a file.
It is found referring an invalid refcount block.

Answering yes remove this refcount block.

.SS "REFCOUNT_CLUSTERS"
Refcount tree contains a record of how many clusters are allocated to them.
A tree was found whose recorded number of clusters doesn't match the number
of blocks that were found associated with it.

Answering yes resets the number of clusters to reflect the real number
of clusters that were associated with the tree.

.SS "REFCOUNT_ROOT_BLOCK_INVALID"
Root refcount block is the root of the refcount record for a file. It is found
referring an invalid refcount block.

Answering yes remove this refcount block and clear refcount flag from this file.

.SS "REFCOUNT_REC_REDUNDANT"
Refcount record is used to store the refcount for physical clusters. Some
refcount record is found to have no physical clusters corresponding to it.

Answering yes remove the refcount record.

.SS "REFCOUNT_COUNT_INVALID"
Refcount record is used to store the refcount for physical clusters. A record
record is found whichs claims the wrong refcount for some physical clusters.

Answering yes update the corresponding refcount record.

.SS "REFCOUNT_COUNT"
Refcount tree contains a record of how many files referring to this tree.
A tree was found whose recorded number of files doesn't match the real
files referring to the tree.

Answering yes resets the number of files to reflect the real number
of files that were associated with the tree.

\" pass1b.c

.SS "DUP_CLUSTERS_SYSFILE_CLONE"
A system file inode claims clusters that are also claimed by another inode.
ocfs2 does not allow this.  System files may be cloned but may not be
deleted.  Allocation system files may not be cloned or deleted.

Answering yes will copy the data of this inode to newly allocated extents.
This will break the claim on the overcommitted clusters.

.SS "DUP_CLUSTERS_CLONE"
An inode claims clusters that are also claimed by another inode.  ocfs2
does not allow this.

Answering yes will copy the data of this inode to newly allocated extents.
This will break the claim on the overcommitted clusters.

.SS "DUP_CLUSTERS_DELETE"
An inode claims clusters that are also claimed by another inode.  ocfs2
does not allow this.

Answering yes will remove this inode, thus breaking its claim on the
overcommitted clusters.

.SS "DUP_CLUSTERS_ADD_REFCOUNT"
An inode claims clusters that are also claimed by another inode.  ocfs2
does not allow this.

Answering yes will try to add a refcount record for all these inodes, so
that they will share the cluster.

\" pass2.c

.SS "DIRENT_DOTTY_DUP"
There can be only one instance of both the "." and ".." entries in a
directory. A directory entry was found which duplicated one of these entries.

Answering yes will remove the duplicate directory entry.

.SS "DIRENT_NOT_DOTTY"
The first and second directory entries in a directory must be "." and ".."
respectively.  One of these directory entries was found to not match these
rules.

Answering yes will force the directory entry to be either "." or "..".  This
might consume otherwise valid entries and cause some files to appear in 
lost+found.

.SS "DIRENT_DOT_INODE"
The inode field of the "." directory entry must refer to the directory inode
that contains the given directory block.  A "." entry was found which doesn't
do so.

Answering yes sets the directory entry's inode reference to the parent
directory that contains the entry.

.SS "DIRENT_DOT_EXCESS"
A "." directory entry was found whose lengths exceeds the amount required
for the single dot in the name.

Answering yes creates another empty directory entry in this excess space.

.SS "DIRENT_ZERO"
A directory entry was found with a zero length name.

Answering yes clears the directory entry so its space can be reused.

.SS "DIRENT_NAME_CHARS"
Directory entries can not contain either the NULL character (ASCII 0) or 
the forward slash (ASCII 47).  A directory entry was found which contains
either.

Answering yes will change each instance of these forbidden characters into
a period (ASCII 46).

.SS "DIRENT_INODE_RANGE"
Each directory entry contains a inode field which the entry's name corresponds
to.  An entry was found which referenced an inode number that is invalid
for the current volume.

Answering yes clears this entry so its space can be reused.  If the entry
once corresponded to a real inode and was corrupted this inode may appear
in lost+found.

.SS "DIRENT_INODE_FREE"
Each directory entry contains a inode field which the entry's name corresponds
to.  An entry was found which referenced an inode number that isn't in
use.

Answering yes clears this directory entry.

.SS "DIRENT_TYPE"
Each directory entry contains a field which describes the type of file
that the entry refers to.  An entry was found whose type doesn't match the
inode it is referring to.

Answering yes resets the entry's type to match the target inode.

.SS "DIR_PARENT_DUP"
Each directory can only be pointed to by one directory entry in a parent
directory.  A directory entry was found which was the second entry to point
to a given directory inode.

Answering yes clears this entry which was the second to refer to a given
directory.  This reflects the policy that hard links to directories are not
allowed.

.SS "DIRENT_DUPLICATE"
File names within a directory must be unique.  A file name occurred in more
than one directory entry in a given directory.

Answering yes renames the duplicate entry to a name that doesn't collide
with recent entries and is unlikely to collide with future entries in
the directory.

.SS "DIRENT_LENGTH"
There are very few directory entry lengths that are valid.  The lengths must
be greater than the minimum required to record a single character directory,
be rounded to 12 bytes, be within the amount of space remaining in a directory
block, and be properly rounded for the size of the name of the directory
entry. An entry was found which didn't meet these criteria.

Answering yes will try to repair the directory entry.  This runs a very good
chance of invalidating all the entries in the directory block.  Orphaned
inodes may appear in lost+found.

.SS "DIR_TRAILER_INODE"
A directory block trailer is a fake directory entry at the end of the
block.  The trailer has compatibility fields for when it is viewed as a
directory entry.  The inode field must be zero.

Answering yes will set the inode field to zero.

.SS "DIR_TRAILER_NAME_LEN"
A directory block trailer is a fake directory entry at the end of the
block.  The trailer has compatibility fields for when it is viewed as a
directory entry.  The name length field must be zero.

Answering yes will set the name length field to zero.

.SS "DIR_TRAILER_REC_LEN"
A directory block trailer is a fake directory entry at the end of the
block.  The trailer has compatibility fields for when it is viewed as a
directory entry.  The record length field must be equal to the size of
the trailer.

Answering yes will set the record length field to the size of the trailer.

.SS "DIR_TRAILER_BLKNO"
A directory block trailer is a fake directory entry at the end of the
block.  The self-referential block number is incorrect.

Answering yes will set the block number to the correct block on disk.

.SS "DIR_TRAILER_PARENT_INODE"
A directory block trailer is a fake directory entry at the end of the
block.  It has a pointer to the directory inode it belongs to.  This
pointer is incorrect.

Answering yes will set the parent inode pointer to the inode referencing
this directory block.

\" pass3.c

.SS "ROOT_DIR_MISSING"
The super block contains a reference to the inode that serves as the root
directory.  This reference points to an inode that isn't in use.

Answering yes will create a new inode and update the super block to refer
to this inode as the root directory.

.SS "LOSTFOUND_MISSING"
The super block contains a reference to the inode that serves as the
lost+found directory.  This reference points to an inode that isn't in use.

Answering yes will create a new lost+found directory in the root directory.

.SS "DIR_NOT_CONNECTED"
Every directory in the file system should be reachable by a directory entry
in its parent directory.  This is verified by walking every directory in
the system.  A directory inode was found during this walk which doesn't have
a parent directory entry.

Answering yes moves this directory entry into the lost+found directory and 
gives it a name based on its inode number.

.SS "DIR_DOTDOT"
A directory inode's ".." directory entry must refer to the parent directory.
A directory was found whose ".." doesn't refer to its parent.

Answering yes will read the directory block for the given directory and update
its ".." entry to reflect its parent.

\" pass4.c

.SS "INODE_NOT_CONNECTED"
Most all inodes in the system should be referenced by a directory entry. An
inode was found which isn't referred to by any directory entry.

Answering yes moves this inode into the lost+found directory and 
gives it a name based on its inode number.

.SS "INODE_COUNT"
Each inode records the number of directory entries that refer to it.  An inode
was found whose recorded count doesn't match the number of entries that
refer to it.

Answering yes sets the inode's count to match the number of referring
directory entries.

.SS "INODE_ORPHANED"
While files are being deleted they are placed in an internal directory.  If
the machine crashes while this is taking place the files will be left in
this directory.  Fsck has found an inode in this directory and would like
to finish the job of truncating and removing it.

Answering yes removes the file data associated with the inode and frees
the inode.

.SS "RECOVER_BACKUP_SUPERBLOCK"
When \fIfsck.ocfs2\fR successfully uses the specified backup superblock,
it provides the user with this option to overwrite the existing superblock
with that backup.

Answering yes will refresh the superblock from the backup. Answering no will
only disable the copying of the backup superblock and will not effect the
remaining \fIfsck.ocfs2\fR processing.

.SS "ORPHAN_DIR_MISSING"
While files are being deleted they are placed in an internal directory, named
orphan directory. If an orphan directory does not exist, an OCFS2 volume cannot
be mounted successfully. Fsck has found the orphan directory is missing and
would like to create it for future use.

Answering yes creates the orphan directory in the system directory.

.SS "JOURNAL_FILE_INVALID"
OCFS2 uses JDB for journalling and some journal files exist in the
system directory. Fsck has found some journal files that are invalid.

Answering yes to this question will regenerate the invalid journal files.

.SS "JOURNAL_UNKNOWN_FEATURE"
Fsck has found some journal files with unknown features.  Other journals
on the filesystem have only known features, so this is likely a corruption.
If you think your filesystem may be newer than this version of fsck.ocfs2,
say N here and grab the latest version of fsck.ocfs2.

Answering yes resets the journal features to match other journals.

.SS "JOURNAL_MISSING_FEATURE"
Fsck has found some journal files have features that are not set on all
journal files. All journals on filesystem should have the same set of
features.

Answering yes will set all journals to the union of set features.

.SS "JOURNAL_TOO_SMALL"
Fsck has found some journal files are too small.

Answering yes extends these journals.

.SS "RECOVER_CLUSTER_INFO"
The currently active cluster stack is different than the one the filesystem
is configured for.  Thus, fsck.ocfs2 cannot determine whether the
filesystem is mounted on an another node or not. The recommended solution
is to exit and run fsck.ocfs2 on this device from a node that has the
appropriate active cluster stack. However, you can proceed with the fsck if
you are sure that the volume is not in use on any node.

Answering yes reconfigures the filesystem to use the current cluster stack.
DANGER: YOU MUST BE ABSOLUTELY SURE THAT NO OTHER NODE IS USING THIS FILESYSTEM
BEFORE CONTINUING.  OTHERWISE, YOU CAN CORRUPT THE FILESYSTEM AND LOSE DATA.

.SS "INLINE_DATA_FLAG_INVALID"
Inline file can only exist in a volume with inline supported, Fsck has found
that a file in a non-inline volume has inline flag set.

Answering yes remove this flag from the file.

.SS "INLINE_DATA_COUNT_INVALID"
For an inline file, there is a limit for id2.id_data.id_count. Fsck has found
that this value isn't right.

Answering yes change this value to the right number.

.SS "XATTR_BLOCK_INVALID"
Extended attributes are stored off an extended attribute block
referenced by the inode.  This inode references an invalid extended
attribute block.

Answering yes will remove this block.

.SS "XATTR_COUNT_INVALID"
The count of extended attributes in an inode, block, or bucket
does not match the number of entries found by fsck.

Answering yes will change this to the correct count.

.SS "XATTR_ENTRY_INVALID"
An extended attribute entry points to already used space.

Answering yes will remove this entry.

.SS "XATTR_NAME_OFFSET_INVALID"
The name_offset field of an extended attribute entry is not correct.
Without a correct name_offset field, the entry cannot be used.

Answering yes will remove this entry.

.SS "XATTR_VALUE_INVALID"
The value region of an extended attribute points to already
used space.

Answering yes will remove this entry.

.SS "XATTR_LOCATION_INVALID"
The xe_local field and xe_value_size field of an extended attribute
entry does not match. So the entry cannot be used.

Answering yes will remove this entry.

.SS "XATTR_HASH_INVALID"
Extended attributes use a hash of their name for lookup purposes.
The name_hash of this extended attribute entry is not correct.

Answering yes will change this to the correct hash.

.SS "XATTR_FREE_START_INVALID"
Extended attributes use free_start to indicate the offset of the
free space in inode, block, or bucket. The free_start field
of this object is not correct.

Answering yes will change this to the correct offset.

.SS "XATTR_VALUE_LEN_INVALID"
Extended attributes use name_value_len to store the total length
of all entry's name and value in inode, block or bucket.
the name_value_len filed of this object is not correct.

Answering yes will change this to the correct value.

.SS "XATTR_BUCKET_COUNT_INVALID"
The count of extended attributes bucket pointed by one extent record
does not match the number of buckets found by fsck.

Answering yes will change this to the correct count.

\" pass5.c

.SS "QMAGIC_INVALID"
The magic number in the header of quota file does not match the proper
number.

Answering yes will make fsck use values in the quota file header anyway.

.SS "QTREE_BLK_INVALID"
Block with references to other blocks with quota data is corrupted.

Answering yes will make fsck use references in the block.

.SS "DQBLK_INVALID"
The structure with quota limits was found in a corrupted block.

Answering yes will use the values of limits for the user / group.

.SS "DUP_DQBLK_INVALID"
The structure with quota limits was found in a corrupted block
and fsck has already found quota limits for this user / group.

Answering yes will use new values of limits for the user / group.

.SS "DUP_DQBLK_VALID"
The structure with quota limits was found in a correct block
but fsck has already found quota limits for this user / group.

Answering yes will use new values of limits for the user / group.

.SS "IV_DX_TREE"
A directory index was found on an inode but that feature is not enabled on the
file system.

Answering yes will truncate the invalid index.

.SS "DX_LOOKUP_FAILED"
A directory entry is missing an entry in the directory index. The missing
index entry will cause lookups on this name to fail.

Answering yes will rebuild the directory index, restoring the missing entry.

.SS "NO_HOLES"
A metadata structure encountered a hole where it should not. Examples of such
structures are directories, refcount trees, dx_trees etc.

Answering yes will remove the hole by updating the offset to the expected value.

.SS "EXTENT_OVERLAP"
The extents of the file overlap, which means there could be two or more
possible data for a particular offset for the file.

Answering yes will serialize the extents.

.SS "DX_TREE_CORRUPT"
The index tree of the directory is corrupt.

Answering yes will rebuild the directory index, in pass 2.


.SS "DX_TREE_MISSING"
The index of this directory is missing.

Answering yes will rebuild the directory index.

.SS "BAD_CRC32"
The metadata block has a bad CRC32, which means either the block or the 
crc32 field is corrupted. 

Answering yes will recalculate the CRC32.

.SH "SEE ALSO"
.BR debugfs.ocfs2(8)
.BR fsck.ocfs2(8)
.BR mkfs.ocfs2(8)
.BR mount.ocfs2(8)
.BR mounted.ocfs2(8)
.BR o2cluster(8)
.BR o2image(8)
.BR o2info(1)
.BR tunefs.ocfs2(8)

.SH "AUTHORS"
Oracle Corporation.

.SH "COPYRIGHT"
Copyright \(co 2004, 2012 Oracle. All rights reserved.