f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen<!--
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenCopyright © 2012 Oracle.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenAuthors:
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenDwight Engen <dwight.engen@oracle.com>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenThis library is free software; you can redistribute it and/or
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engenmodify it under the terms of the GNU Lesser General Public
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenLicense as published by the Free Software Foundation; either
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engenversion 2.1 of the License, or (at your option) any later version.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenThis library is distributed in the hope that it will be useful,
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engenbut WITHOUT ANY WARRANTY; without even the implied warranty of
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenLesser General Public License for more details.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenYou should have received a copy of the GNU Lesser General Public
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenLicense along with this library; if not, write to the Free Software
250b1eec71b074acdff1c5f6b5a1f0d7d2c20b77Stéphane GraberFoundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen-->
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
7f95145833bb24f54e037f73ecc37444d6635697Dwight Engen<!DOCTYPE refentry PUBLIC @docdtd@ [
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen<!ENTITY seealso SYSTEM "@builddir@/see_also.sgml">
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen]>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen<refentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <docinfo><date>@LXC_GENERATE_DATE@</date></docinfo>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refmeta>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refentrytitle>lxc-top</refentrytitle>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <manvolnum>1</manvolnum>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refmeta>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refnamediv>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refname>lxc-top</refname>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refpurpose>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen monitor container statistics
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refpurpose>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refnamediv>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refsynopsisdiv>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <cmdsynopsis>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <command>lxc-top</command>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <arg choice="opt">--help</arg>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <arg choice="opt">--delay <replaceable>delay</replaceable></arg>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <arg choice="opt">--sort <replaceable>sortby</replaceable></arg>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <arg choice="opt">--reverse</arg>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </cmdsynopsis>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refsynopsisdiv>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <title>Description</title>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <command>lxc-top</command> displays container statistics. The output
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen is updated every <replaceable>delay</replaceable> seconds, and is
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen ordered according to the <replaceable>sortby</replaceable> value
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen given. <command>lxc-top</command> will display as many containers as
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen can fit in your terminal. Press 'q' to quit. Press one of the sort
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen key letters to sort by that statistic. Pressing a sort key letter a
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen second time reverses the sort order.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <title>Options</title>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <variablelist>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <term>
1bc07a5b8dbaef4b6eb6d30a260e9c2153ed368bKATOH Yasufumi <option>-d, --delay <replaceable>delay</replaceable></option>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </term>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen Amount of time in seconds to delay between screen updates.
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen The default is 3 seconds.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <term>
1bc07a5b8dbaef4b6eb6d30a260e9c2153ed368bKATOH Yasufumi <option>-s, --sort <replaceable>sortby</replaceable></option>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </term>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen Sort the containers by name, cpu use, or memory use. The
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <replaceable>sortby</replaceable> argument should be one of
7dc6f6e279b35ccff88793afe991d34ecead57f3Dwight Engen the letters n,c,b,m,k to sort by name, cpu use, block I/O, memory,
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen or kernel memory use respectively. The default is 'n'.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <term>
1bc07a5b8dbaef4b6eb6d30a260e9c2153ed368bKATOH Yasufumi <option>-r, --reverse</option>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </term>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen Reverse the default sort order. By default, names sort in
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen ascending alphabetical order and values sort in descending
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen amounts (ie. largest value first).
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </variablelist>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <title>Example</title>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <variablelist>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <term>lxc-top --delay 1 --sort m</term>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen Display containers, updating every second, sorted by memory use.
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </listitem>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </varlistentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </variablelist>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <refsect1>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <title>Notes</title>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <para>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen For performance reasons the kernel does not account kernel memory use
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen unless a kernel memory limit is set. If a limit is not set, <command>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen lxc-top</command> will display kernel memory use as 0. If no containers
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen are being accounted, the KMem column will not be displayed. A limit can
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen be set by specifying
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <programlisting>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen lxc.cgroup.memory.kmem.limit_in_bytes = <replaceable>number</replaceable>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen </programlisting>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen in your container configuration file, see
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <citerefentry>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <refentrytitle>lxc.conf</refentrytitle>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen <manvolnum>5</manvolnum>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen </citerefentry>.
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen </para>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen </refsect1>
2752ecec3232c231469a2ad8513a5527fef66fd6Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen &seealso;
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <title>Author</title>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen <para>Dwight Engen <email>dwight.engen@oracle.com</email></para>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen </refsect1>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen</refentry>
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen<!-- Keep this comment at the end of the file
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenLocal variables:
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engenmode: sgml
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-omittag:t
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-shorttag:t
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-minimize-attributes:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-always-quote-attributes:t
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-indent-step:2
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-indent-data:t
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-parent-document:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-default-dtd-file:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-exposed-tags:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-local-catalogs:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engensgml-local-ecat-files:nil
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight EngenEnd:
f080ffd7d656fbd9505a8e8eb52a05d61355c677Dwight Engen-->