Whamcloud - gitweb
LUDOC-403 acl: Update link for POSIX ACL paper
[doc/manual.git] / TroubleShootingRecovery.xml
1 <?xml version='1.0' encoding='utf-8'?>
2 <chapter xmlns="http://docbook.org/ns/docbook"
3 xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:lang="en-US"
4 xml:id="troubleshootingrecovery">
5   <title xml:id="troubleshootingrecovery.title">Troubleshooting
6   Recovery</title>
7   <para>This chapter describes what to do if something goes wrong during
8   recovery. It describes:</para>
9   <itemizedlist>
10     <listitem>
11       <para>
12         <xref linkend="dbdoclet.50438225_71141" />
13       </para>
14     </listitem>
15     <listitem>
16       <para>
17         <xref linkend="dbdoclet.50438225_37365" />
18       </para>
19     </listitem>
20     <listitem>
21       <para>
22         <xref linkend="dbdoclet.50438225_12316" />
23       </para>
24     </listitem>
25     <listitem>
26       <para>
27         <xref linkend="dbdoclet.lfsckadmin" />
28       </para>
29     </listitem>
30   </itemizedlist>
31   <section xml:id="dbdoclet.50438225_71141">
32     <title>
33     <indexterm>
34       <primary>recovery</primary>
35       <secondary>corruption of backing ldiskfs file system</secondary>
36     </indexterm>Recovering from Errors or Corruption on a Backing ldiskfs File
37     System</title>
38     <para>When an OSS, MDS, or MGS server crash occurs, it is not necessary to
39     run e2fsck on the file system.
40     <literal>ldiskfs</literal> journaling ensures that the file system remains
41     consistent over a system crash. The backing file systems are never accessed
42     directly from the client, so client crashes are not relevant for server
43     file system consistency.</para>
44     <para>The only time it is REQUIRED that
45     <literal>e2fsck</literal> be run on a device is when an event causes
46     problems that ldiskfs journaling is unable to handle, such as a hardware
47     device failure or I/O error. If the ldiskfs kernel code detects corruption
48     on the disk, it mounts the file system as read-only to prevent further
49     corruption, but still allows read access to the device. This appears as
50     error "-30" (
51     <literal>EROFS</literal>) in the syslogs on the server, e.g.:</para>
52     <screen>Dec 29 14:11:32 mookie kernel: LDISKFS-fs error (device sdz):
53             ldiskfs_lookup: unlinked inode 5384166 in dir #145170469
54 Dec 29 14:11:32 mookie kernel: Remounting filesystem read-only </screen>
55     <para>In such a situation, it is normally required that e2fsck only be run
56     on the bad device before placing the device back into service.</para>
57     <para>In the vast majority of cases, the Lustre software can cope with any
58     inconsistencies found on the disk and between other devices in the file
59     system.</para>
60     <note>
61           <para>The legacy offline-LFSCK tool included with e2fsprogs is rarely
62       required for Lustre file system operation. offline-LFSCK is not to be
63       confused with LFSCK tool, which is part of Lustre and provides online
64       consistency checking.</para>
65     </note>
66     <para>For problem analysis, it is strongly recommended that
67     <literal>e2fsck</literal> be run under a logger, like script, to record all
68     of the output and changes that are made to the file system in case this
69     information is needed later.</para>
70     <para>If time permits, it is also a good idea to first run
71     <literal>e2fsck</literal> in non-fixing mode (-n option) to assess the type
72     and extent of damage to the file system. The drawback is that in this mode,
73     <literal>e2fsck</literal> does not recover the file system journal, so there
74     may appear to be file system corruption when none really exists.</para>
75     <para>To address concern about whether corruption is real or only due to
76     the journal not being replayed, you can briefly mount and unmount the
77     <literal>ldiskfs</literal> file system directly on the node with the Lustre
78     file system stopped, using a command similar to:</para>
79     <screen>mount -t ldiskfs /dev/{ostdev} /mnt/ost; umount /mnt/ost</screen>
80     <para>This causes the journal to be recovered.</para>
81     <para>The
82     <literal>e2fsck</literal> utility works well when fixing file system
83     corruption (better than similar file system recovery tools and a primary
84     reason why
85     <literal>ldiskfs</literal> was chosen over other file systems). However, it
86     is often useful to identify the type of damage that has occurred so an
87     <literal>ldiskfs</literal> expert can make intelligent decisions about what
88     needs fixing, in place of
89     <literal>e2fsck</literal>.</para>
90     <screen>root# {stop lustre services for this device, if running}
91 root# script /tmp/e2fsck.sda
92 Script started, file is /tmp/e2fsck.sda
93 root# mount -t ldiskfs /dev/sda /mnt/ost
94 root# umount /mnt/ost
95 root# e2fsck -fn /dev/sda   # don't fix file system, just check for corruption
96 :
97 [e2fsck output]
98 :
99 root# e2fsck -fp /dev/sda   # fix errors with prudent answers (usually <literal>yes</literal>)</screen>
100   </section>
101   <section xml:id="dbdoclet.50438225_37365">
102     <title>
103     <indexterm>
104       <primary>recovery</primary>
105       <secondary>corruption of Lustre file system</secondary>
106     </indexterm>Recovering from Corruption in the Lustre File System</title>
107     <para>In cases where an ldiskfs MDT or OST becomes corrupt, you need to run
108     e2fsck to correct the local filesystem consistency, then use
109     <literal>LFSCK</literal> to run a distributed check on the file system to
110     resolve any inconsistencies between the MDTs and OSTs, or among MDTs.</para>
111     <orderedlist>
112       <listitem>
113         <para>Stop the Lustre file system.</para>
114       </listitem>
115       <listitem>
116         <para>Run
117         <literal>e2fsck -f</literal> on the individual MDT/OST that had
118         problems to fix any local file system damage.</para>
119         <para>We recommend running
120         <literal>e2fsck</literal> under script, to create a log of changes made
121         to the file system in case it is needed later. After
122         <literal>e2fsck</literal> is run, bring up the file system, if
123         necessary, to reduce the outage window.</para>
124       </listitem>
125     </orderedlist>
126     <section xml:id="dbdoclet.50438225_13916">
127       <title>
128       <indexterm>
129         <primary>recovery</primary>
130         <secondary>orphaned objects</secondary>
131       </indexterm>Working with Orphaned Objects</title>
132       <para>The simplest problem to resolve is that of orphaned objects. When
133       the LFSCK layout check is run, these objects are linked to new files and
134       put into 
135       <literal>.lustre/lost+found/MDT<replaceable>xxxx</replaceable></literal> 
136       in the Lustre file system 
137       (where MDTxxxx is the index of the MDT on which the orphan was found),
138       where they can be examined and saved or deleted as necessary.</para>
139       <para condition='l27'>With Lustre version 2.7 and later, LFSCK will
140        identify and process orphan objects found on MDTs as well.</para>
141     </section>
142   </section>
143   <section xml:id="dbdoclet.50438225_12316">
144     <title>
145     <indexterm>
146       <primary>recovery</primary>
147       <secondary>unavailable OST</secondary>
148     </indexterm>Recovering from an Unavailable OST</title>
149     <para>One problem encountered in a Lustre file system environment is when
150     an OST becomes unavailable due to a network partition, OSS node crash, etc.
151     When this happens, the OST's clients pause and wait for the OST to become
152     available again, either on the primary OSS or a failover OSS. When the OST
153     comes back online, the Lustre file system starts a recovery process to
154     enable clients to reconnect to the OST. Lustre servers put a limit on the
155     time they will wait in recovery for clients to reconnect.</para>
156     <para>During recovery, clients reconnect and replay their requests
157     serially, in the same order they were done originally. Until a client
158     receives a confirmation that a given transaction has been written to stable
159     storage, the client holds on to the transaction, in case it needs to be
160     replayed. Periodically, a progress message prints to the log, stating
161     how_many/expected clients have reconnected. If the recovery is aborted,
162     this log shows how many clients managed to reconnect. When all clients have
163     completed recovery, or if the recovery timeout is reached, the recovery
164     period ends and the OST resumes normal request processing.</para>
165     <para>If some clients fail to replay their requests during the recovery
166     period, this will not stop the recovery from completing. You may have a
167     situation where the OST recovers, but some clients are not able to
168     participate in recovery (e.g. network problems or client failure), so they
169     are evicted and their requests are not replayed. This would result in any
170     operations on the evicted clients failing, including in-progress writes,
171     which would cause cached writes to be lost. This is a normal outcome; the
172     recovery cannot wait indefinitely, or the file system would be hung any
173     time a client failed. The lost transactions are an unfortunate result of
174     the recovery process.</para>
175     <note>
176       <para>The failure of client recovery does not indicate or lead to
177       filesystem corruption. This is a normal event that is handled by the MDT
178       and OST, and should not result in any inconsistencies between
179       servers.</para>
180     </note>
181     <note>
182       <para>The version-based recovery (VBR) feature enables a failed client to
183       be ''skipped'', so remaining clients can replay their requests, resulting
184       in a more successful recovery from a downed OST. For more information
185       about the VBR feature, see
186       <xref linkend="lustrerecovery" />(Version-based Recovery).</para>
187     </note>
188   </section>
189   <section xml:id="dbdoclet.lfsckadmin" condition='l23'>
190     <title>
191     <indexterm>
192       <primary>recovery</primary>
193       <secondary>oiscrub</secondary>
194     </indexterm>
195     <indexterm>
196       <primary>recovery</primary>
197       <secondary>LFSCK</secondary>
198     </indexterm>Checking the file system with LFSCK</title>
199         <para condition='l23'>LFSCK is an administrative tool introduced in Lustre
200     software release 2.3 for checking and repair of the attributes specific to a
201     mounted Lustre file system. It is similar in concept to an offline fsck repair
202     tool for a local filesystem, but LFSCK is implemented to run as part of the
203     Lustre file system while the file system is mounted and in use. This allows
204     consistency of checking and repair by the Lustre software without unnecessary
205     downtime, and can be run on the largest Lustre file systems with negligible
206     disruption to normal operations.</para>
207     <para condition='l23'>Since Lustre software release 2.3, LFSCK can verify
208     and repair the Object Index (OI) table that is used internally to map
209     Lustre File Identifiers (FIDs) to MDT internal ldiskfs inode numbers, in
210     an internal table called the OI Table. An OI Scrub traverses the OI table
211     and makes corrections where necessary. An OI Scrub is required after
212     restoring from a file-level MDT backup (
213     <xref linkend="dbdoclet.backup_device" />), or in case the OI Table is
214     otherwise corrupted. Later phases of LFSCK will add further checks to the
215     Lustre distributed file system state.</para>
216     <para condition='l24'>In Lustre software release 2.4, LFSCK namespace
217     scanning can verify and repair the directory FID-in-dirent and LinkEA
218     consistency.</para>
219     <para condition='l26'>In Lustre software release 2.6, LFSCK layout scanning
220     can verify and repair MDT-OST file layout inconsistencies. File layout
221     inconsistencies between MDT-objects and OST-objects that are checked and
222     corrected include dangling reference, unreferenced OST-objects, mismatched
223     references and multiple references.</para>
224     <para condition='l27'>In Lustre software release 2.7, LFSCK layout scanning
225     is enhanced to support verify and repair inconsistencies between multiple
226     MDTs.</para>
227     <para>Control and monitoring of LFSCK is through LFSCK and the
228     <literal>/proc</literal> file system interfaces. LFSCK supports three types
229     of interface: switch interface, status interface, and adjustment interface.
230     These interfaces are detailed below.</para>
231     <section>
232       <title>LFSCK switch interface</title>
233       <section>
234         <title>Manually Starting LFSCK</title>
235         <section>
236           <title>Description</title>
237           <para>LFSCK can be started after the MDT is mounted using the
238           <literal>lctl lfsck_start</literal> command.</para>
239         </section>
240         <section>
241           <title>Usage</title>
242 <screen>lctl lfsck_start &lt;-M | --device <replaceable>[MDT,OST]_device</replaceable>&gt; \
243                     [-A | --all] \
244                     [-c | --create_ostobj <replaceable>on | off</replaceable>] \
245                     [-C | --create_mdtobj <replaceable>on | off</replaceable>] \
246                     [-d | --delay_create_ostobj <replaceable>on | off</replaceable>] \
247                     [-e | --error <replaceable>{continue | abort}</replaceable>] \
248                     [-h | --help] \
249                     [-n | --dryrun <replaceable>on | off</replaceable>] \
250                     [-o | --orphan] \
251                     [-r | --reset] \
252                     [-s | --speed <replaceable>ops_per_sec_limit</replaceable>] \
253                     [-t | --type <replaceable>check_type[,check_type...]</replaceable>] \
254                     [-w | --window_size <replaceable>size</replaceable>]</screen>
255         </section>
256         <section>
257           <title>Options</title>
258           <para>The various
259           <literal>lfsck_start</literal> options are listed and described below.
260           For a complete list of available options, type
261           <literal>lctl lfsck_start -h</literal>.</para>
262           <informaltable frame="all">
263             <tgroup cols="2">
264               <colspec colname="c1" colwidth="3*" />
265               <colspec colname="c2" colwidth="7*" />
266               <thead>
267                 <row>
268                   <entry>
269                     <para>
270                       <emphasis role="bold">Option</emphasis>
271                     </para>
272                   </entry>
273                   <entry>
274                     <para>
275                       <emphasis role="bold">Description</emphasis>
276                     </para>
277                   </entry>
278                 </row>
279               </thead>
280               <tbody>
281                 <row>
282                   <entry>
283                     <para>
284                       <literal>-M | --device</literal>
285                     </para>
286                   </entry>
287                   <entry>
288                     <para>The MDT or OST target to start LFSCK on.</para>
289                   </entry>
290                 </row>
291                 <row>
292                   <entry>
293                     <para>
294                       <literal>-A | --all</literal>
295                     </para>
296                   </entry>
297                   <entry>
298                     <para condition='l26'>Start LFSCK on all
299                     targets on all servers simultaneously.
300                     By default, both layout and namespace
301                     consistency checking and repair are started.</para>
302                   </entry>
303                 </row>
304                 <row>
305                   <entry>
306                     <para>
307                       <literal>-c | --create_ostobj</literal>
308                     </para>
309                   </entry>
310                   <entry>
311                     <para condition='l26'>Create the lost OST-object for
312                     dangling LOV EA,
313                     <literal>off</literal>(default) or
314                     <literal>on</literal>. If not specified, then the default
315                     behaviour is to keep the dangling LOV EA there without
316                     creating the lost OST-object.</para>
317                   </entry>
318                 </row>
319                 <row>
320                   <entry>
321                     <para>
322                       <literal>-C | --create_mdtobj</literal>
323                     </para>
324                   </entry>
325                   <entry>
326                     <para condition='l27'>Create the lost MDT-object for
327                     dangling name entry,
328                     <literal>off</literal>(default) or
329                     <literal>on</literal>. If not specified, then the default
330                     behaviour is to keep the dangling name entry there without
331                     creating the lost MDT-object.</para>
332                   </entry>
333                 </row>
334                 <row>
335                   <entry>
336                     <para>
337                       <literal>-d | --delay_create_ostobj</literal>
338                     </para>
339                   </entry>
340                   <entry>
341                     <para condition='l29'>
342                       Delay creating the lost OST-object for dangling LOV EA
343                       until the orphan OST-objects are handled.
344                       <literal>off</literal>(default) or
345                       <literal>on</literal>.
346                     </para>
347                   </entry>
348                 </row>
349                 <row>
350                   <entry>
351                     <para>
352                       <literal>-e | --error</literal>
353                     </para>
354                   </entry>
355                   <entry>
356                     <para>Error handle,
357                     <literal>continue</literal>(default) or
358                     <literal>abort</literal>. Specify whether the LFSCK will
359                     stop or not if fails to repair something. If it is not
360                     specified, the saved value (when resuming from checkpoint)
361                     will be used if present. This option cannot be changed
362                     while LFSCK is running.</para>
363                   </entry>
364                 </row>
365                 <row>
366                   <entry>
367                     <para>
368                       <literal>-h | --help</literal>
369                     </para>
370                   </entry>
371                   <entry>
372                     <para>Operating help information.</para>
373                   </entry>
374                 </row>
375                 <row>
376                   <entry>
377                     <para>
378                       <literal>-n | --dryrun</literal>
379                     </para>
380                   </entry>
381                   <entry>
382                     <para>Perform a trial without making any changes.
383                     <literal>off</literal>(default) or
384                     <literal>on</literal>.</para>
385                   </entry>
386                 </row>
387                 <row>
388                   <entry>
389                     <para>
390                       <literal>-o | --orphan</literal>
391                     </para>
392                   </entry>
393                   <entry>
394                     <para condition='l26'>Repair orphan OST-objects for layout
395                     LFSCK.</para>
396                   </entry>
397                 </row>
398                 <row>
399                   <entry>
400                     <para>
401                       <literal>-r | --reset</literal>
402                     </para>
403                   </entry>
404                   <entry>
405                     <para>Reset the start position for the object iteration to
406                     the beginning for the specified MDT. By default the
407                     iterator will resume scanning from the last checkpoint
408                     (saved periodically by LFSCK) provided it is
409                     available.</para>
410                   </entry>
411                 </row>
412                 <row>
413                   <entry>
414                     <para>
415                       <literal>-s | --speed</literal>
416                     </para>
417                   </entry>
418                   <entry>
419                     <para>Set the upper speed limit of LFSCK processing in
420                     objects per second. If it is not specified, the saved value
421                     (when resuming from checkpoint) or default value of 0 (0 =
422                     run as fast as possible) is used. Speed can be adjusted
423                     while LFSCK is running with the adjustment
424                     interface.</para>
425                   </entry>
426                 </row>
427                 <row>
428                   <entry>
429                     <para>
430                       <literal>-t | --type</literal>
431                     </para>
432                   </entry>
433                   <entry>
434                     <para>The type of checking/repairing that should be
435                     performed. The new LFSCK framework provides a single
436                     interface for a variety of system consistency
437                     checking/repairing operations including:</para>
438                     <para>Without a specified option, the LFSCK component(s)
439                     which ran last time and did not finish or the component(s)
440                     corresponding to some known system inconsistency, will be
441                     started. Anytime the LFSCK is triggered, the OI scrub will
442                     run automatically, so there is no need to specify
443                     OI_scrub in that case.</para>
444                     <para condition='l24'>
445                     <literal>namespace</literal>: check and repair
446                     FID-in-dirent and LinkEA consistency.</para>
447                     <para condition='l27'> Lustre-2.7 enhances
448                     namespace consistency verification under DNE mode.</para>
449                     <para condition='l26'>
450                     <literal>layout</literal>: check and repair MDT-OST
451                     inconsistency.</para>
452                   </entry>
453                 </row>
454                 <row>
455                   <entry>
456                     <para>
457                       <literal>-w | --window_size</literal>
458                     </para>
459                   </entry>
460                   <entry>
461                     <para condition='l26'>The window size for the async request
462                     pipeline. The LFSCK async request pipeline's input/output
463                     may have quite different processing speeds, and there may
464                     be too many requests in the pipeline as to cause abnormal
465                     memory/network pressure. If not specified, then the default
466                     window size for the async request pipeline is 1024.</para>
467                   </entry>
468                 </row>
469               </tbody>
470             </tgroup>
471           </informaltable>
472         </section>
473       </section>
474       <section>
475         <title>Manually Stopping LFSCK</title>
476         <section>
477           <title>Description</title>
478           <para>To stop LFSCK when the MDT is mounted, use the
479           <literal>lctl lfsck_stop</literal> command.</para>
480         </section>
481         <section>
482           <title>Usage</title>
483 <screen>lctl lfsck_stop &lt;-M | --device <replaceable>[MDT,OST]_device</replaceable>&gt; \
484                     [-A | --all] \
485                     [-h | --help]</screen>
486         </section>
487         <section>
488           <title>Options</title>
489           <para>The various
490           <literal>lfsck_stop</literal> options are listed and described below.
491           For a complete list of available options, type
492           <literal>lctl lfsck_stop -h</literal>.</para>
493           <informaltable frame="all">
494             <tgroup cols="2">
495               <colspec colname="c1" colwidth="3*" />
496               <colspec colname="c2" colwidth="7*" />
497               <thead>
498                 <row>
499                   <entry>
500                     <para>
501                       <emphasis role="bold">Option</emphasis>
502                     </para>
503                   </entry>
504                   <entry>
505                     <para>
506                       <emphasis role="bold">Description</emphasis>
507                     </para>
508                   </entry>
509                 </row>
510               </thead>
511               <tbody>
512                 <row>
513                   <entry>
514                     <para>
515                       <literal>-M | --device</literal>
516                     </para>
517                   </entry>
518                   <entry>
519                     <para>The MDT or OST target to stop LFSCK on.</para>
520                   </entry>
521                 </row>
522                 <row>
523                   <entry>
524                     <para>
525                       <literal>-A | --all</literal>
526                     </para>
527                   </entry>
528                   <entry>
529                     <para>Stop LFSCK on all targets on all servers
530                     simultaneously.</para>
531                   </entry>
532                 </row>
533                 <row>
534                   <entry>
535                     <para>
536                       <literal>-h | --help</literal>
537                     </para>
538                   </entry>
539                   <entry>
540                     <para>Operating help information.</para>
541                   </entry>
542                 </row>
543               </tbody>
544             </tgroup>
545           </informaltable>
546         </section>
547       </section>
548     </section>
549     <section>
550       <title>Check the LFSCK global status</title>
551       <section>
552         <title>Description</title>
553         <para>Check the LFSCK global status via a single
554         <literal>lctl lfsck_query</literal> command on the MDS.</para>
555       </section>
556       <section>
557         <title>Usage</title>
558 <screen>lctl lfsck_query &lt;-M | --device <replaceable>MDT_device</replaceable>&gt; \
559                     [-h | --help] \
560                     [-t | --type <replaceable>lfsck_type[,lfsck_type...]</replaceable>] \
561                     [-w | --wait]</screen>
562       </section>
563       <section>
564         <title>Options</title>
565         <para>The various
566         <literal>lfsck_query</literal> options are listed and described below.
567         For a complete list of available options, type
568         <literal>lctl lfsck_query -h</literal>.</para>
569         <informaltable frame="all">
570           <tgroup cols="2">
571             <colspec colname="c1" colwidth="3*" />
572             <colspec colname="c2" colwidth="7*" />
573             <thead>
574               <row>
575                 <entry>
576                   <para>
577                     <emphasis role="bold">Option</emphasis>
578                   </para>
579                 </entry>
580                 <entry>
581                   <para>
582                     <emphasis role="bold">Description</emphasis>
583                   </para>
584                 </entry>
585               </row>
586             </thead>
587             <tbody>
588               <row>
589                 <entry>
590                   <para>
591                     <literal>-M | --device</literal>
592                   </para>
593                 </entry>
594                 <entry>
595                   <para>The device to query for LFSCK status.</para>
596                 </entry>
597               </row>
598               <row>
599                 <entry>
600                   <para>
601                     <literal>-h | --help</literal>
602                   </para>
603                 </entry>
604                 <entry>
605                   <para>Operating help information.</para>
606                 </entry>
607               </row>
608               <row>
609                 <entry>
610                   <para>
611                     <literal>-t | --type</literal>
612                   </para>
613                 </entry>
614                 <entry>
615                   <para>The LFSCK type(s) that should be queried,
616                   including: layout, namespace.</para>
617                 </entry>
618               </row>
619               <row>
620                 <entry>
621                   <para>
622                     <literal>-w | --wait</literal>
623                   </para>
624                 </entry>
625                 <entry>
626                   <para>will wait if the LFSCK is in scanning.</para>
627                 </entry>
628               </row>
629             </tbody>
630             </tgroup>
631           </informaltable>
632       </section>
633     </section>
634     <section>
635       <title>LFSCK status interface</title>
636       <section>
637         <title>LFSCK status of OI Scrub via
638         <literal>procfs</literal></title>
639         <section>
640           <title>Description</title>
641           <para>For each LFSCK component there is a dedicated procfs interface
642           to trace the corresponding LFSCK component status. For OI Scrub, the
643           interface is the OSD layer procfs interface, named
644           <literal>oi_scrub</literal>. To display OI Scrub status, the standard
645           <literal>lctl get_param</literal> command is used as shown in the
646           usage below.</para>
647         </section>
648         <section>
649           <title>Usage</title>
650           <screen>lctl get_param -n osd-ldiskfs.<replaceable>FSNAME</replaceable>-[<replaceable>MDT_target|OST_target</replaceable>].oi_scrub</screen>
651         </section>
652         <section>
653           <title>Output</title>
654           <informaltable frame="all">
655             <tgroup cols="2">
656               <colspec colname="c1" colwidth="3*" />
657               <colspec colname="c2" colwidth="7*" />
658               <thead>
659                 <row>
660                   <entry>
661                     <para>
662                       <emphasis role="bold">Information</emphasis>
663                     </para>
664                   </entry>
665                   <entry>
666                     <para>
667                       <emphasis role="bold">Detail</emphasis>
668                     </para>
669                   </entry>
670                 </row>
671               </thead>
672               <tbody>
673                 <row>
674                   <entry>
675                     <para>General Information</para>
676                   </entry>
677                   <entry>
678                     <itemizedlist>
679                       <listitem>
680                         <para>Name: OI_scrub.</para>
681                       </listitem>
682                       <listitem>
683                         <para>OI scrub magic id (an identifier unique to OI
684                         scrub).</para>
685                       </listitem>
686                       <listitem>
687                         <para>OI files count.</para>
688                       </listitem>
689                       <listitem>
690                         <para>Status: one of the status -
691                         <literal>init</literal>,
692                         <literal>scanning</literal>,
693                         <literal>completed</literal>,
694                         <literal>failed</literal>,
695                         <literal>stopped</literal>,
696                         <literal>paused</literal>, or
697                         <literal>crashed</literal>.</para>
698                       </listitem>
699                       <listitem>
700                         <para>Flags: including -
701                         <literal>recreated</literal>(OI file(s) is/are
702                         removed/recreated),
703                         <literal>inconsistent</literal>(restored from
704                         file-level backup),
705                         <literal>auto</literal>(triggered by non-UI mechanism),
706                         and
707                         <literal>upgrade</literal>(from Lustre software release
708                         1.8 IGIF format.)</para>
709                       </listitem>
710                       <listitem>
711                         <para>Parameters: OI scrub parameters, like
712                         <literal>failout</literal>.</para>
713                       </listitem>
714                       <listitem>
715                         <para>Time Since Last Completed.</para>
716                       </listitem>
717                       <listitem>
718                         <para>Time Since Latest Start.</para>
719                       </listitem>
720                       <listitem>
721                         <para>Time Since Last Checkpoint.</para>
722                       </listitem>
723                       <listitem>
724                         <para>Latest Start Position: the position for the
725                         latest scrub started from.</para>
726                       </listitem>
727                       <listitem>
728                         <para>Last Checkpoint Position.</para>
729                       </listitem>
730                       <listitem>
731                         <para>First Failure Position: the position for the
732                         first object to be repaired.</para>
733                       </listitem>
734                       <listitem>
735                         <para>Current Position.</para>
736                       </listitem>
737                     </itemizedlist>
738                   </entry>
739                 </row>
740                 <row>
741                   <entry>
742                     <para>Statistics</para>
743                   </entry>
744                   <entry>
745                     <itemizedlist>
746                       <listitem>
747                         <para>
748                         <literal>Checked</literal> total number of objects
749                         scanned.</para>
750                       </listitem>
751                       <listitem>
752                         <para>
753                         <literal>Updated</literal> total number of objects
754                         repaired.</para>
755                       </listitem>
756                       <listitem>
757                         <para>
758                         <literal>Failed</literal> total number of objects that
759                         failed to be repaired.</para>
760                       </listitem>
761                       <listitem>
762                         <para>
763                         <literal>No Scrub</literal> total number of objects
764                         marked
765                         <literal>LDISKFS_STATE_LUSTRE_NOSCRUB and
766                         skipped</literal>.</para>
767                       </listitem>
768                       <listitem>
769                         <para>
770                         <literal>IGIF</literal> total number of objects IGIF
771                         scanned.</para>
772                       </listitem>
773                       <listitem>
774                         <para>
775                         <literal>Prior Updated</literal> how many objects have
776                         been repaired which are triggered by parallel
777                         RPC.</para>
778                       </listitem>
779                       <listitem>
780                         <para>
781                         <literal>Success Count</literal> total number of
782                         completed OI_scrub runs on the target.</para>
783                       </listitem>
784                       <listitem>
785                         <para>
786                         <literal>Run Time</literal> how long the scrub has run,
787                         tally from the time of scanning from the beginning of
788                         the specified MDT target, not include the
789                         paused/failure time among checkpoints.</para>
790                       </listitem>
791                       <listitem>
792                         <para>
793                         <literal>Average Speed</literal> calculated by dividing
794                         <literal>Checked</literal> by
795                         <literal>run_time</literal>.</para>
796                       </listitem>
797                       <listitem>
798                         <para>
799                         <literal>Real-Time Speed</literal> the speed since last
800                         checkpoint if the OI_scrub is running.</para>
801                       </listitem>
802                       <listitem>
803                         <para>
804                         <literal>Scanned</literal> total number of objects under
805                         /lost+found that have been scanned.</para>
806                       </listitem>
807                       <listitem>
808                         <para>
809                         <literal>Repaired</literal> total number of objects
810                         under /lost+found that have been recovered.</para>
811                       </listitem>
812                       <listitem>
813                         <para>
814                         <literal>Failed</literal> total number of objects under
815                         /lost+found failed to be scanned or failed to be
816                         recovered.</para>
817                       </listitem>
818                     </itemizedlist>
819                   </entry>
820                 </row>
821               </tbody>
822             </tgroup>
823           </informaltable>
824         </section>
825       </section>
826       <section condition='l24'>
827         <title>LFSCK status of namespace via
828         <literal>procfs</literal></title>
829         <section>
830           <title>Description</title>
831           <para>The
832           <literal>namespace</literal> component is responsible for checks
833           described in <xref linkend="dbdoclet.lfsckadmin" />. The
834           <literal>procfs</literal> interface for this component is in the
835           MDD layer, named
836           <literal>lfsck_namespace</literal>. To show the status of this
837           component,
838           <literal>lctl get_param</literal> should be used as described in the
839           usage below.</para>
840           <para>The LFSCK namespace status output refers to phase 1 and phase 2.
841           Phase 1 is when the LFSCK main engine, which runs on each MDT,
842           linearly scans its local device, guaranteeing that all local objects
843           are checked.  However, there are certain cases in which LFSCK cannot
844           know whether an object is consistent or cannot repair an inconsistency
845           until the phase 1 scanning is completed. During phase 2 of the
846           namespace check, objects with multiple hard-links, objects with remote
847           parents, and other objects which couldn't be verified during phase 1
848           will be checked.</para>
849         </section>
850         <section>
851           <title>Usage</title>
852           <screen>lctl get_param -n mdd. <replaceable>FSNAME</replaceable>-<replaceable>MDT_target</replaceable>.lfsck_namespace</screen>
853         </section>
854         <section>
855           <title>Output</title>
856           <informaltable frame="all">
857             <tgroup cols="2">
858               <colspec colname="c1" colwidth="3*" />
859               <colspec colname="c2" colwidth="7*" />
860               <thead>
861                 <row>
862                   <entry>
863                     <para>
864                       <emphasis role="bold">Information</emphasis>
865                     </para>
866                   </entry>
867                   <entry>
868                     <para>
869                       <emphasis role="bold">Detail</emphasis>
870                     </para>
871                   </entry>
872                 </row>
873               </thead>
874               <tbody>
875                 <row>
876                   <entry>
877                     <para>General Information</para>
878                   </entry>
879                   <entry>
880                     <itemizedlist>
881                       <listitem>
882                         <para>Name:
883                         <literal>lfsck_namespace</literal></para>
884                       </listitem>
885                       <listitem>
886                         <para>LFSCK namespace magic.</para>
887                       </listitem>
888                       <listitem>
889                         <para>LFSCK namespace version..</para>
890                       </listitem>
891                       <listitem>
892                         <para>Status: one of the status -
893                         <literal>init</literal>,
894                         <literal>scanning-phase1</literal>,
895                         <literal>scanning-phase2</literal>,
896                         <literal>completed</literal>,
897                         <literal>failed</literal>,
898                         <literal>stopped</literal>,
899                         <literal>paused</literal>,
900                         <literal>partial</literal>,
901                         <literal>co-failed</literal>,
902                         <literal>co-stopped</literal> or
903                         <literal>co-paused</literal>.</para>
904                       </listitem>
905                       <listitem>
906                         <para>Flags: including -
907                         <literal>scanned-once</literal>(the first cycle
908                         scanning has been completed),
909                         <literal>inconsistent</literal>(one or more
910                         inconsistent FID-in-dirent or LinkEA entries that have
911                         been discovered),
912                         <literal>upgrade</literal>(from Lustre software release
913                         1.8 IGIF format.)</para>
914                       </listitem>
915                       <listitem>
916                         <para>Parameters: including
917                         <literal>dryrun</literal>,
918                         <literal>all_targets</literal>,
919                         <literal>failout</literal>,
920                         <literal>broadcast</literal>,
921                         <literal>orphan</literal>,
922                         <literal>create_ostobj</literal> and
923                         <literal>create_mdtobj</literal>.</para>
924                       </listitem>
925                       <listitem>
926                         <para>Time Since Last Completed.</para>
927                       </listitem>
928                       <listitem>
929                         <para>Time Since Latest Start.</para>
930                       </listitem>
931                       <listitem>
932                         <para>Time Since Last Checkpoint.</para>
933                       </listitem>
934                       <listitem>
935                         <para>Latest Start Position: the position the checking
936                         began most recently.</para>
937                       </listitem>
938                       <listitem>
939                         <para>Last Checkpoint Position.</para>
940                       </listitem>
941                       <listitem>
942                         <para>First Failure Position: the position for the
943                         first object to be repaired.</para>
944                       </listitem>
945                       <listitem>
946                         <para>Current Position.</para>
947                       </listitem>
948                     </itemizedlist>
949                   </entry>
950                 </row>
951                 <row>
952                   <entry>
953                     <para>Statistics</para>
954                   </entry>
955                   <entry>
956                     <itemizedlist>
957                       <listitem>
958                         <para>
959                         <literal>Checked Phase1</literal> total number of
960                         objects scanned during
961                         <literal>scanning-phase1</literal>.</para>
962                       </listitem>
963                       <listitem>
964                         <para>
965                         <literal>Checked Phase2</literal> total number of
966                         objects scanned during
967                         <literal>scanning-phase2</literal>.</para>
968                       </listitem>
969                       <listitem>
970                         <para>
971                         <literal>Updated Phase1</literal> total number of
972                         objects repaired during
973                         <literal>scanning-phase1</literal>.</para>
974                       </listitem>
975                       <listitem>
976                         <para>
977                         <literal>Updated Phase2</literal> total number of
978                         objects repaired during
979                         <literal>scanning-phase2</literal>.</para>
980                       </listitem>
981                       <listitem>
982                         <para>
983                         <literal>Failed Phase1</literal> total number of objets
984                         that failed to be repaired during
985                         <literal>scanning-phase1</literal>.</para>
986                       </listitem>
987                       <listitem>
988                         <para>
989                         <literal>Failed Phase2</literal> total number of objets
990                         that failed to be repaired during
991                         <literal>scanning-phase2</literal>.</para>
992                       </listitem>
993                       <listitem>
994                         <para>
995                         <literal>directories</literal> total number of
996                         directories scanned.</para>
997                       </listitem>
998                       <listitem>
999                         <para>
1000                         <literal>multiple_linked_checked</literal> total number
1001                         of multiple-linked objects that have been
1002                         scanned.</para>
1003                       </listitem>
1004                       <listitem>
1005                         <para>
1006                         <literal>dirent_repaired</literal> total number of
1007                         FID-in-dirent entries that have been repaired.</para>
1008                       </listitem>
1009                       <listitem>
1010                         <para>
1011                         <literal>linkea_repaired</literal> total number of
1012                         linkEA entries that have been repaired.</para>
1013                       </listitem>
1014                       <listitem>
1015                         <para>
1016                         <literal>unknown_inconsistency</literal> total number of
1017                         undefined inconsistencies found in
1018                         scanning-phase2.</para>
1019                       </listitem>
1020                       <listitem>
1021                         <para>
1022                         <literal>unmatched_pairs_repaired</literal> total number
1023                         of unmatched pairs that have been repaired.</para>
1024                       </listitem>
1025                       <listitem>
1026                         <para>
1027                         <literal>dangling_repaired</literal> total number of
1028                         dangling name entries that have been
1029                         found/repaired.</para>
1030                       </listitem>
1031                       <listitem>
1032                         <para>
1033                         <literal>multi_referenced_repaired</literal> total
1034                         number of multiple referenced name entries that have
1035                         been found/repaired.</para>
1036                       </listitem>
1037                       <listitem>
1038                         <para>
1039                         <literal>bad_file_type_repaired</literal> total number
1040                         of name entries with bad file type that have been
1041                         repaired.</para>
1042                       </listitem>
1043                       <listitem>
1044                         <para>
1045                         <literal>lost_dirent_repaired</literal> total number of
1046                         lost name entries that have been re-inserted.</para>
1047                       </listitem>
1048                       <listitem>
1049                         <para>
1050                         <literal>striped_dirs_scanned</literal> total number of
1051                         striped directories (master) that have been
1052                         scanned.</para>
1053                       </listitem>
1054                       <listitem>
1055                         <para>
1056                         <literal>striped_dirs_repaired</literal> total number of
1057                         striped directories (master) that have been
1058                         repaired.</para>
1059                       </listitem>
1060                       <listitem>
1061                         <para>
1062                         <literal>striped_dirs_failed</literal> total number of
1063                         striped directories (master) that have failed to be
1064                         verified.</para>
1065                       </listitem>
1066                       <listitem>
1067                         <para>
1068                         <literal>striped_dirs_disabled</literal> total number of
1069                         striped directories (master) that have been
1070                         disabled.</para>
1071                       </listitem>
1072                       <listitem>
1073                         <para>
1074                         <literal>striped_dirs_skipped</literal> total number of
1075                         striped directories (master) that have been skipped
1076                         (for shards verification) because of lost master LMV
1077                         EA.</para>
1078                       </listitem>
1079                       <listitem>
1080                         <para>
1081                         <literal>striped_shards_scanned</literal> total number
1082                         of striped directory shards (slave) that have been
1083                         scanned.</para>
1084                       </listitem>
1085                       <listitem>
1086                         <para>
1087                         <literal>striped_shards_repaired</literal> total number
1088                         of striped directory shards (slave) that have been
1089                         repaired.</para>
1090                       </listitem>
1091                       <listitem>
1092                         <para>
1093                         <literal>striped_shards_failed</literal> total number of
1094                         striped directory shards (slave) that have failed to be
1095                         verified.</para>
1096                       </listitem>
1097                       <listitem>
1098                         <para>
1099                         <literal>striped_shards_skipped</literal> total number
1100                         of striped directory shards (slave) that have been
1101                         skipped (for name hash verification) because LFSCK does
1102                         not know whether the slave LMV EA is valid or
1103                         not.</para>
1104                       </listitem>
1105                       <listitem>
1106                         <para>
1107                         <literal>name_hash_repaired</literal> total number of
1108                         name entries under striped directory with bad name hash
1109                         that have been repaired.</para>
1110                       </listitem>
1111                       <listitem>
1112                         <para>
1113                         <literal>nlinks_repaired</literal> total number of
1114                         objects with nlink fixed.</para>
1115                       </listitem>
1116                       <listitem>
1117                         <para>
1118                         <literal>mul_linked_repaired</literal> total number of
1119                         multiple-linked objects that have been repaired.</para>
1120                       </listitem>
1121                       <listitem>
1122                         <para>
1123                         <literal>local_lost_found_scanned</literal> total number
1124                         of objects under /lost+found that have been
1125                         scanned.</para>
1126                       </listitem>
1127                       <listitem>
1128                         <para>
1129                         <literal>local_lost_found_moved</literal> total number
1130                         of objects under /lost+found that have been moved to
1131                         namespace visible directory.</para>
1132                       </listitem>
1133                       <listitem>
1134                         <para>
1135                         <literal>local_lost_found_skipped</literal> total number
1136                         of objects under /lost+found that have been
1137                         skipped.</para>
1138                       </listitem>
1139                       <listitem>
1140                         <para>
1141                         <literal>local_lost_found_failed</literal> total number
1142                         of objects under /lost+found that have failed to be
1143                         processed.</para>
1144                       </listitem>
1145                       <listitem>
1146                         <para>
1147                         <literal>Success Count</literal> the total number of
1148                         completed LFSCK runs on the target.</para>
1149                       </listitem>
1150                       <listitem>
1151                         <para>
1152                         <literal>Run Time Phase1</literal> the duration of the
1153                         LFSCK run during
1154                         <literal>scanning-phase1</literal>. Excluding the time
1155                         spent paused between checkpoints.</para>
1156                       </listitem>
1157                       <listitem>
1158                         <para>
1159                         <literal>Run Time Phase2</literal> the duration of the
1160                         LFSCK run during
1161                         <literal>scanning-phase2</literal>. Excluding the time
1162                         spent paused between checkpoints.</para>
1163                       </listitem>
1164                       <listitem>
1165                         <para>
1166                         <literal>Average Speed Phase1</literal> calculated by
1167                         dividing
1168                         <literal>checked_phase1</literal> by
1169                         <literal>run_time_phase1</literal>.</para>
1170                       </listitem>
1171                       <listitem>
1172                         <para>
1173                         <literal>Average Speed Phase2</literal> calculated by
1174                         dividing
1175                         <literal>checked_phase2</literal> by
1176                         <literal>run_time_phase1</literal>.</para>
1177                       </listitem>
1178                       <listitem>
1179                         <para>
1180                         <literal>Real-Time Speed Phase1</literal> the speed
1181                         since the last checkpoint if the LFSCK is running
1182                         <literal>scanning-phase1</literal>.</para>
1183                       </listitem>
1184                       <listitem>
1185                         <para>
1186                         <literal>Real-Time Speed Phase2</literal> the speed
1187                         since the last checkpoint if the LFSCK is running
1188                         <literal>scanning-phase2</literal>.</para>
1189                       </listitem>
1190                     </itemizedlist>
1191                   </entry>
1192                 </row>
1193               </tbody>
1194             </tgroup>
1195           </informaltable>
1196         </section>
1197       </section>
1198       <section condition='l26'>
1199         <title>LFSCK status of layout via
1200         <literal>procfs</literal></title>
1201         <section>
1202           <title>Description</title>
1203           <para>The
1204           <literal>layout</literal> component is responsible for checking and
1205           repairing MDT-OST inconsistency. The
1206           <literal>procfs</literal> interface for this component is in the MDD
1207           layer, named
1208           <literal>lfsck_layout</literal>, and in the OBD layer, named
1209           <literal>lfsck_layout</literal>. To show the status of this component
1210           <literal>lctl get_param</literal> should be used as described in the
1211           usage below.</para>
1212           <para>The LFSCK layout status output refers to phase 1 and phase 2.
1213           Phase 1 is when the LFSCK main engine, which runs on each MDT/OST,
1214           linearly scans its local device, guaranteeing that all local objects
1215           are checked. During phase 1 of layout LFSCK, the OST-objects which are
1216           not referenced by any MDT-object are recorded in a bitmap. During
1217           phase 2 of the layout check, the OST-objects in the bitmap will be
1218           re-scanned to check whether they are really orphan objects.</para>
1219         </section>
1220         <section>
1221           <title>Usage</title>
1222           <screen>lctl get_param -n mdd.
1223 <replaceable>FSNAME</replaceable>-
1224 <replaceable>MDT_target</replaceable>.lfsck_layout
1225 lctl get_param -n obdfilter.
1226 <replaceable>FSNAME</replaceable>-
1227 <replaceable>OST_target</replaceable>.lfsck_layout</screen>
1228         </section>
1229         <section>
1230           <title>Output</title>
1231           <informaltable frame="all">
1232             <tgroup cols="2">
1233               <colspec colname="c1" colwidth="3*" />
1234               <colspec colname="c2" colwidth="7*" />
1235               <thead>
1236                 <row>
1237                   <entry>
1238                     <para>
1239                       <emphasis role="bold">Information</emphasis>
1240                     </para>
1241                   </entry>
1242                   <entry>
1243                     <para>
1244                       <emphasis role="bold">Detail</emphasis>
1245                     </para>
1246                   </entry>
1247                 </row>
1248               </thead>
1249               <tbody>
1250                 <row>
1251                   <entry>
1252                     <para>General Information</para>
1253                   </entry>
1254                   <entry>
1255                     <itemizedlist>
1256                       <listitem>
1257                         <para>Name:
1258                         <literal>lfsck_layout</literal></para>
1259                       </listitem>
1260                       <listitem>
1261                         <para>LFSCK namespace magic.</para>
1262                       </listitem>
1263                       <listitem>
1264                         <para>LFSCK namespace version..</para>
1265                       </listitem>
1266                       <listitem>
1267                         <para>Status: one of the status -
1268                         <literal>init</literal>,
1269                         <literal>scanning-phase1</literal>,
1270                         <literal>scanning-phase2</literal>,
1271                         <literal>completed</literal>,
1272                         <literal>failed</literal>,
1273                         <literal>stopped</literal>,
1274                         <literal>paused</literal>,
1275                         <literal>crashed</literal>,
1276                         <literal>partial</literal>,
1277                         <literal>co-failed</literal>,
1278                         <literal>co-stopped</literal>, or
1279                         <literal>co-paused</literal>.</para>
1280                       </listitem>
1281                       <listitem>
1282                         <para>Flags: including -
1283                         <literal>scanned-once</literal>(the first cycle
1284                         scanning has been completed),
1285                         <literal>inconsistent</literal>(one or more MDT-OST
1286                         inconsistencies have been discovered),
1287                         <literal>incomplete</literal>(some MDT or OST did not
1288                         participate in the LFSCK or failed to finish the LFSCK)
1289                         or
1290                         <literal>crashed_lastid</literal>(the lastid files on
1291                         the OST crashed and needs to be rebuilt).</para>
1292                       </listitem>
1293                       <listitem>
1294                         <para>Parameters: including
1295                         <literal>dryrun</literal>,
1296                         <literal>all_targets</literal> and
1297                         <literal>failout</literal>.</para>
1298                       </listitem>
1299                       <listitem>
1300                         <para>Time Since Last Completed.</para>
1301                       </listitem>
1302                       <listitem>
1303                         <para>Time Since Latest Start.</para>
1304                       </listitem>
1305                       <listitem>
1306                         <para>Time Since Last Checkpoint.</para>
1307                       </listitem>
1308                       <listitem>
1309                         <para>Latest Start Position: the position the checking
1310                         began most recently.</para>
1311                       </listitem>
1312                       <listitem>
1313                         <para>Last Checkpoint Position.</para>
1314                       </listitem>
1315                       <listitem>
1316                         <para>First Failure Position: the position for the
1317                         first object to be repaired.</para>
1318                       </listitem>
1319                       <listitem>
1320                         <para>Current Position.</para>
1321                       </listitem>
1322                     </itemizedlist>
1323                   </entry>
1324                 </row>
1325                 <row>
1326                   <entry>
1327                     <para>Statistics</para>
1328                   </entry>
1329                   <entry>
1330                     <itemizedlist>
1331                       <listitem>
1332                         <para>
1333                         <literal>Success Count:</literal> the total number of
1334                         completed LFSCK runs on the target.</para>
1335                       </listitem>
1336                       <listitem>
1337                         <para>
1338                         <literal>Repaired Dangling:</literal> total number of
1339                         MDT-objects with dangling reference have been repaired
1340                         in the scanning-phase1.</para>
1341                       </listitem>
1342                       <listitem>
1343                         <para>
1344                         <literal>Repaired Unmatched Pairs</literal> total number
1345                         of unmatched MDT and OST-object pairs have been
1346                         repaired in the scanning-phase1</para>
1347                       </listitem>
1348                       <listitem>
1349                         <para>
1350                         <literal>Repaired Multiple Referenced</literal> total
1351                         number of OST-objects with multiple reference have been
1352                         repaired in the scanning-phase1.</para>
1353                       </listitem>
1354                       <listitem>
1355                         <para>
1356                         <literal>Repaired Orphan</literal> total number of
1357                         orphan OST-objects have been repaired in the
1358                         scanning-phase2.</para>
1359                       </listitem>
1360                       <listitem>
1361                         <para>
1362                         <literal>Repaired Inconsistent Owner</literal> total
1363                         number.of OST-objects with incorrect owner information
1364                         have been repaired in the scanning-phase1.</para>
1365                       </listitem>
1366                       <listitem>
1367                         <para>
1368                         <literal>Repaired Others</literal> total number of.other
1369                         inconsistency repaired in the scanning phases.</para>
1370                       </listitem>
1371                       <listitem>
1372                         <para>
1373                         <literal>Skipped</literal> Number of skipped
1374                         objects.</para>
1375                       </listitem>
1376                       <listitem>
1377                         <para>
1378                         <literal>Failed Phase1</literal> total number of objects
1379                         that failed to be repaired during
1380                         <literal>scanning-phase1</literal>.</para>
1381                       </listitem>
1382                       <listitem>
1383                         <para>
1384                         <literal>Failed Phase2</literal> total number of objects
1385                         that failed to be repaired during
1386                         <literal>scanning-phase2</literal>.</para>
1387                       </listitem>
1388                       <listitem>
1389                         <para>
1390                         <literal>Checked Phase1</literal> total number of
1391                         objects scanned during
1392                         <literal>scanning-phase1</literal>.</para>
1393                       </listitem>
1394                       <listitem>
1395                         <para>
1396                         <literal>Checked Phase2</literal> total number of
1397                         objects scanned during
1398                         <literal>scanning-phase2</literal>.</para>
1399                       </listitem>
1400                       <listitem>
1401                         <para>
1402                         <literal>Run Time Phase1</literal> the duration of the
1403                         LFSCK run during
1404                         <literal>scanning-phase1</literal>. Excluding the time
1405                         spent paused between checkpoints.</para>
1406                       </listitem>
1407                       <listitem>
1408                         <para>
1409                         <literal>Run Time Phase2</literal> the duration of the
1410                         LFSCK run during
1411                         <literal>scanning-phase2</literal>. Excluding the time
1412                         spent paused between checkpoints.</para>
1413                       </listitem>
1414                       <listitem>
1415                         <para>
1416                         <literal>Average Speed Phase1</literal> calculated by
1417                         dividing
1418                         <literal>checked_phase1</literal> by
1419                         <literal>run_time_phase1</literal>.</para>
1420                       </listitem>
1421                       <listitem>
1422                         <para>
1423                         <literal>Average Speed Phase2</literal> calculated by
1424                         dividing
1425                         <literal>checked_phase2</literal> by
1426                         <literal>run_time_phase1</literal>.</para>
1427                       </listitem>
1428                       <listitem>
1429                         <para>
1430                         <literal>Real-Time Speed Phase1</literal> the speed
1431                         since the last checkpoint if the LFSCK is running
1432                         <literal>scanning-phase1</literal>.</para>
1433                       </listitem>
1434                       <listitem>
1435                         <para>
1436                         <literal>Real-Time Speed Phase2</literal> the speed
1437                         since the last checkpoint if the LFSCK is running
1438                         <literal>scanning-phase2</literal>.</para>
1439                       </listitem>
1440                     </itemizedlist>
1441                   </entry>
1442                 </row>
1443               </tbody>
1444             </tgroup>
1445           </informaltable>
1446         </section>
1447       </section>
1448     </section>
1449     <section>
1450       <title>LFSCK adjustment interface</title>
1451       <section condition='l26'>
1452         <title>Rate control</title>
1453         <section>
1454           <title>Description</title>
1455           <para>The LFSCK upper speed limit can be changed using
1456           <literal>lctl set_param</literal> as shown in the usage below.</para>
1457         </section>
1458         <section>
1459           <title>Usage</title>
1460           <screen>lctl set_param mdd.${FSNAME}-${MDT_target}.lfsck_speed_limit=
1461 <replaceable>N</replaceable>
1462 lctl set_param obdfilter.${FSNAME}-${OST_target}.lfsck_speed_limit=
1463 <replaceable>N</replaceable></screen>
1464         </section>
1465         <section>
1466           <title>Values</title>
1467           <informaltable frame="all">
1468             <tgroup cols="2">
1469               <colspec colname="c1" colwidth="3*" />
1470               <colspec colname="c2" colwidth="7*" />
1471               <tbody>
1472                 <row>
1473                   <entry>
1474                     <para>0</para>
1475                   </entry>
1476                   <entry>
1477                     <para>No speed limit (run at maximum speed.)</para>
1478                   </entry>
1479                 </row>
1480                 <row>
1481                   <entry>
1482                     <para>positive integer</para>
1483                   </entry>
1484                   <entry>
1485                     <para>Maximum number of objects to scan per second.</para>
1486                   </entry>
1487                 </row>
1488               </tbody>
1489             </tgroup>
1490           </informaltable>
1491         </section>
1492       </section>
1493       <section xml:id="dbdoclet.lfsck_auto_scrub">
1494         <title>Auto scrub</title>
1495         <section>
1496           <title>Description</title>
1497           <para>The
1498           <literal>auto_scrub</literal> parameter controls whether OI scrub will
1499           be triggered when an inconsistency is detected during OI lookup. It
1500           can be set as described in the usage and values sections
1501           below.</para>
1502           <para>There is also a
1503           <literal>noscrub</literal> mount option (see
1504           <xref linkend="dbdoclet.50438219_12635" />) which can be used to
1505           disable automatic OI scrub upon detection of a file-level backup at
1506           mount time. If the
1507           <literal>noscrub</literal> mount option is specified,
1508           <literal>auto_scrub</literal> will also be disabled, so OI scrub will
1509           not be triggered when an OI inconsistency is detected. Auto scrub can
1510           be renabled after the mount using the command shown in the usage.
1511           Manually starting LFSCK after mounting provides finer control over
1512           the starting conditions.</para>
1513         </section>
1514         <section>
1515           <title>Usage</title>
1516           <screen>lctl set_param osd_ldiskfs.${FSNAME}-${MDT_target}.auto_scrub=<replaceable>N</replaceable></screen>
1517           <para>where
1518           <replaceable>N</replaceable>is an integer as described below.</para>
1519           <note condition='l25'><para>Lustre software 2.5 and later supports
1520           <literal>-P</literal> option that makes the
1521           <literal>set_param</literal> permanent.</para></note>
1522         </section>
1523         <section>
1524           <title>Values</title>
1525           <informaltable frame="all">
1526             <tgroup cols="2">
1527               <colspec colname="c1" colwidth="3*" />
1528               <colspec colname="c2" colwidth="7*" />
1529               <tbody>
1530                 <row>
1531                   <entry>
1532                     <para>0</para>
1533                   </entry>
1534                   <entry>
1535                     <para>Do not start OI Scrub automatically.</para>
1536                   </entry>
1537                 </row>
1538                 <row>
1539                   <entry>
1540                     <para>positive integer</para>
1541                   </entry>
1542                   <entry>
1543                     <para>Automatically start OI Scrub if inconsistency is
1544                     detected during OI lookup.</para>
1545                   </entry>
1546                 </row>
1547               </tbody>
1548             </tgroup>
1549           </informaltable>
1550         </section>
1551       </section>
1552     </section>
1553   </section>
1554 </chapter>