]>
Commit | Line | Data |
---|---|---|
295b3979 | 1 | //po4a: entry man manual |
6d5b6948 MB |
2 | = lsmem(1) |
3 | :doctype: manpage | |
f42ed819 | 4 | :man manual: User Commands |
6d5b6948 MB |
5 | :man source: util-linux {release-version} |
6 | :page-layout: base | |
7 | :command: lsmem | |
8 | ||
9 | == NAME | |
10 | ||
11 | lsmem - list the ranges of available memory with their online status | |
12 | ||
13 | == SYNOPSIS | |
14 | ||
4d297435 | 15 | *lsmem* [options] |
6d5b6948 MB |
16 | |
17 | == DESCRIPTION | |
18 | ||
19 | The *lsmem* command lists the ranges of available memory with their online status. The listed memory blocks correspond to the memory block representation in sysfs. The command also shows the memory block size and the amount of memory in online and offline state. | |
20 | ||
21 | The default output compatible with original implementation from s390-tools, but it's strongly recommended to avoid using default outputs in your scripts. Always explicitly define expected columns by using the *--output* option together with a columns list in environments where a stable output is required. | |
22 | ||
23 | The *lsmem* command lists a new memory range always when the current memory block distinguish from the previous block by some output column. This default behavior is possible to override by the *--split* option (e.g., *lsmem --split=ZONES*). The special word "none" may be used to ignore all differences between memory blocks and to create as large as possible continuous ranges. The opposite semantic is *--all* to list individual memory blocks. | |
24 | ||
25 | Note that some output columns may provide inaccurate information if a split policy forces *lsmem* to ignore differences in some attributes. For example if you merge removable and non-removable memory blocks to the one range than all the range will be marked as non-removable on *lsmem* output. | |
26 | ||
27 | Not all columns are supported on all systems. If an unsupported column is specified, *lsmem* prints the column but does not provide any data for it. | |
28 | ||
29 | Use the *--help* option to see the columns description. | |
30 | ||
31 | == OPTIONS | |
32 | ||
33 | *-a*, *--all*:: | |
4eab78d3 | 34 | List each individual memory block, instead of combining memory blocks with similar attributes. |
6d5b6948 MB |
35 | |
36 | *-b*, *--bytes*:: | |
4c989ad4 | 37 | include::man-common/in-bytes.adoc[] |
6d5b6948 MB |
38 | |
39 | *-h*, *--help*:: | |
4eab78d3 | 40 | Display help text and exit. |
6d5b6948 MB |
41 | |
42 | *-J*, *--json*:: | |
4eab78d3 | 43 | Use JSON output format. |
6d5b6948 MB |
44 | |
45 | *-n*, *--noheadings*:: | |
4eab78d3 | 46 | Do not print a header line. |
6d5b6948 MB |
47 | |
48 | *-o*, *--output* _list_:: | |
4eab78d3 | 49 | 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., *lsmem -o +NODE*). |
6d5b6948 MB |
50 | |
51 | *--output-all*:: | |
4eab78d3 | 52 | Output all available columns. |
6d5b6948 MB |
53 | |
54 | *-P*, *--pairs*:: | |
4eab78d3 | 55 | Produce output in the form of key="value" pairs. All potentially unsafe value characters are hex-escaped (\x<code>). |
6d5b6948 MB |
56 | |
57 | *-r*, *--raw*:: | |
4eab78d3 | 58 | Produce output in raw format. All potentially unsafe characters are hex-escaped (\x<code>). |
6d5b6948 MB |
59 | |
60 | *-S*, *--split* _list_:: | |
c83a52f0 | 61 | Specify which columns (attributes) use to split memory blocks to ranges. The supported columns are STATE, REMOVABLE, NODE and ZONES, or "none". The other columns are silently ignored. For more details see *DESCRIPTION* above. |
6d5b6948 MB |
62 | |
63 | *-s*, *--sysroot* _directory_:: | |
4eab78d3 | 64 | Gather memory data for a Linux instance other than the instance from which the *lsmem* command is issued. The specified _directory_ is the system root of the Linux instance to be inspected. |
6d5b6948 MB |
65 | |
66 | *-V*, *--version*:: | |
4eab78d3 | 67 | Display version information and exit. |
6d5b6948 MB |
68 | |
69 | *--summary*[=_when_]:: | |
4eab78d3 | 70 | This option controls summary lines output. The optional argument _when_ can be *never*, *always* or *only*. If the _when_ argument is omitted, it defaults to *"only"*. The summary output is suppressed for *--raw*, *--pairs* and *--json*. |
6d5b6948 MB |
71 | |
72 | == AUTHORS | |
73 | ||
74 | *lsmem* was originally written by Gerald Schaefer for s390-tools in Perl. The C version for util-linux was written by Clemens von Mann, Heiko Carstens and Karel Zak. | |
75 | ||
76 | == SEE ALSO | |
77 | ||
78 | *chmem*(8) | |
79 | ||
625e9c61 | 80 | include::man-common/bugreports.adoc[] |
6d5b6948 | 81 | |
625e9c61 | 82 | include::man-common/footer.adoc[] |
6d5b6948 MB |
83 | |
84 | ifdef::translation[] | |
625e9c61 | 85 | include::man-common/translation.adoc[] |
6d5b6948 | 86 | endif::[] |