Whamcloud - gitweb
Add lov_getconfig to lctl docs.
[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 lov_setconfig\SpecialChar ~
297 lov-uuid\SpecialChar ~
298 default-stripe-count\SpecialChar ~
299 default-stripe-size\SpecialChar ~
300 offset\SpecialChar ~
301 pattern\SpecialChar ~
302 UUID1\SpecialChar ~
303 [U
304 UID2...] Write LOV configuration to an MDS device
305 \layout Description
306
307 lov_getconfig\SpecialChar ~
308 lov-uuid Read LOV configuration from an MDS device.
309  Returns default-stripe-count, default-stripe-size, offset, pattern, and
310  a list of OST UUIDs.
311 \end_deeper 
312 \layout Description
313
314 device\SpecialChar ~
315 operations
316 \begin_deeper 
317 \layout Description
318
319 probe\SpecialChar ~
320 [timeout] Build a connection handle to a device.
321  This command is used to suspend configuration till the lctl command has
322  ensured that the mds and osc services are available.
323  This is to avoid mount failures in a reebooting cluster
324 \layout Description
325
326 close 
327 \layout Description
328
329 getattr\SpecialChar ~
330 <objid> Get attributes for an OST object <objid> 
331 \layout Description
332
333 setattr\SpecialChar ~
334 <objid>\SpecialChar ~
335 <mode> Set mode attribute for OST object <objid>
336 \layout Description
337
338 create\SpecialChar ~
339 [num\SpecialChar ~
340 [mode\SpecialChar ~
341 [verbose]]] Create the specified number <num> of OST objects
342  with the given <mode>
343 \layout Description
344
345 destroy\SpecialChar ~
346 <objid> Destroy an OST object
347 \layout Description
348
349 test_getattr\SpecialChar ~
350 <num>\SpecialChar ~
351 [verbose\SpecialChar ~
352 [[t]objid]] Do <num> getattrs on OST object <objid>
353  (objectid+1 on each thread)
354 \layout Description
355
356 test_brw\SpecialChar ~
357 [t]<num>\SpecialChar ~
358 [write\SpecialChar ~
359 [verbose\SpecialChar ~
360 [npages\SpecialChar ~
361 [[t]objid]]]] Do <num> bulk read/writes
362  on OST object <objid> (<npages> per I/O)
363 \layout Description
364
365 test_ldlm Perform lock manager test
366 \layout Description
367
368 ldlm_regress_start\SpecialChar ~
369 %s\SpecialChar ~
370 [numthreads\SpecialChar ~
371 [refheld\SpecialChar ~
372 [numres\SpecialChar ~
373 [numext]]]] Start lock manager
374  stress test
375 \layout Description
376
377 ldlm_regress_stop Stop lock manager stress test
378 \layout Description
379
380 dump_ldlm Dump all lock manager state, this is very useful for debugging
381 \layout Description
382
383 newconn\SpecialChar ~
384 <olduuid>\SpecialChar ~
385 [newuuid]
386 \end_deeper 
387 \layout Description
388
389 debug
390 \begin_deeper 
391 \layout Description
392
393 debug_kernel\SpecialChar ~
394 [file]\SpecialChar ~
395 [raw] Get debug buffer and dump to a fileusage
396 \layout Description
397
398 debug_file\SpecialChar ~
399 <input>\SpecialChar ~
400 [output]\SpecialChar ~
401 [raw] Read debug buffer from input and dump to
402  outputusage
403 \layout Description
404
405 clear Clear kernel debug buffer 
406 \layout Description
407
408 mark\SpecialChar ~
409 <text> Insert marker text in kernel debug buffer 
410 \layout Description
411
412 filter\SpecialChar ~
413 <subsystem\SpecialChar ~
414 id/debug\SpecialChar ~
415 mask> Filter message type from the kernel debug
416  buffer
417 \layout Description
418
419 show\SpecialChar ~
420 <subsystem\SpecialChar ~
421 id/debug\SpecialChar ~
422 mask> Show specific type of messages 
423 \layout Description
424
425 debug_list\SpecialChar ~
426 <subs/types> List all the subsystem and debug types
427 \layout Description
428
429 panic Force the kernel to panic
430 \end_deeper 
431 \layout Description
432
433 control
434 \begin_deeper 
435 \layout Description
436
437 help Show a complete list of commands, help <command name> can be used to
438  get help on specific command
439 \layout Description
440
441 exit Close the lctl session
442 \layout Description
443
444 quit Close the lctl session
445 \end_deeper 
446 \layout Subsection
447
448 EXAMPLES
449 \layout Description
450
451 attach
452 \layout LyX-Code
453
454 # lctl
455 \newline 
456 lctl > newdev
457 \newline 
458 lctl > attach obdfilter OBDDEV OBDUUID 
459 \layout Description
460
461 connect
462 \layout LyX-Code
463
464 lctl > name2dev OSCDEV
465 \newline 
466
467 \newline 
468 lctl > device 2
469 \newline 
470 lctl > connect
471 \newline 
472
473 \layout Description
474
475 getattr
476 \layout LyX-Code
477
478 lctl > getattr 12
479 \newline 
480 id: 12
481 \newline 
482 grp: 0
483 \newline 
484 atime: 1002663714
485 \newline 
486 mtime: 1002663535
487 \newline 
488 ctime: 1002663535
489 \newline 
490 size: 10
491 \newline 
492 blocks: 8
493 \newline 
494 blksize: 4096
495 \newline 
496 mode: 100644
497 \newline 
498 uid: 0
499 \newline 
500 gid: 0
501 \newline 
502 flags: 0
503 \newline 
504 obdflags: 0
505 \newline 
506 nlink: 1
507 \newline 
508 valid: ffffffff
509 \newline 
510 inline:
511 \newline 
512 obdmd:
513 \newline 
514 lctl > disconnect 
515 \newline 
516 Finished (success)
517 \layout Description
518
519 setup 
520 \layout LyX-Code
521
522 lctl > setup /dev/loop0 extN
523 \newline 
524 lctl > quit 
525 \layout LyX-Code
526
527 \layout Subsection
528
529 BUGS
530 \layout Standard
531
532 None are known.
533 \layout Subsection
534
535 AUTHOR
536 \layout Standard
537
538 Cluster File Systems, Inc.
539  2002 - created
540 \the_end