157 lines
5.2 KiB
HTML
157 lines
5.2 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of LSMEM</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>LSMEM</H1>
|
|
Section: User Commands (1)<BR>Updated: October 2016<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
lsmem - list the ranges of available memory with their online status
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
<B>lsmem</B>
|
|
|
|
[options]
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
The <B>lsmem</B> 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.
|
|
<P>
|
|
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 <B>--output</B> option
|
|
together with a columns list in environments where a stable output is required.
|
|
<P>
|
|
The <B>lsmem</B> 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 <B>--split</B> option (e.g. <B>lsmem
|
|
--split=ZONES</B>). 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 <B>--all</B> to list individual memory
|
|
blocks.
|
|
<P>
|
|
Note that some output columns may provide inaccurate information if a split policy
|
|
forces <B>lsmem</B> 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 <B>lsmem</B> output.
|
|
<P>
|
|
Not all columns are supported on all systems. If an unsupported column is
|
|
specified, <B>lsmem</B> prints the column but does not provide any data for it.
|
|
<P>
|
|
Use the <B>--help</B> option to see the columns description.
|
|
<P>
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
<DL COMPACT>
|
|
<DT id="1"><B>-a</B>, <B>--all</B>
|
|
|
|
<DD>
|
|
List each individual memory block, instead of combining memory blocks with
|
|
similar attributes.
|
|
<DT id="2"><B>-b</B>,<B> --bytes</B>
|
|
|
|
<DD>
|
|
Print the SIZE column in bytes rather than in a human-readable format.
|
|
<DT id="3"><B>-h</B>, <B>--help</B>
|
|
|
|
<DD>
|
|
Display help text and exit.
|
|
<DT id="4"><B>-J</B>,<B> --json</B>
|
|
|
|
<DD>
|
|
Use JSON output format.
|
|
<DT id="5"><B>-n</B>,<B> --noheadings</B>
|
|
|
|
<DD>
|
|
Do not print a header line.
|
|
<DT id="6"><B>-o</B>,<B> --output </B><I>list</I>
|
|
|
|
<DD>
|
|
Specify which output columns to print. Use <B>--help</B>
|
|
to get a list of all supported columns.
|
|
The default list of columns may be extended if <I>list</I> is
|
|
specified in the format <B>+</B><I>list</I> (e.g. <B>lsmem -o +NODE</B>).
|
|
<DT id="7"><B>--output-all</B>
|
|
|
|
<DD>
|
|
Output all available columns.
|
|
<DT id="8"><B>-P</B>,<B> --pairs</B>
|
|
|
|
<DD>
|
|
Produce output in the form of key="value" pairs.
|
|
All potentially unsafe characters are hex-escaped (\x<code>).
|
|
<DT id="9"><B>-r</B>,<B> --raw</B>
|
|
|
|
<DD>
|
|
Produce output in raw format. All potentially unsafe characters are hex-escaped
|
|
(\x<code>).
|
|
<DT id="10"><B>-S</B>,<B> --split </B><I>list</I>
|
|
|
|
<DD>
|
|
Specify which columns (attributes) use to split memory blocks to ranges. The
|
|
supported columns are STATE, REMOVABLE, NODE and ZONES, or "none". The another columns are
|
|
silently ignored. For more details see DESCRIPTION above.
|
|
<DT id="11"><B>-s</B>,<B> --sysroot </B><I>directory</I>
|
|
|
|
<DD>
|
|
Gather memory data for a Linux instance other than the instance from which the
|
|
<B>lsmem</B> command is issued. The specified <I>directory</I> is the system
|
|
root of the Linux instance to be inspected.
|
|
<DT id="12"><B>-V</B>, <B>--version</B>
|
|
|
|
<DD>
|
|
Display version information and exit.
|
|
<DT id="13"><B>--summary</B>[=<I>when</I>]<DD>
|
|
This option controls summary lines output. The optional argument <I>when</I> can be
|
|
<B>never</B>, <B>always</B> or <B>only</B>. If the <I>when</I> argument is
|
|
omitted, it defaults to <B>"only"</B>. The summary output is suppressed for
|
|
<B>--raw</B>, <B>--pairs</B> and <B>--json</B>.
|
|
</DL>
|
|
<A NAME="lbAF"> </A>
|
|
<H2>AUTHOR</H2>
|
|
|
|
<B>lsmem</B>
|
|
|
|
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.
|
|
<A NAME="lbAG"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+chmem">chmem</A></B>(8)
|
|
|
|
<A NAME="lbAH"> </A>
|
|
<H2>AVAILABILITY</H2>
|
|
|
|
The <B>lsmem</B> command is part of the util-linux package and is available from
|
|
|
|
Linux Kernel Archive
|
|
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="14"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="15"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="16"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="17"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="18"><A HREF="#lbAF">AUTHOR</A><DD>
|
|
<DT id="19"><A HREF="#lbAG">SEE ALSO</A><DD>
|
|
<DT id="20"><A HREF="#lbAH">AVAILABILITY</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:18 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|