Whamcloud - gitweb
LU-15833 llapi: don't use realpath in llapi_search_fsname()
[fs/lustre-release.git] / lustre / doc / llverdev.8
1 .\" -*- nroff -*-
2 .\" Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
3 .\" This file may be copied under the terms of the GNU Public License, v2.
4 .\"
5 .TH llverdev 8 "2008 Mar 15" Lustre "configuration utilities"
6 .SH NAME
7 llverdev - verify a block device is functioning properly over its full size
8 .SH SYNOPSIS
9 .BI llverdev
10 .RB [ -c
11 .IR chunksize ]
12 .RB [ -f "] [" -h ]
13 .RB [ -o
14 .IR offset_kb ]
15 .RB [ -l "] [" -p "] [" -r ]
16 .RB [ -s
17 .IR size_mb ]
18 .RB [ -t
19 .IR timestamp ]
20 .RB [ -v "] [" -w ]
21 .I device
22 .SH DESCRIPTION
23 Sometimes kernel drivers or hardware devices have bugs that prevent them from
24 accessing the full device size correctly, or possibly have bad sectors on disk
25 or other problems which prevent proper data storage.  There are often defects
26 associated with major system boundaries such as 2^32 bytes, 2^31 sectors,
27 2^31 blocks, 2^32 blocks, etc.
28 .PP
29 The
30 .B llverdev
31 tool will write and verify a unique test pattern across the entire device in
32 order to ensure that not only is data accessible after it was written, but
33 also that data written to one part of the disk is not overwriting data on
34 another part of the disk.
35 .PP
36 It is expected that llverdev tool will be run on large size devices (TB), 
37 so it is always better to run llverdev tool in verbose mode, so that one
38 can easily restart device testing from the point at which it had stopped. 
39 .PP
40 Running a full verification can be time consuming for very large devices,
41 so it is advisable to start with a partial verification to ensure the
42 device is minimally sane before investing the time in a full verification.
43 .SH OPTIONS
44 .TP
45 .BR -c | --chunksize " \fIchunk_mb"
46 IO chunk size in megabytes (default=1), with optional KMG suffix.
47 .TP
48 .BR -f | --force
49 force test to run without confirmation that the device will be overwritten
50 and all data therein will be permanently destroyed.
51 .TP
52 .BR -h | --help
53 display a brief help message.
54 .TP
55 .BR -l | --long
56 Run a full check, writing and then reading and verifying every block on the
57 disk.
58 .TP
59 .BR -o | --offset " \fIoffset_kb"
60 offset of IO start in kilobytes (default=0), with optional KMGTP suffix.
61 .TP
62 .BR -p | --partial
63 Run a partial check, only doing periodic checks across the device (1GB steps).
64 .TP
65 .BR -r | --read
66 Run test in read (verify) mode only, after having run the test in
67 .B -w
68 mode previously.
69 .TP
70 .BR -s | --size " \fIsize_mb"
71 device or file size in megabytes to use for the test, with optional KMGTP
72 suffix.  If unspecified, use the actual device or file size (or write until
73 an error is hit if 0).
74 .TP
75 .BR -t | --timestamp " \fItimestamp"
76 Set test start time as printed at the start of a previously interrupted test
77 to ensure that the validation data is the same across the whole filesystem
78 (default=current time())
79 .TP
80 .BR -v | --verbose
81 Run test in verbose mode, listing each read and write operation.
82 .TP
83 .BR -w | --write
84 Run test in write (test-pattern) mode (default run both read and write)
85 .SH EXAMPLES
86 .TP
87 Run a partial device verification on \fB/dev/sda\fR:
88 .B llverdev -v -p /dev/sda
89 .br
90 llverdev: permanently overwrite all data on /dev/sda (yes/no)? y
91 .br
92 llverdev: /dev/sda is 4398046511104 bytes (4096.0 GB) in size
93 .br
94 Timestamp: 1009839028
95 .br
96 Current write offset:        4096 kB
97 .TP
98 Continue an interrupted verification at offset \fB4096\fRkB from the start of the device, using the same timestamp as the previous run:
99 .B llverdev -f -v -p --offset=4096 --timestamp=1009839028 /dev/sda
100 .br
101 llverdev: /dev/sda is 4398046511104 bytes (4096.0 GB) in size
102 .br
103 Timestamp: 1009839028
104 .br
105 write complete
106 .br
107 read complete
108 .SH SEE ALSO
109 .BR llverfs (8)