Whamcloud - gitweb
LU-5813 lnet: Fix typo in route show command
[fs/lustre-release.git] / lustre / doc / lnetctl.8
1 .
2 .TH lnetctl 1 "2014 Sep 12" Lustre "configuration utilities"
3 .
4 .SH "SYNOPSIS"
5 \fBlnetctl\fR
6 .
7 .br
8 \fBlnetctl\fR \fB<cmd> <subcmd> [optional parameters]\fR
9 .
10 .SH "DESCRIPTION"
11 \fBlnetctl\fR is used to configure LNet parameters allowing various configuration
12 and debugging features to be accessed\.
13 .
14 .P
15 \fBlnetctl\fR can be invoked in interactive mode by issuing lnetctl command\.
16 After that, commands are issued as below\.
17 .
18 .P
19 To get a complete listing of available commands, type \fBhelp\fR at the
20 lnetctl prompt\. To get basic help on the meaning and syntax of a command
21 type \fB<command>\fR \-\-help\.
22 .
23 .P
24 For non\-interactive use the \fBlnetctl\fR utility can be invoked from the
25 command line as follows:
26 .
27 .P
28 lnetctl \fIcommand\fR \fIsubcommand\fR [optional parameters]
29 .
30 .SS "LNet Initialization:"
31 .
32 .TP
33 \fBlnetctl lnet\fR configure [\-\-all]
34 Brings up the LNet Network Interface (NI) system\. If the \-\-all option is
35 provided it will load network interfaces defined in the modprobe files\.
36 Otherwise, it doesn\'t initialize any networks by default\.
37 .
38 .TP
39 \fBlnetctl lnet\fR unconfigure
40 Brings down the LNet Network Interface (NI) system including any configured
41 networks\.
42 .
43 .SS "Network Configuration"
44 .
45 .TP
46 \fBlnetctl net\fR add
47 Configures a network interface either given the network name and physical
48 interface device name, or given the ip2net parameter\. Other parameters
49 are optional\.
50 .
51 .br
52 \-\-net: net name (e.g. tcp0)
53 .
54 .br
55 \-\-if: physical interface (e.g. eth0)
56 .
57 .br
58 \-\-ip2net: specify networks based on IP address patterns
59 .
60 .br
61 \-\-peer\-timeout: time to wait before declaring a peer dead (in seconds).
62 Default value for o2iblnd and socklnd is 180 seconds.
63 .
64 .br
65 \-\-peer\-credits: define the max number of in\-flight messages per peer.
66 .
67 .br
68 \-\-peer\-buffer\-credits: the max number of routed in\-flight messages
69 per peer.
70 .
71 .br
72 \-\-credits: The total number of in\-flight messages over a network interface.
73 .
74 .br
75 \-\-cpt: The CPU partitions on which the created network interface is bound to.
76 Refer to the Lustre Manual Section "Binding Network Interface Against CPU
77 Partitions" for more details. For example to bind a Network Interface to
78 CPU partitions 0 and 1, you would specify this parameter as \-\-cpt [0,
79 1]
80 .
81 .br
82
83 .
84 .TP
85 \fBlnetctl net\fR del
86 Delete a network interface given the network name\.
87 .
88 .br
89 \-\-net: net name (e.g. tcp0)
90 .
91 .br
92
93 .
94 .TP
95 \fBlnetctl net\fR show
96 Show all currently configured network interfaces if no parameters given or filter
97 on the network name\. More details can be shown by specifying the \-\-verbose
98 parameter\.
99 .
100 .br
101 \-\-net: net name (e.g. tcp0) to filter on
102 .
103 .br
104 \-\-verbose: display detailed output per network
105 .
106 .SS "Route Configuration"
107 .
108 .TP
109 \fBlnetctl route\fR add
110 Add a route\.
111 .
112 .br
113 \-\-net: net name (e.g. tcp0)
114 .
115 .br
116 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp)
117 .
118 .br
119 \-\-hop: number to final destination (1 < hops < 255)
120 .
121 .br
122 \-\-priority: priority of route (0 \- highest prio)
123 .
124 .br
125
126 .
127 .TP
128 \fBlnetctl route\fR del
129 Delete a route specified via the network and gateway\.
130 .
131 .br
132 \-\-net: net name (e.g. tcp0)
133 .
134 .br
135 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp)
136 .
137 .br
138
139 .
140 .TP
141 \fBlnetctl route\fR show
142 Show all currently configured routes if no parameters given, or filter on
143 given parameters\. More details can be shown by specifying the \-\-verbose
144 parameter\.
145 .
146 .br
147 \-\-net: net name (e.g. tcp0) to filter on
148 .
149 .br
150 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp) to filter on
151 .
152 .br
153 \-\-hop: number to final destination (1 < hops < 255) to filter on
154 .
155 .br
156 \-\-priority: priority of route (0 \- highest prio to filter on)
157 .
158 .br
159 \-\-verbose: display detailed output per route
160 .
161 .br
162
163 .
164 .SS "Routing Information"
165 .
166 .TP
167 \fBlnetctl routing\fR show
168 Show router buffers values as well as show the status of routing (IE: whether
169 the node is set to be a router)
170 .
171 .SS "Value Setting"
172 Individual values can be set using the \fBlnetctl set\fR command\.
173 .
174 .TP
175 \fBlnetctl set\fR tiny_buffers \fIvalue\fR
176 Set the number of tiny buffers in the system\. This is the total number of tiny
177 buffers for all CPU partitions\.
178 .
179 .TP
180 \fBlnetctl set\fR small_buffers \fIvalue\fR
181 Set the number of small buffers in the system\. This is the total number of
182 small buffers for all CPU partitions\.
183 .
184 .TP
185 \fBlnetctl set\fR large_buffers \fIvalue\fR
186 Set the number of large buffers in the system\. This is the total number of
187 large buffers for all CPU partitions\.
188 .
189 .TP
190 \fBlnetctl set\fR routing \fI[0, 1]\fR
191 0 value indicates to disable routing\. 1 value indicates to enable routing\.
192 When routing is disabled the values of the buffers that might have been changed
193 are not remembered, and the next time routing is enabled the default buffer
194 count will be used\.
195 .
196 .SS "Import and Export YAML Configuration Files"
197 LNet configuration can be represented in YAML format\. A YAML configuration
198 file can be passed to the lnetctl utility via the \fBimport\fR command\. The
199 lnetctl utility will attempt to configure all elements defined in the YAML
200 file\.
201 .
202 .P
203 Similarly the \fBexport\fR command can be used to dump all supported LNet
204 configuration to stdout\. The output can be redirected to a file\.
205 .
206 .TP
207 \fBlnetctl import\fR \fIFILE\fR:
208
209 .
210 .TP
211 \fBlnetctl import\fR < \fIFILE\fR
212 \fBimport\fR command uses the specified YAML configuration file to configure
213 LNet parameters defined within\. The import command by default adds the LNet
214 parameters defined in the YAML file, but this default behavior can be
215 overwritten by specifying the desired behavior\.
216 .
217 .br
218 \-\-add: add configuration
219 .
220 .br
221 \-\-del: delete configuration
222 .
223 .br
224 \-\-show: show configuration
225 .
226 .br
227 \-\-help: display this help
228 .
229 .TP
230 \fBlnetctl export\fR \fIFILE\fR:
231
232 .
233 .TP
234 \fBlnetctl export\fR > \fIFILE\fR
235 \fBexport\fR command dumps the supported LNet configuration in YAML format to
236 stdout, which can be redirected to a normal file\. The output of the
237 \fBimport\fR command can be used as input to the \fBexport\fR command\.
238 .
239 .br
240 \-\-help: display this help
241 .
242 .SS "LNet Statistics"
243 .
244 .TP
245 \fBlnetctl stats\fR
246 Show LNET statistics
247 .
248 .br
249 \-> Number of messages allocated
250 .
251 .br
252 \-> Maximum number of messages allocated
253 .
254 .br
255 \-> Number of errors encountered
256 .
257 .br
258 \-> Number of messages sent
259 .
260 .br
261 \-> Number of messages received
262 .
263 .br
264 \-> Number of messages routed
265 .
266 .br
267 \-> Total size in bytes of messages sent
268 .
269 .br
270 \-> Total size in bytes of messages received
271 .
272 .br
273 \-> Total size in bytes of messages routed
274 .
275 .br
276 \-> Total size in bytes of messages dropped
277 .
278 .br
279
280 .
281 .SS "Showing Peer Credits"
282 .
283 .TP
284 \fBlnetctl peer_credits\fR
285 Show details on configured peer credits
286 .
287 .br
288 \-> Peer nid
289 .
290 .br
291 \-> State
292 .
293 .br
294 \-> Reference count on the peer
295 .
296 .br
297 \-> Maximum transmit credits
298 .
299 .br
300 \-> Available transmit credits
301 .
302 .br
303 \-> Available router credits
304 .
305 .br
306 \-> Minimum router credits\.
307 .
308 .SH "EXAMPLES"
309 .
310 .SS "Initializing LNet after load"
311 .
312 .IP "\(bu" 4
313 lnetctl lnet configure
314 .
315 .IP "\(bu" 4
316 lnetctl lnet configure \-\-all
317 .
318 .IP "" 0
319 .
320 .SS "Shutting down LNet"
321 .
322 .IP "\(bu" 4
323 lnetctl lnet unconfigure
324 .
325 .IP "" 0
326 .
327 .SS "Add network"
328 .
329 .IP "\(bu" 4
330 lnetctl net add \-\-net tcp0 \-\-if eth0
331 .
332 .IP "\(bu" 4
333 lnetctl net add \-\-ip2net "tcp0(eth0) 192\.168\.0\.[2,4]; tcp0 192\.168\.0\.*;
334 o2ib0 132\.6\.[1\-3]\.[2\-8/2]"
335 .
336 .IP "" 0
337 .
338 .SS "Delete network"
339 .
340 .IP "\(bu" 4
341 lnetctl net del \-\-net tcp0
342 .
343 .IP "" 0
344 .
345 .SS "Show network"
346 .
347 .TP
348 lnetctl net show \-\-verbose:
349
350 .
351 .P
352 net:
353 .
354 .br
355         \- nid: 0@lo
356 .
357 .br
358           status: up
359 .
360 .br
361           tunables:
362 .
363 .br
364                 peer_timeout: 0
365 .
366 .br
367                 peer_credits: 0
368 .
369 .br
370                 peer_buffer_credits: 0
371 .
372 .br
373                 credits: 0
374 .
375 .br
376         \- nid: 192\.168\.205\.130@tcp1
377 .
378 .br
379           status: up
380 .
381 .br
382           interfaces:
383 .
384 .br
385                 0: eth3
386 .
387 .br
388                 1: eth4
389 .
390 .br
391           tunables:
392 .
393 .br
394                 peer_timeout: 180
395 .
396 .br
397                 peer_credits: 8
398 .
399 .br
400                 peer_buffer_credits: 0
401 .
402 .br
403                 credits: 256
404 .
405 .br
406 .
407 .SS "Add route"
408 .
409 .IP "\(bu" 4
410 lnetctl route add \-\-net tcp0 \-\-gateway 10\.10\.10\.1@tcp1 \-\-hop 1
411 \-\-priority 1
412 .
413 .IP "" 0
414 .
415 .SS "Delete route"
416 .
417 .IP "\(bu" 4
418 lnetctl route del \-\-net tcp0 \-\-gateway 10\.10\.10\.1@tcp1
419 .
420 .IP "" 0
421 .
422 .SS "Show route"
423 .
424 .IP "\(bu" 4
425 lnetctl route show \-\-verbose
426 .
427 .IP "" 0
428 .
429 .P
430 route:
431 .
432 .br
433         \- net: tcp
434 .
435 .br
436           gateway: 192\.168\.205\.131@tcp1
437 .
438 .br
439           hop: 1
440 .
441 .br
442           priority: 0 state: down
443 .
444 .br
445 .
446 .SS "Show routing"
447 .
448 .IP "\(bu" 4
449 lnetctl routing show
450 .
451 .IP "" 0
452 .
453 .P
454 routing:
455 .
456 .br
457         \- cpt[0]:
458 .
459 .br
460           tiny:
461 .
462 .br
463                 npages: 0
464 .
465 .br
466                 nbuffers: 2048
467 .
468 .br
469                 credits: 2048
470 .
471 .br
472                 mincredits: 2048
473 .
474 .br
475           small:
476 .
477 .br
478                 npages: 1
479 .
480 .br
481                 nbuffers: 16384
482 .
483 .br
484                 credits: 16384
485 .
486 .br
487                 mincredits: 16384
488 .
489 .br
490           large:
491 .
492 .br
493                 npages: 256
494 .
495 .br
496                 nbuffers: 1024
497 .
498 .br
499                 credits: 1024
500 .
501 .br
502                 mincredits: 1024
503 .
504 .br
505         \- enable: 1
506 .
507 .SS "Setting variables"
508 .
509 .IP "\(bu" 4
510 lnetctl set tiny_buffers 2048
511 .
512 .IP "\(bu" 4
513 lnetctl set small_buffers 16384
514 .
515 .IP "\(bu" 4
516 lnetctl set large_buffers 256
517 .
518 .IP "\(bu" 4
519 lnetctl set routing 1
520 .
521 .IP "" 0
522 .
523 .SS "Importing YAML files for configuring"
524 .
525 .IP "\(bu" 4
526 lnetctl import lnet\.conf
527 .
528 .IP "\(bu" 4
529 lnetctl import < lnet\.conf
530 .
531 .IP "" 0
532 .
533 .SS "Exporting LNet Configuration"
534 .
535 .IP "\(bu" 4
536 lnetctl export lnet\.conf
537 .
538 .IP "\(bu" 4
539 lnetctl export > lnet\.conf
540 .
541 .IP "" 0
542 .
543 .SS "Showing LNet Stats"
544 .
545 .IP "\(bu" 4
546 lnetctl stats show
547 .
548 .IP "" 0
549 .
550 .P
551 statistics:
552 .
553 .br
554         msgs_alloc: 0
555 .
556 .br
557         msgs_max: 1
558 .
559 .br
560         errors: 0
561 .
562 .br
563         send_count: 89
564 .
565 .br
566         recv_count: 0
567 .
568 .br
569         route_count: 0
570 .
571 .br
572         drop_count: 19
573 .
574 .br
575         send_length: 0
576 .
577 .br
578         recv_length: 0
579 .
580 .br
581         route_length: 0
582 .
583 .br
584         drop_length: 0
585 .
586 .br
587 .
588 .SS "Showing peer credits information"
589 .
590 .IP "\(bu" 4
591 lnetctl peer_credits show
592 .
593 .IP "" 0
594 .
595 .P
596 peer:
597 .
598 .br
599         \- nid: 192\.168\.205\.131@tcp1
600 .
601 .br
602           state: down
603 .
604 .br
605           refcount: 4
606 .
607 .br
608           max_ni_tx_credits: 8
609 .
610 .br
611           available_tx_credits: 8
612 .
613 .br
614           available_rtr_credits: 8
615 .
616 .br
617           min_rtr_credits: 7
618 .
619 .br
620           tx_q_num_of_buf: 0
621 .
622 .br
623
624 .SH SEE ALSO
625 .BR Lustre (7)
626