2 .TH lnetctl 8 "2017 Jan 12" Lustre "configuration utilities"
8 .B lnetctl --list-commands
10 \fBlnetctl\fR \fB<cmd> <subcmd> [optional parameters]\fR
14 \fBlnetctl\fR is used to configure LNet parameters allowing various configuration
15 and debugging features to be accessed\.
18 \fBlnetctl\fR can be invoked in interactive mode by issuing lnetctl command\.
19 After that, commands are issued as below\.
22 To get a complete listing of available commands, type
24 at the lnetctl prompt\. To get basic help on the meaning and syntax of a command
25 type \fB<command>\fR \-\-help\.
28 For non\-interactive use the \fBlnetctl\fR utility can be invoked from the
29 command line as follows:
32 lnetctl \fIcommand\fR \fIsubcommand\fR [optional parameters]
34 .SS "LNet Initialization:"
37 \fBlnetctl lnet\fR configure [\-\-all]
38 Brings up the LNet Network Interface (NI) system\. If the \-\-all option is
39 provided it will load network interfaces defined in the modprobe files\.
40 Otherwise, it doesn\'t initialize any networks by default\.
43 \fBlnetctl lnet\fR unconfigure
44 Brings down the LNet Network Interface (NI) system including any configured
47 .SS "Network Configuration"
51 Configures a network interface either given the network name and physical
52 interface device name, or given the ip2net parameter\. Other parameters
56 \-\-net: net name (e.g. tcp0)
59 \-\-if: physical interface (e.g. eth0)
62 \-\-nid: LNet network address to bring up. Cannot be combined with \-\-net.
65 \-\-ip2net: specify networks based on IP address patterns
68 \-\-peer\-timeout: time to wait before declaring a peer dead (in seconds).
69 Default value for o2iblnd and socklnd is 180 seconds.
72 \-\-peer\-credits: define the max number of in\-flight messages per peer.
75 \-\-peer\-buffer\-credits: the max number of routed in\-flight messages
79 \-\-credits: The total number of in\-flight messages over a network interface.
82 \-\-cpt: The CPU partitions on which the created network interface is bound to.
83 Refer to the Lustre Manual Section "Binding Network Interface Against CPU
84 Partitions" for more details. For example to bind a Network Interface to
85 CPU partitions 0 and 1, you would specify this parameter as \-\-cpt [0,
93 Delete a network interface given the network name\.
96 \-\-net: net name (e.g. tcp0)
99 \-\-nid: lnet network address to bring up. Cannot be combined with \-\-net.
104 \fBlnetctl net\fR show
105 Show all currently configured network interfaces if no parameters given or filter
106 on the network name\. More details can be shown by specifying the \-\-verbose
110 \-\-net: net name (e.g. tcp0) to filter on
113 \-\-verbose: display detailed output per network
116 .SS "Peer Configuration"
118 \fBlnetctl peer\fR add
119 Configure an LNET peer with at least one supplied NID\. The primary NID must be specified. By default, peers are marked as multi-rail capable\.
123 \-\-nid: one or more peer NIDs to add to the peer\.
127 \-\-prim_nid: Primary NID of the peer\.
130 \-\-non_mr: create this peer as not Multi-Rail capable\.
133 \-\-lock_prim: lock primary NID of the peer for the purpose of identification with Lustre\.
138 \fBlnetctl peer\fR del
139 Delete a peer NID. The primary NID must be specified. If the removed NID is the primary NID, the peer entry will be deleted.
143 \-\-nid: one or more peer NIDs to remove from the peer\.
147 \-\-prim_nid: Primary NID of the peer\.
150 \-\-force: optional, use to delete a peer with primary NID locked\.
155 \fBlnetctl peer\fR show
156 Show configured peers. By default, lists all peers and associated NIDs.
160 \-\-nid: list of primary nids to filter on
164 \-\-verbose: Include extended statistics, including credits and counters.
169 .SS "Route Configuration"
172 \fBlnetctl route\fR add
176 \-\-net: net name (e.g. tcp0)
179 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp)
182 \-\-hop: number to final destination (1 < hops < 255)
185 \-\-priority: priority of route (0 \- highest prio)
191 \fBlnetctl route\fR del
192 Delete a route specified via the network and gateway\.
195 \-\-net: net name (e.g. tcp0)
198 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp)
204 \fBlnetctl route\fR show
205 Show all currently configured routes if no parameters given, or filter on
206 given parameters\. More details can be shown by specifying the \-\-verbose
210 \-\-net: net name (e.g. tcp0) to filter on
213 \-\-gateway: gateway nid (e.g. 10\.1\.1\.2@tcp) to filter on
216 \-\-hop: number to final destination (1 < hops < 255) to filter on
219 \-\-priority: priority of route (0 \- highest prio to filter on)
222 \-\-verbose: display detailed output per route
227 .SS "Routing Information"
230 \fBlnetctl routing\fR show
231 Show router buffers values as well as show the status of routing (IE: whether
232 the node is set to be a router)
235 Individual values can be set using the \fBlnetctl set\fR command\.
238 \fBlnetctl set\fR tiny_buffers \fIvalue\fR
239 Set the number of tiny buffers in the system\. This is the total number of tiny
240 buffers for all CPU partitions\.
243 \fBlnetctl set\fR small_buffers \fIvalue\fR
244 Set the number of small buffers in the system\. This is the total number of
245 small buffers for all CPU partitions\.
248 \fBlnetctl set\fR large_buffers \fIvalue\fR
249 Set the number of large buffers in the system\. This is the total number of
250 large buffers for all CPU partitions\.
253 \fBlnetctl set\fR routing \fI[0, 1]\fR
254 0 value indicates to disable routing\. 1 value indicates to enable routing\.
255 When routing is disabled the values of the buffers that might have been changed
256 are not remembered, and the next time routing is enabled the default buffer
260 \fBlnetctl set\fR drop_asym_route \fI[0, 1]\fR
261 0 value indicates to accept asymmetrical route messages\. 1 value indicates to
262 drop them\. Asymmetrical route is when a message from a remote peer is coming
263 through a router that would not be used by this node to reach the remote peer\.
266 \fBlnetctl set\fR response_tracking \fI[0, 1, 2, 3]\fR
267 Set the behavior of response tracking\.
268 0 - Only LNet pings and discovery pushes utilize response tracking\.
269 1 - GETs are eligible for response tracking\.
270 2 - PUTs are eligible for response tracking\.
271 3 - Both PUTs and GETs are eligible for response tracking (default)\.
272 Note: Regardless of the value of the response_tracking parameter LNet
273 pings and discovery pushes always utilize response tracking\.
276 \fBlnetctl set\fR recovery_limit \fIvalue\fR
277 Set how long LNet will attempt to recover unhealthy peer interfaces\.
278 0 - Recover indefinitely (default)\.
279 >0 - Recover for the specified number of seconds\.
282 \fBlnetctl set\fR max_recovery_ping_interval \fIvalue\fR
283 Set the maximum recovery ping interval.
284 The recovery ping mechanism increases the next scheduled recovery ping attempt
285 timeout exponentially (base 2) until it is equal to the value set.
286 The default value is 900.
288 .SS "Import and Export YAML Configuration Files"
289 LNet configuration can be represented in YAML format\. A YAML configuration
290 file can be passed to the lnetctl utility via the \fBimport\fR command\. The
291 lnetctl utility will attempt to configure all elements defined in the YAML
295 Similarly the \fBexport\fR command can be used to dump all supported LNet
296 configuration to stdout\. The output can be redirected to a file\.
299 \fBlnetctl import\fR \fIFILE\fR:
303 \fBlnetctl import\fR < \fIFILE\fR
304 \fBimport\fR command uses the specified YAML configuration file to configure
305 LNet parameters defined within\. The import command by default adds the LNet
306 parameters defined in the YAML file, but this default behavior can be
307 overwritten by specifying the desired behavior\.
310 \-\-add: add configuration
313 \-\-del: delete configuration
316 \-\-show: show configuration
319 \-\-exec: execute command
322 \-\-help: display this help
325 \fBlnetctl export\fR \fIFILE\fR:
329 \fBlnetctl export\fR > \fIFILE\fR
330 \fBexport\fR command dumps the LNet configuration, state information, and stats
331 in YAML format to stdout, which can be redirected to a normal file\. The output
332 of the \fBexport\fR command can be used as input to the \fBimport\fR command\.
335 \-\-backup: dump only elements necessary to recreate the current configuration.
338 \-\-help: display this help
340 .SS "LNet Statistics"
343 \fBlnetctl stats\fR show
347 \-> Number of messages allocated
350 \-> Maximum number of messages allocated
353 \-> Number of errors encountered
356 \-> Number of messages sent
359 \-> Number of messages received
362 \-> Number of messages routed
365 \-> Total size in bytes of messages sent
368 \-> Total size in bytes of messages received
371 \-> Total size in bytes of messages routed
374 \-> Total size in bytes of messages dropped
379 .SS "Showing Peer Credits"
382 \fBlnetctl peer_credits\fR
383 Show details on configured peer credits
392 \-> Reference count on the peer
395 \-> Maximum transmit credits
398 \-> Available transmit credits
401 \-> Available router credits
404 \-> Minimum router credits\.
406 .SS "UDSP Configuration"
409 \fBlnetctl udsp\fR add
410 Add user-defined selection policy.
415 Adding a local network udsp.
418 If multiple local networks are available, each one can be assigned a priority\.
419 The one with the highest priority is selected to send on\.
420 NID and network matching is using NID-range syntax, please see the manual for more detail\.
423 \-\-src : network in NID-range syntax (e.g. tcp0 or tcp[1-3])
426 \-\-<priority> <priority value>: optional priority value in [0-255], 0 as the highest
429 \-\-<idx>: The index of where to insert the rule\. By default append to the end of the list
434 Adding a local NID udsp.
437 Assign priority to local NIDs\. After a local network is chosen, the NI with highest priority is selected\.
440 \-\-src: NID in NID-range syntax (e.g. 10.1.1.2@tcp or 10.1.1.*@tcp)
443 \-\-<priority> <priority value>: optional priority value in [0-255], 0 as the highest
446 \-\-<idx>: The index of where to insert the rule\. By default append to the end of the list
451 Adding a peer NID udsp.
454 Assign priority to peer NIDs. Peer NID with highest priority is selected to send to\.
457 \-\-dst: NID in NID-range syntax (e.g. 10.1.1.2@tcp)
460 \-\-<priority> <priority value>: optional priority value in [0-255], 0 as the highest
463 \-\-<idx>: The index of where to insert the rule\. By default append to the end of the list
468 Adding a NID pair udsp.
471 The local NIDs which match the rule are added on a list on the peer NIs matching the rule\.
472 When selecting the peer NI, the one with the local NID being used on its list is preferred\.
475 \-\-dst: NID in NID-range syntax (e.g. 10.1.1.1@tcp)
478 \-\-src: NID in NID-range syntax (e.g. 10.1.1.2@tcp)
481 \-\-<idx>: The index of where to insert the rule\. By default append to the end of the list
486 Adding a Peer Router udsp.
489 The router NIDs matching the rule are added on a list on the peer NIs matching the rule\.
490 When sending to a remote peer, the router which has its nid on the peer NI list is preferred\.
493 \-\-dst: peer NID in NID-range syntax (e.g. 10.1.1.1@tcp)
496 \-\-rte: router NID in NID-range syntax (e.g. 10.1.2.1@tcp)
499 \-\-<idx>: The index of where to insert the rule\. By default append to the end of the list
504 \fBlnetctl udsp\fR del
505 Delete user-defined selection policy.
508 \-\-idx: The index of the rule to delete\.
512 \fBlnetctl udsp\fR show
513 Show all user-defined selection policies in the system\. The policies are dumped in YAML form\.
518 \fBlnetctl debug\fR recovery
519 List NIDs on recovery queue
522 \-\-local : list NIDs on local recovery queue
525 \-\-peer : list NIDs on peer recovery queue
530 \fBlnetctl debug\fR peer
531 Dump peer debug info to debug log and console
541 Output a list of the commands supported by the lnetctl utility
544 .SS "Initializing LNet after load"
547 lnetctl lnet configure
550 lnetctl lnet configure \-\-all
554 .SS "Shutting down LNet"
557 lnetctl lnet unconfigure
564 lnetctl net add \-\-net tcp0 \-\-if eth0
567 lnetctl net add \-\-ip2net "tcp0(eth0) 192\.168\.0\.[2,4]; tcp0 192\.168\.0\.*;
568 o2ib0 132\.6\.[1\-3]\.[2\-8/2]"
575 lnetctl net del \-\-net tcp0
582 lnetctl net show \-\-verbose:
604 peer_buffer_credits: 0
610 \- nid: 192\.168\.205\.130@tcp1
634 peer_buffer_credits: 0
644 lnetctl route add \-\-net tcp0 \-\-gateway 10\.10\.10\.1@tcp1 \-\-hop 1
652 lnetctl route del \-\-net tcp0 \-\-gateway 10\.10\.10\.1@tcp1
659 lnetctl route show \-\-verbose
670 gateway: 192\.168\.205\.131@tcp1
676 priority: 0 state: down
741 .SS "Setting variables"
744 lnetctl set tiny_buffers 2048
747 lnetctl set small_buffers 16384
750 lnetctl set large_buffers 256
753 lnetctl set routing 1
757 .SS "Importing YAML files for configuring"
760 lnetctl import lnet\.conf
763 lnetctl import < lnet\.conf
767 .SS "Exporting LNet Configuration"
770 lnetctl export lnet\.conf
773 lnetctl export > lnet\.conf
777 .SS "Showing LNet Stats"
822 .SS "Showing peer information"
833 \- primary nid: 10\.148\.0\.8@o2ib
842 \- nid: 10\.148\.0\.8@o2ib
848 \- primary nid: 10\.148\.0\.20@o2ib
857 \- nid: 10\.148\.0\.20@o2ib
863 \- nid: 10\.148\.0\.25@o2ib
873 lnetctl udsp add \-\-src tcp \-\-priority 1
879 .SS "Deleting a UDSP"
882 lnetctl udsp del \-\-idx 0