Whamcloud - gitweb
Updated the lctl manpage and Lustre How-To.
[fs/lustre-release.git] / lustre / doc / lctl.lyx
1 #LyX 1.2 created this file. For more info see http://www.lyx.org/
2 \lyxformat 220
3 \textclass amsart-plain
4 \language english
5 \inputencoding auto
6 \fontscheme times
7 \graphics default
8 \paperfontsize default
9 \spacing single 
10 \papersize letterpaper
11 \paperpackage a4
12 \use_geometry 0
13 \use_amsmath 0
14 \use_natbib 0
15 \use_numerical_citations 0
16 \paperorientation portrait
17 \secnumdepth 3
18 \tocdepth 3
19 \paragraph_separation skip
20 \defskip medskip
21 \quotes_language english
22 \quotes_times 2
23 \papercolumns 1
24 \papersides 1
25 \paperpagestyle default
26
27 \layout Section
28
29 LCTL
30 \layout Subsection
31
32 NAME 
33 \layout Standard
34
35 lctl - low level Lustre file system configuration utility
36 \layout Subsection
37
38 SYNOPSIS
39 \layout Standard
40
41
42 \series bold 
43 lctl 
44 \layout Standard
45
46
47 \series bold 
48 lctl\SpecialChar ~
49 --device\SpecialChar ~
50 <devno> <command\SpecialChar ~
51 [args]>
52 \layout Standard
53
54
55 \series bold 
56 lctl\SpecialChar ~
57 --threads\SpecialChar ~
58 <numthreads>\SpecialChar ~
59 <verbose>\SpecialChar ~
60 <devno>\SpecialChar ~
61 <command [args]>
62 \layout Subsection
63
64 DESCRIPTION
65 \layout Standard
66
67 The program can be invoked in interactive mode by issuing 
68 \series bold 
69 lctl.
70
71 \series default 
72  After that commands are issued as below.
73  The most common commands in lctl are (in matching pairs) 
74 \family typewriter 
75 device
76 \family default 
77
78 \family typewriter 
79 attach
80 \family default 
81  and 
82 \family typewriter 
83 detach
84 \family default 
85
86 \family typewriter 
87 setup
88 \family default 
89  and 
90 \family typewriter 
91 cleanup
92 \family default 
93
94 \family typewriter 
95 connect
96 \family default 
97  and 
98 \family typewriter 
99 disconnect
100 \family default 
101
102 \family typewriter 
103 help
104 \family default 
105 , and 
106 \family typewriter 
107 quit
108 \family default 
109 .
110   To get a complete listing of available commands, type 
111 \family typewriter 
112 help
113 \family default 
114  at the lctl prompt.
115   To get basic help on the meaning and syntax of a command, type 
116 \family typewriter 
117 help command
118 \family default 
119 .
120   Command completion is activated with the 
121 \family typewriter 
122 TAB
123 \family default 
124  key, and command history is available via the up- and down-arrow keys.
125  
126 \layout Standard
127
128 For non-interactive single threaded use, one uses the second invocation
129  which runs 
130 \emph on 
131 command
132 \emph default 
133  after connecting to the 
134 \emph on 
135 device.
136
137 \emph default 
138  
139 \layout Description
140
141 --device The device number to be used for the operation.
142  The value of devno is an integer, normally found by calling 
143 \emph on 
144 lctl name2dev 
145 \emph default 
146 on a device name.
147  
148 \layout Description
149
150 --threads How many threads should be forked doing the command specified.
151  The numthreads variable is a strictly positivie integer indicating how
152  many threads should be started.
153  Verbose can take values <XXXX>, 
154 \emph on 
155 devno 
156 \emph default 
157 is used as above.
158 \layout LyX-Code
159
160 \layout LyX-Code
161
162 \layout Description
163
164 network\SpecialChar ~
165 config
166 \begin_deeper 
167 \layout Description
168
169 network\SpecialChar ~
170 <tcp/elans/myrinet> Indicate what kind of network applies for the
171  configuration commands that follow
172 \layout Description
173
174 connect\SpecialChar ~
175 [[<hostname>\SpecialChar ~
176 <port>]\SpecialChar ~
177 |\SpecialChar ~
178 <elan\SpecialChar ~
179 id>] This will establish a connection to
180  a remote network network id given by the hostname/port combination or the
181  elan id 
182 \layout Description
183
184 disconnect\SpecialChar ~
185 <nid> Disconnect from a remote nid
186 \layout Description
187
188 mynid\SpecialChar ~
189 [nid] Informs the socknal of the local nid.
190  It defaults to hostname for tcp networks and is automatically setup for
191  elan/myrinet networks 
192 \layout Description
193
194 add_uuid\SpecialChar ~
195 <uuid>\SpecialChar ~
196 <nid> Associate a given UUID with an 
197 \emph on 
198 nid
199 \emph default 
200  
201 \layout Description
202
203 close_uuid\SpecialChar ~
204 <uuid> Disconnect a UUID 
205 \layout Description
206
207 del_uuid\SpecialChar ~
208 <uuid> Delete a UUID association
209 \layout Description
210
211 add_route\SpecialChar ~
212 <gateway>\SpecialChar ~
213 <target>\SpecialChar ~
214 [target] Add an entry to the routing table for
215  the given target 
216 \layout Description
217
218 del_route\SpecialChar ~
219 <target> Delete an entry for the target from the routing table
220 \layout Description
221
222 route_list Print the complete routing table 
223 \layout Description
224
225 recv_mem\SpecialChar ~
226 [size] Set the socket receive buffer size, if the size is omited
227  the default size for the buffer is printed
228 \layout Description
229
230 send_mem\SpecialChar ~
231 [size] Set send buffer size for the socket, if size is omited the
232  default size for the buffer is printed
233 \layout Description
234
235 nagle\SpecialChar ~
236 [on/off] Enable/disable nagle, omiting the arguement will cause the
237  default value to be printed
238 \end_deeper 
239 \layout Description
240
241 device\SpecialChar ~
242 selection
243 \begin_deeper 
244 \layout Description
245
246 newdev Create a new device
247 \layout Description
248
249 name2dev This command can be used to determine a device number for the given
250  device name.
251 \layout Description
252
253 device This will select the specified OBD device.
254   All other commands depend on the device being set.
255  
256 \layout Description
257
258 device_list Show all the devices
259 \end_deeper 
260 \layout Description
261
262 device\SpecialChar ~
263 config
264 \begin_deeper 
265 \layout Description
266
267 attach\SpecialChar ~
268 type\SpecialChar ~
269 [name\SpecialChar ~
270 [uuid]] 
271 \shape italic 
272 Attach
273 \shape default 
274  a type to the current device (which you need to set using the 
275 \family typewriter 
276 device
277 \family default 
278  command) and give that device a name and UUID.
279   This allows us to identify the device for use later, and also tells us
280  what type of device we will have.
281 \layout Description
282
283 setup\SpecialChar ~
284 <args...> Type specific device setup commands.
285  For obdfilter a setup command tells the driver which block device it should
286  use for storage and what type of filesystem is on that device.
287  
288 \layout Description
289
290 cleanup Cleanup a previously setup device
291 \layout Description
292
293 detach Remove driver (and name and uuid) from the current device
294 \layout Description
295
296 lovconfig\SpecialChar ~
297 lov-uuid\SpecialChar ~
298 stripe-count\SpecialChar ~
299 stripe-size\SpecialChar ~
300 offset\SpecialChar ~
301 pattern\SpecialChar ~
302 UUID1\SpecialChar ~
303 [UUID2...] Write
304  LOV configuration to an MDS device
305 \end_deeper 
306 \layout Description
307
308 device\SpecialChar ~
309 operations
310 \begin_deeper 
311 \layout Description
312
313 probe\SpecialChar ~
314 [timeout] Build a connection handle to a device.
315  This command is used to suspend configuration till the lctl command has
316  ensured that the mds and osc services are available.
317  This is to avoid mount failures in a reebooting cluster
318 \layout Description
319
320 close 
321 \layout Description
322
323 getattr\SpecialChar ~
324 <objid> Get attributes for an OST object <objid> 
325 \layout Description
326
327 setattr\SpecialChar ~
328 <objid>\SpecialChar ~
329 <mode> Set mode attribute for OST object <objid>
330 \layout Description
331
332 create\SpecialChar ~
333 [num\SpecialChar ~
334 [mode\SpecialChar ~
335 [verbose]]] Create the specified number <num> of OST objects
336  with the given <mode>
337 \layout Description
338
339 destroy\SpecialChar ~
340 <objid> Destroy an OST object
341 \layout Description
342
343 test_getattr\SpecialChar ~
344 <num>\SpecialChar ~
345 [verbose\SpecialChar ~
346 [[t]objid]] Do <num> getattrs on OST object <objid>
347  (objectid+1 on each thread)
348 \layout Description
349
350 test_brw\SpecialChar ~
351 [t]<num>\SpecialChar ~
352 [write\SpecialChar ~
353 [verbose\SpecialChar ~
354 [npages\SpecialChar ~
355 [[t]objid]]]] Do <num> bulk read/writes
356  on OST object <objid> (<npages> per I/O)
357 \layout Description
358
359 test_ldlm Perform lock manager test
360 \layout Description
361
362 ldlm_regress_start\SpecialChar ~
363 %s\SpecialChar ~
364 [numthreads\SpecialChar ~
365 [refheld\SpecialChar ~
366 [numres\SpecialChar ~
367 [numext]]]] Start lock manager
368  stress test
369 \layout Description
370
371 ldlm_regress_stop Stop lock manager stress test
372 \layout Description
373
374 dump_ldlm Dump all lock manager state, this is very useful for debugging
375 \layout Description
376
377 newconn\SpecialChar ~
378 <olduuid>\SpecialChar ~
379 [newuuid]
380 \end_deeper 
381 \layout Description
382
383 debug
384 \begin_deeper 
385 \layout Description
386
387 debug_kernel\SpecialChar ~
388 [file]\SpecialChar ~
389 [raw] Get debug buffer and dump to a fileusage
390 \layout Description
391
392 debug_file\SpecialChar ~
393 <input>\SpecialChar ~
394 [output]\SpecialChar ~
395 [raw] Read debug buffer from input and dump to
396  outputusage
397 \layout Description
398
399 clear Clear kernel debug buffer 
400 \layout Description
401
402 mark\SpecialChar ~
403 <text> Insert marker text in kernel debug buffer 
404 \layout Description
405
406 filter\SpecialChar ~
407 <subsystem\SpecialChar ~
408 id/debug\SpecialChar ~
409 mask> Filter message type from the kernel debug
410  buffer
411 \layout Description
412
413 show\SpecialChar ~
414 <subsystem\SpecialChar ~
415 id/debug\SpecialChar ~
416 mask> Show specific type of messages 
417 \layout Description
418
419 debug_list\SpecialChar ~
420 <subs/types> List all the subsystem and debug types
421 \layout Description
422
423 panic Force the kernel to panic
424 \end_deeper 
425 \layout Description
426
427 control
428 \begin_deeper 
429 \layout Description
430
431 help Show a complete list of commands, help <command name> can be used to
432  get help on specific command
433 \layout Description
434
435 exit Close the lctl session
436 \layout Description
437
438 quit Close the lctl session
439 \end_deeper 
440 \layout Subsection
441
442 EXAMPLES
443 \layout Description
444
445 attach
446 \layout LyX-Code
447
448 # lctl
449 \newline 
450 lctl > newdev
451 \newline 
452 lctl > attach obdfilter OBDDEV OBDUUID 
453 \layout Description
454
455 connect
456 \layout LyX-Code
457
458 lctl > name2dev OSCDEV
459 \newline 
460
461 \newline 
462 lctl > device 2
463 \newline 
464 lctl > connect
465 \newline 
466
467 \layout Description
468
469 getattr
470 \layout LyX-Code
471
472 lctl > getattr 12
473 \newline 
474 id: 12
475 \newline 
476 grp: 0
477 \newline 
478 atime: 1002663714
479 \newline 
480 mtime: 1002663535
481 \newline 
482 ctime: 1002663535
483 \newline 
484 size: 10
485 \newline 
486 blocks: 8
487 \newline 
488 blksize: 4096
489 \newline 
490 mode: 100644
491 \newline 
492 uid: 0
493 \newline 
494 gid: 0
495 \newline 
496 flags: 0
497 \newline 
498 obdflags: 0
499 \newline 
500 nlink: 1
501 \newline 
502 valid: ffffffff
503 \newline 
504 inline:
505 \newline 
506 obdmd:
507 \newline 
508 lctl > disconnect 
509 \newline 
510 Finished (success)
511 \layout Description
512
513 setup 
514 \layout LyX-Code
515
516 lctl > setup /dev/loop0 extN
517 \newline 
518 lctl > quit 
519 \layout LyX-Code
520
521 \layout Subsection
522
523 BUGS
524 \layout Standard
525
526 None are known.
527 \layout Subsection
528
529 AUTHOR
530 \layout Standard
531
532 Cluster File Systems, Inc.
533  2002 - created
534 \the_end