---
name: "lctl"
section: "1"
platform: "linux"
package: "lustre-utils"
version: "1.8.3-4"
release: "Debian 6.0 (Squeeze)"
platforms: ["linux"]
url: "https://new.carta.tech/lctl"
---

# lctl(1)

Low level Lustre filesystem configuration utility

## NAME

lctl - Low level Lustre filesystem configuration utility

## SYNOPSIS

**lctl**\
 **lctl --device \<devno\> \<command \[args\]\>**\

## DESCRIPTION

**lctl** is used to directly control Lustre via an ioctl interface, allowing various configuration, maintenance, and debugging features to be accessed.

**lctl** can be invoked in interactive mode by issuing lctl command. After that, commands are issued as below. The most common commands in lctl are **dl** , **device** , **network** *\<up/down\>* , **list\_nids** , **ping** *nid* , **help** , **quit.**

To get a complete listing of available commands, type **help** at the lctl prompt.  To get basic help on the meaning and syntax of a command, type  **help** *command* Command completion is activated with the TAB key, and command history is available via the up- and down-arrow keys.

For non-interactive use, one uses the second invocation, which runs command after connecting to the device.

### Network Configuration

- **network** *\<up/down\>\|\<tcp/elan/myrinet\>*

  Start or stop LNET, or select a network type for other *lctl* LNET commands

- **list\_nids**

  Print all Network Identifiers on the local node. LNET must be running.

- **which\_nid** *\<nidlist\>*

  From a list of nids for a remote node, show which interface communication will take place on.

- **ping** *\<nid\>*

  Check LNET connectivity via an LNET ping. This will use the fabric appropriate to the specified NID.

- **interface\_list**

  Print the network interface information for a given  **network** type.

- **peer\_list**

  Print the known peers for a given  **network** type.

- **conn\_list**

  Print all the connected remote NIDs for a given **network** type.

- **active\_tx**

  This command should print active transmits, and it is only used for elan network type.

- **route\_list**

  Print the complete routing table.

### Device Selection

- **device** *\<devname\>*

  This will select the specified OBD device.  All other commands depend on the device being set.

- **device\_list**

  Show all the local Lustre OBDs. AKA  **dl**

### Device Operations

- **conf\_param** *\<device\> \<parameter\>*

  Set a permanent configuration parameter for any device via the MGS.  This command must be run on the MGS node.

- **activate**

  Reactivate an import after deactivating, below.

- **deactivate**

  Deactivate an import, in particular meaning do not assign new file stripes to an OSC.  This command should be used on the OSC in the MDT LOV corresponding to a failed OST device, to prevent further attempts at communication with the failed OST.

- **abort\_recovery**

  Abort the recovery process on a restarting MDT or OST device

### Virtual Block Device Operation

Lustre is able to emulate a virtual block device upon regular file. It is necessary to be used when you are trying to setup a swap space via file.

- **blockdev\_attach** *\<file name\> \<device node\>*

  Attach the lustre regular file to a block device. If the device node is not existent, lctl will create it - it is recommended to create it by lctl since the emulator uses a dynamical major number.

- **blockdev\_detach** *\<device node\>*

  Detach the virtual block device.

- **blockdev\_info** *\<device node\>*

  Acquire which lustre file was attached to the device node.

### Debug

- **debug\_daemon**

  Start and stop the debug daemon, and control the output filename and size.

- **debug\_kernel** *\[file\] \[raw\]*

  Dump the kernel debug buffer to stdout or file.

- **debug\_file** *\<input\> \[output\]*

  Convert kernel-dumped debug log from binary to plain text format.

- **clear**

  Clear the kernel debug buffer.

- **mark** *\<text\>*

  Insert marker text in the kernel debug buffer.

- **filter** *\<subsystem id/debug mask\>*

  Filter kernel debug messages by subsystem or mask.

- **show** *\<subsystem id/debug mask\>*

  Show specific type of messages.

- **debug\_list** *\<subs/types\>*

  List all the subsystem and debug types.

- **modules** *\<path\>*

  Provide gdb-friendly module information.

## OPTIONS

The following options can be used to invoke lctl.

- **--device**

  The device to be used for the operation. This can be specified by name or number. See  **device\_list**

- **--ignore\_errors \| ignore\_errors**

  Ignore errors during script processing

- \# lctl

  ## EXAMPLES

lctl \> dl\
   0 UP mgc MGC192.168.0.20@tcp bfbb24e3-7deb-2ffa-eab0-44dffe00f692 5\
   1 UP ost OSS OSS\_uuid 3\
   2 UP obdfilter testfs-OST0000 testfs-OST0000\_UUID 3\
 lctl \> dk /tmp/log Debug log: 87 lines, 87 kept, 0 dropped.\
 lctl \> quit

\# lctl conf\_param testfs-MDT0000 sys.timeout=40

## BUGS

Please report all bugs to Sun Microsystems, Inc. http://bugzilla.lustre.org/

## AVAILABILITY

**lctl** is part of the  **Lustre**(7) filesystem package and is available from Sun Microsystems, Inc.\
 http://www.sun.com/software/products/lustre/index.xml

## SEE ALSO

**Lustre**(7), [**mkfs.lustre**(8)](/mkfs.lustre/8.md), [**mount.lustre**(8)](/mount.lustre/8.md), **lctl**(8), **lfs**(1)
