LSMTD(8) System Manager's Manual LSMTD(8)

lsmtd - list memory technology devices

lsmtd [options] [device...]

lsmtd lists information about all available or the specified MTD and UBI devices. The lsmtd command reads the sysfs filesystem to gather information. Alternatively, the procfs filesystem and ioctl interfaces are used, should the sysfs filesystem not be available.

The command prints all MTD and UBI devices in a pretty-printed list format by default.

The default output is subject to change. So whenever possible, you should avoid using default outputs in your scripts. Always explicitly define expected columns by using --output columns-list in environments where a stable output is required.

Use lsmtd --help to get a list of all available columns.

Print columns with size quantities (e.g. erase block size) in bytes instead of a human-readable format.
Display a help text and exit.
Only use ascii characters for pretty printing.
Use JSON output format. All potentially unsafe characters in string values are escaped with JSON escape sequences or hex-escaped (\u<code>).
Use a pretty-printed list output format (default).
Do not display information about UBI devices or volumes.
Do not print column headings when using raw or list output format.
Specify which output columns to print. Use --help to get a list of all supported columns.

The default list of columns may be extended if list is specified in the format +list (e.g. lsmtd -o +EB-SIZE).

Output all available columns.
Produce output in the form of key="value" pairs. All potentially unsafe characters are hex-escaped (\x<code>).
Produce output in raw format. All potentially unsafe characters are hex-escaped (\x<code>).
Display human readable sizes as powers of ten rather than powers of two.
Print version information and exit.
Sort output lines by column.

If the --bytes option is not specified, the JSON output format prints sizes as string values even if they do not have a suffix.

David Oberhollenzer <david.oberhollenzer@sigma-star.at>

Report mtd-utils bugs to the Linux mtd mailing list.

The lsmtd command is part of the mtd-utils package and is available from ftp://ftp.infradead.org/pub/mtd-utils/.

Copyright © 2017 David Oberhollenzer - sigma star gmbh
License GPLv2: GNU GPL version 2 http://gnu.org/licenses/gpl2.html.
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

lsblk(8), ls(1)

April 2017 mtd-utils