2009-09-11 02:13:33 -04:00
|
|
|
====================================================
|
2010-02-25 12:13:59 -05:00
|
|
|
tmux-mem-cpu-load
|
2009-09-11 02:13:33 -04:00
|
|
|
====================================================
|
|
|
|
----------------------------------------------------
|
2010-02-25 12:13:59 -05:00
|
|
|
CPU, RAM memory, and load monitor for use with tmux_
|
2009-09-11 02:13:33 -04:00
|
|
|
----------------------------------------------------
|
|
|
|
|
2013-06-13 22:07:07 -04:00
|
|
|
.. image:: https://travis-ci.org/thewtex/tmux-mem-cpu-load.png
|
|
|
|
:target: https://travis-ci.org/thewtex/tmux-mem-cpu-load
|
|
|
|
|
2009-09-11 02:13:33 -04:00
|
|
|
Description
|
|
|
|
===========
|
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
A simple, lightweight program provided for system monitoring in the *status*
|
|
|
|
line of **tmux**.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
The memory monitor displays the used and available memory.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
The CPU usage monitor outputs a percent CPU usage over all processors. It also
|
2010-08-01 11:17:42 -04:00
|
|
|
displays a textual bar graph of the current percent usage.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
The system load average is also displayed.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
Example output::
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
2885/7987MB [||||| ] 51.2% 2.11 2.35 2.44
|
|
|
|
|
|
|
|
^ ^ ^ ^ ^ ^ ^
|
|
|
|
| | | | | | |
|
2013-03-18 03:27:13 -04:00
|
|
|
1 2 3 4 5 6 7
|
2010-02-25 12:13:59 -05:00
|
|
|
|
2010-02-25 12:20:27 -05:00
|
|
|
1. Currently used memory.
|
|
|
|
2. Available memory.
|
|
|
|
3. CPU usage bar graph.
|
|
|
|
4. CPU usage percentage.
|
|
|
|
5. Load average for the past minute.
|
|
|
|
6. Load average for the past 5 minutes.
|
|
|
|
7. Load average for the past 15 minutes.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2013-05-03 14:28:12 -04:00
|
|
|
For `terminals with 256 color support`_, graded colors can be displayed by
|
|
|
|
passing the **--colors** flag.
|
|
|
|
|
2009-09-11 02:13:33 -04:00
|
|
|
|
|
|
|
Installation
|
|
|
|
============
|
|
|
|
|
|
|
|
Dependencies
|
|
|
|
------------
|
|
|
|
|
2013-06-09 22:55:08 -04:00
|
|
|
Currently, Linux and Mac OSX are supported.
|
2013-04-04 19:52:38 -04:00
|
|
|
|
2009-09-11 02:13:33 -04:00
|
|
|
Building
|
|
|
|
~~~~~~~~
|
|
|
|
|
2013-04-04 19:52:38 -04:00
|
|
|
* >= CMake_ -2.6
|
2009-09-11 02:13:33 -04:00
|
|
|
* C++ compiler (e.g. gcc/g++)
|
|
|
|
|
|
|
|
Download
|
|
|
|
--------
|
|
|
|
|
|
|
|
There are links to the source code at the `project homepage`_.
|
|
|
|
|
|
|
|
Build
|
|
|
|
-----
|
|
|
|
|
|
|
|
::
|
|
|
|
|
|
|
|
cd <source dir>
|
|
|
|
cmake .
|
|
|
|
make
|
|
|
|
|
|
|
|
Install
|
|
|
|
-------
|
|
|
|
|
|
|
|
::
|
|
|
|
|
|
|
|
su -
|
|
|
|
make install
|
|
|
|
logout
|
|
|
|
|
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
Configuring tmux_
|
2013-06-09 22:55:08 -04:00
|
|
|
=================
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:20:27 -05:00
|
|
|
Edit ``$HOME/.tmux.conf`` to display the program's output in *status-left* or
|
2010-02-25 12:13:59 -05:00
|
|
|
*status-right*. For example::
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
set -g status-interval 2
|
2013-05-03 14:28:12 -04:00
|
|
|
set -g status-left "#S #[fg=green,bg=black,bright]#(tmux-mem-cpu-load --colors 2)#[default]"
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
Note that the first argument to `tmux-mem-cpu-load` should be the same number
|
|
|
|
of seconds that *status-interval* is set at.
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-08-01 11:17:42 -04:00
|
|
|
An optional second argument is the number of bars in the bar graph, which
|
|
|
|
defaults to 10. This can, for instance, be set to the number of cores in a
|
|
|
|
multi-core system.
|
|
|
|
|
2009-09-11 02:13:33 -04:00
|
|
|
|
|
|
|
Author
|
|
|
|
======
|
|
|
|
|
|
|
|
Matt McCormick (thewtex) <matt@mmmccormick.com>
|
|
|
|
|
2013-06-09 22:57:37 -04:00
|
|
|
Contributions from:
|
|
|
|
|
|
|
|
* Justin Crawford <justinc@pci-online.net>
|
|
|
|
* krieiter <krieiter@gmail.com>
|
|
|
|
|
2009-09-11 02:13:33 -04:00
|
|
|
|
2010-02-25 12:13:59 -05:00
|
|
|
.. _tmux: http://tmux.sourceforge.net/
|
2013-04-04 19:52:38 -04:00
|
|
|
.. _CMake: http://www.cmake.org
|
2010-02-25 12:13:59 -05:00
|
|
|
.. _`project homepage`: http://github.com/thewtex/tmux-mem-cpu-load
|
2013-05-03 14:28:12 -04:00
|
|
|
.. _`terminals with 256 color support`: http://misc.flogisoft.com/bash/tip_colors_and_formatting#terminals_compatibility
|