mirror of
https://github.com/nicolargo/glances.git
synced 2024-09-11 12:47:14 +03:00
Fix typos
Found via `codespell -S ./venv,./glances/outputs,*.svg -L hart,bu,te,statics`
This commit is contained in:
parent
94d1e00692
commit
4046fbb18c
@ -7,7 +7,7 @@
|
|||||||
"""
|
"""
|
||||||
Script which downloads exe and wheel files hosted on AppVeyor:
|
Script which downloads exe and wheel files hosted on AppVeyor:
|
||||||
https://ci.appveyor.com/project/giampaolo/psutil
|
https://ci.appveyor.com/project/giampaolo/psutil
|
||||||
Copied and readapted from the original recipe of Ibarra Corretge'
|
Copied and re-adapted from the original recipe of Ibarra Corretge'
|
||||||
<saghul@gmail.com>:
|
<saghul@gmail.com>:
|
||||||
http://code.saghul.net/index.php/2015/09/09/
|
http://code.saghul.net/index.php/2015/09/09/
|
||||||
"""
|
"""
|
||||||
|
2
.github/ISSUE_TEMPLATE/bug_report.md
vendored
2
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@ -12,7 +12,7 @@ A clear and concise description of what the bug is.
|
|||||||
|
|
||||||
**To Reproduce**
|
**To Reproduce**
|
||||||
Steps to reproduce the behavior:
|
Steps to reproduce the behavior:
|
||||||
1. Start Glances with the followings options '...'
|
1. Start Glances with the following options '...'
|
||||||
2. Press the key '....'
|
2. Press the key '....'
|
||||||
3. See error
|
3. See error
|
||||||
|
|
||||||
|
46
NEWS.rst
46
NEWS.rst
@ -18,8 +18,8 @@ Enhancements:
|
|||||||
* Keybind(s) for modifying nice level #2081
|
* Keybind(s) for modifying nice level #2081
|
||||||
* [WEBUI] Reorganize help screen #2037
|
* [WEBUI] Reorganize help screen #2037
|
||||||
* Add a Json stdout option #2060
|
* Add a Json stdout option #2060
|
||||||
* Improve error message when export error occures
|
* Improve error message when export error occurs
|
||||||
* Improve error message when MQTT error occures
|
* Improve error message when MQTT error occurs
|
||||||
* Change the way core are displayed
|
* Change the way core are displayed
|
||||||
* Remove unused key in the process list
|
* Remove unused key in the process list
|
||||||
* Refactor top menu of the curse interface
|
* Refactor top menu of the curse interface
|
||||||
@ -126,7 +126,7 @@ Bugs corrected:
|
|||||||
* Failure to start on Apple M1 Max #1939
|
* Failure to start on Apple M1 Max #1939
|
||||||
* Influxdb2 via SSL #1934
|
* Influxdb2 via SSL #1934
|
||||||
* Update WebUI (security patch). Thanks to @notFloran.
|
* Update WebUI (security patch). Thanks to @notFloran.
|
||||||
* Swith from black <> white theme with the '9' hotkey - Related to issue #976
|
* Switch from black <> white theme with the '9' hotkey - Related to issue #976
|
||||||
* Fix: Docker plugin - Invalid IO stats with Arch Linux #1945
|
* Fix: Docker plugin - Invalid IO stats with Arch Linux #1945
|
||||||
* Bug Fix: Docker plugin - Network stats not being displayed #1944
|
* Bug Fix: Docker plugin - Network stats not being displayed #1944
|
||||||
* Fix Grafana CPU temperature panel #1954
|
* Fix Grafana CPU temperature panel #1954
|
||||||
@ -219,7 +219,7 @@ Enhancement and development requests:
|
|||||||
- Add caching for processing username and cmdline
|
- Add caching for processing username and cmdline
|
||||||
- Correct and improve refresh time method
|
- Correct and improve refresh time method
|
||||||
- Set refresh rate for global CPU percent
|
- Set refresh rate for global CPU percent
|
||||||
- Set the dafault refresh rate of system stats to 60 seconds
|
- Set the default refresh rate of system stats to 60 seconds
|
||||||
- Default refresh time for sensors is refresh rate * 2
|
- Default refresh time for sensors is refresh rate * 2
|
||||||
- Improve history perf
|
- Improve history perf
|
||||||
- Change main curses loop
|
- Change main curses loop
|
||||||
@ -301,7 +301,7 @@ Version 3.1.6.1
|
|||||||
|
|
||||||
Bugs corrected:
|
Bugs corrected:
|
||||||
|
|
||||||
* Glances crash after installing module for shown GPU informations on Windows 10 #1800
|
* Glances crash after installing module for shown GPU information on Windows 10 #1800
|
||||||
|
|
||||||
Version 3.1.6
|
Version 3.1.6
|
||||||
=============
|
=============
|
||||||
@ -359,7 +359,7 @@ Enhancements and new features:
|
|||||||
* Enhancement: RSS for containers enhancement #1694
|
* Enhancement: RSS for containers enhancement #1694
|
||||||
* exports: support rabbitmq amqps enhancement #1687
|
* exports: support rabbitmq amqps enhancement #1687
|
||||||
* Quick Look missing CPU Infos enhancement #1685
|
* Quick Look missing CPU Infos enhancement #1685
|
||||||
* Add amqps protocol suppport for rabbitmq export #1688
|
* Add amqps protocol support for rabbitmq export #1688
|
||||||
* Select host in Grafana json #1684
|
* Select host in Grafana json #1684
|
||||||
* Value for free disk space is counterintuative on ext file systems enhancement #644
|
* Value for free disk space is counterintuative on ext file systems enhancement #644
|
||||||
|
|
||||||
@ -403,7 +403,7 @@ Bugs corrected:
|
|||||||
* Disk IO stats missing after upgrade to 5.5.x kernel #1601
|
* Disk IO stats missing after upgrade to 5.5.x kernel #1601
|
||||||
* Glances don't want to run on Crostini (LXC Container, Debian 10, python 3.7.3) #1600
|
* Glances don't want to run on Crostini (LXC Container, Debian 10, python 3.7.3) #1600
|
||||||
* Kafka key name needs to be bytes #1593
|
* Kafka key name needs to be bytes #1593
|
||||||
* Cant start glances with glances --export mqtt #1581
|
* Can't start glances with glances --export mqtt #1581
|
||||||
* [WEBUI] AMP plugins is not displayed correctly in the Web Interface #1574
|
* [WEBUI] AMP plugins is not displayed correctly in the Web Interface #1574
|
||||||
* Unhandled AttributeError when no config files found #1569
|
* Unhandled AttributeError when no config files found #1569
|
||||||
* Glances writing lots of Docker Error message in logs file enhancement #1561
|
* Glances writing lots of Docker Error message in logs file enhancement #1561
|
||||||
@ -641,7 +641,7 @@ Graph:
|
|||||||
# generate_every to a non zero value corresponding to the seconds between
|
# generate_every to a non zero value corresponding to the seconds between
|
||||||
# two generation. Set it to 0 to disable graph auto generation.
|
# two generation. Set it to 0 to disable graph auto generation.
|
||||||
generate_every=60
|
generate_every=60
|
||||||
# See followings configuration keys definitions in the Pygal lib documentation
|
# See following configuration keys definitions in the Pygal lib documentation
|
||||||
# http://pygal.org/en/stable/documentation/index.html
|
# http://pygal.org/en/stable/documentation/index.html
|
||||||
width=800
|
width=800
|
||||||
height=600
|
height=600
|
||||||
@ -701,7 +701,7 @@ Bugs corrected:
|
|||||||
* glances_network `OSError: [Errno 19] No such device` (issue #1106)
|
* glances_network `OSError: [Errno 19] No such device` (issue #1106)
|
||||||
* GPU plugin. <class 'TypeError'>: ... not JSON serializable"> (issue #1112)
|
* GPU plugin. <class 'TypeError'>: ... not JSON serializable"> (issue #1112)
|
||||||
* PermissionError on macOS (issue #1120)
|
* PermissionError on macOS (issue #1120)
|
||||||
* Cant move up or down in glances --browser (issue #1113)
|
* Can't move up or down in glances --browser (issue #1113)
|
||||||
* Unable to give aliases to or hide network interfaces and disks (issue #1126)
|
* Unable to give aliases to or hide network interfaces and disks (issue #1126)
|
||||||
* `UnicodeDecodeError` on mountpoints with non-breaking spaces (issue #1128)
|
* `UnicodeDecodeError` on mountpoints with non-breaking spaces (issue #1128)
|
||||||
|
|
||||||
@ -758,7 +758,7 @@ Bugs corrected:
|
|||||||
* On Windows --export-statsd terminates immediately and does not export (issue #1067)
|
* On Windows --export-statsd terminates immediately and does not export (issue #1067)
|
||||||
* Glances v2.8.7 issues with Curses UI on Android (issue #1053)
|
* Glances v2.8.7 issues with Curses UI on Android (issue #1053)
|
||||||
* Fails to start, OSError in sensors_temperatures (issue #1057)
|
* Fails to start, OSError in sensors_temperatures (issue #1057)
|
||||||
* Crashs after long time running the glances --browser (issue #1059)
|
* Crashes after long time running the glances --browser (issue #1059)
|
||||||
* Sensor values don't refresh since psutil backend (issue #1061)
|
* Sensor values don't refresh since psutil backend (issue #1061)
|
||||||
* glances-version.db Permission denied (issue #1066)
|
* glances-version.db Permission denied (issue #1066)
|
||||||
|
|
||||||
@ -857,7 +857,7 @@ Enhancements and new features:
|
|||||||
* Not compatible with the new Docker API 2.0 (Docker 1.13) (issue #1000)
|
* Not compatible with the new Docker API 2.0 (Docker 1.13) (issue #1000)
|
||||||
* Add ZeroMQ exporter (issue #939)
|
* Add ZeroMQ exporter (issue #939)
|
||||||
* Add CouchDB exporter (issue #928)
|
* Add CouchDB exporter (issue #928)
|
||||||
* Add hotspot Wifi informations (issue #937)
|
* Add hotspot Wifi information (issue #937)
|
||||||
* Add default interface speed and automatic rate thresolds (issue #718)
|
* Add default interface speed and automatic rate thresolds (issue #718)
|
||||||
* Highlight max stats in the processes list (issue #878)
|
* Highlight max stats in the processes list (issue #878)
|
||||||
* Docker alerts and actions (issue #875)
|
* Docker alerts and actions (issue #875)
|
||||||
@ -880,8 +880,8 @@ Version 2.7.1
|
|||||||
|
|
||||||
Bugs corrected:
|
Bugs corrected:
|
||||||
|
|
||||||
* AMP plugin crashs on start with Python 3 (issue #917)
|
* AMP plugin crashes on start with Python 3 (issue #917)
|
||||||
* Ports plugin crashs on start with Python 3 (issue #918)
|
* Ports plugin crashes on start with Python 3 (issue #918)
|
||||||
|
|
||||||
Version 2.7
|
Version 2.7
|
||||||
===========
|
===========
|
||||||
@ -902,7 +902,7 @@ Enhancements and new features:
|
|||||||
* Add a new "Ports scanner" plugin (issue #734)
|
* Add a new "Ports scanner" plugin (issue #734)
|
||||||
* Add a new IRQ monitoring plugin (issue #911)
|
* Add a new IRQ monitoring plugin (issue #911)
|
||||||
* Improve IP plugin to display public IP address (issue #646)
|
* Improve IP plugin to display public IP address (issue #646)
|
||||||
* CPU additionnal stats monitoring: Context switch, Interrupts... (issue #810)
|
* CPU additional stats monitoring: Context switch, Interrupts... (issue #810)
|
||||||
* Filter processes by others stats (username) (issue #748)
|
* Filter processes by others stats (username) (issue #748)
|
||||||
* [Folders] Differentiate permission issue and non-existence of a directory (issue #828)
|
* [Folders] Differentiate permission issue and non-existence of a directory (issue #828)
|
||||||
* [Web UI] Add cpu name in quicklook plugin (issue #825)
|
* [Web UI] Add cpu name in quicklook plugin (issue #825)
|
||||||
@ -1042,10 +1042,10 @@ Enhancements and new features:
|
|||||||
Bugs corrected:
|
Bugs corrected:
|
||||||
|
|
||||||
* The WebUI displays bad sensors stats (issue #632)
|
* The WebUI displays bad sensors stats (issue #632)
|
||||||
* Filter processes crashs with a bad regular expression pattern (issue #665)
|
* Filter processes crashes with a bad regular expression pattern (issue #665)
|
||||||
* Error with IP plugin (issue #651)
|
* Error with IP plugin (issue #651)
|
||||||
* Crach with Docker plugin (issue #649)
|
* Crach with Docker plugin (issue #649)
|
||||||
* Docker plugin crashs with webserver mode (issue #654)
|
* Docker plugin crashes with webserver mode (issue #654)
|
||||||
* Infrequently crashing due to assert (issue #623)
|
* Infrequently crashing due to assert (issue #623)
|
||||||
* Value for free disk space is counterintuative on ext file systems (issue #644)
|
* Value for free disk space is counterintuative on ext file systems (issue #644)
|
||||||
* Try/catch for unexpected psutil.NoSuchProcess: process no longer exists (issue #432)
|
* Try/catch for unexpected psutil.NoSuchProcess: process no longer exists (issue #432)
|
||||||
@ -1125,7 +1125,7 @@ Enhancements and new features:
|
|||||||
* Add InfluxDB export module (--export-influxdb) (issue #455)
|
* Add InfluxDB export module (--export-influxdb) (issue #455)
|
||||||
* Add StatsD export module (--export-statsd) (issue #465)
|
* Add StatsD export module (--export-statsd) (issue #465)
|
||||||
* Refactor export module (CSV export option is now --export-csv). It is now possible to export stats from the Glances client mode (issue #463)
|
* Refactor export module (CSV export option is now --export-csv). It is now possible to export stats from the Glances client mode (issue #463)
|
||||||
* The Web inteface is now based on Bootstrap / RWD grid (issue #417, #366 and #461) Thanks to Nicolas Hart @nclsHart
|
* The Web interface is now based on Bootstrap / RWD grid (issue #417, #366 and #461) Thanks to Nicolas Hart @nclsHart
|
||||||
* It is now possible, through the configuration file, to define if an alarm should be logged or not (using the _log option) (issue #437)
|
* It is now possible, through the configuration file, to define if an alarm should be logged or not (using the _log option) (issue #437)
|
||||||
* You can now set alarm for Disk IO
|
* You can now set alarm for Disk IO
|
||||||
* API: add getAllLimits and getAllViews methods (issue #481) and allow CORS request (issue #479)
|
* API: add getAllLimits and getAllViews methods (issue #481) and allow CORS request (issue #479)
|
||||||
@ -1181,7 +1181,7 @@ Version 2.1.1
|
|||||||
|
|
||||||
Enhancement:
|
Enhancement:
|
||||||
|
|
||||||
* Automaticaly compute top processes number for the current screen (issue #408)
|
* Automatically compute top processes number for the current screen (issue #408)
|
||||||
* CPU and Memory footprint optimization (issue #401)
|
* CPU and Memory footprint optimization (issue #401)
|
||||||
|
|
||||||
Bugs corrected:
|
Bugs corrected:
|
||||||
@ -1190,7 +1190,7 @@ Bugs corrected:
|
|||||||
* Process no longer exists (issue #421)
|
* Process no longer exists (issue #421)
|
||||||
* Error with Glances Client with Python 3.4.1 (issue #419)
|
* Error with Glances Client with Python 3.4.1 (issue #419)
|
||||||
* TypeError: memory_maps() takes exactly 2 arguments (issue #413)
|
* TypeError: memory_maps() takes exactly 2 arguments (issue #413)
|
||||||
* No filesystem informations since Glances 2.0 bug enhancement (issue #381)
|
* No filesystem information since Glances 2.0 bug enhancement (issue #381)
|
||||||
|
|
||||||
Version 2.1
|
Version 2.1
|
||||||
===========
|
===========
|
||||||
@ -1200,7 +1200,7 @@ Version 2.1
|
|||||||
The pattern could be defined from the command line (-f <pattern>)
|
The pattern could be defined from the command line (-f <pattern>)
|
||||||
or by pressing the ENTER key in the curse interface.
|
or by pressing the ENTER key in the curse interface.
|
||||||
For the moment, process filter feature is only available in standalone mode.
|
For the moment, process filter feature is only available in standalone mode.
|
||||||
* Add extended processes informations for top process
|
* Add extended processes information for top process
|
||||||
Top process stats availables: CPU affinity, extended memory information (shared, text, lib, datat, dirty, swap), open threads/files and TCP/UDP network sessions, IO nice level
|
Top process stats availables: CPU affinity, extended memory information (shared, text, lib, datat, dirty, swap), open threads/files and TCP/UDP network sessions, IO nice level
|
||||||
For the moment, extended processes stats are only available in standalone mode.
|
For the moment, extended processes stats are only available in standalone mode.
|
||||||
* Add --process-short-name tag and '/' key to switch between short/command line
|
* Add --process-short-name tag and '/' key to switch between short/command line
|
||||||
@ -1396,7 +1396,7 @@ Version 1.6.1
|
|||||||
* Key 'u' shows cumulative net traffic
|
* Key 'u' shows cumulative net traffic
|
||||||
* Work in improving autoUnit
|
* Work in improving autoUnit
|
||||||
* Take into account the number of core in the CPU process limit
|
* Take into account the number of core in the CPU process limit
|
||||||
* API improvment add time_since_update for disk, process_disk and network
|
* API improvement add time_since_update for disk, process_disk and network
|
||||||
* Improve help display
|
* Improve help display
|
||||||
* Add more dummy FS to the ignore list
|
* Add more dummy FS to the ignore list
|
||||||
* Code refactory: psutil < 0.4.1 is deprecated (Thk to Alessio)
|
* Code refactory: psutil < 0.4.1 is deprecated (Thk to Alessio)
|
||||||
@ -1504,7 +1504,7 @@ Version 1.3.7
|
|||||||
=============
|
=============
|
||||||
|
|
||||||
* Display (if terminal space is available) an alerts history (logs)
|
* Display (if terminal space is available) an alerts history (logs)
|
||||||
* Add a limits classe to manage stats limits
|
* Add a limits class to manage stats limits
|
||||||
* Manage black and white console (issue #31)
|
* Manage black and white console (issue #31)
|
||||||
|
|
||||||
Version 1.3.6
|
Version 1.3.6
|
||||||
@ -1533,7 +1533,7 @@ Version 1.3.4
|
|||||||
Version 1.3.3
|
Version 1.3.3
|
||||||
=============
|
=============
|
||||||
|
|
||||||
* Automatically swith between process short and long name
|
* Automatically switch between process short and long name
|
||||||
* Center the host / system information
|
* Center the host / system information
|
||||||
* Always put the hour/date in the bottom/right
|
* Always put the hour/date in the bottom/right
|
||||||
* Correct a bug if there is a lot of Disk/IO
|
* Correct a bug if there is a lot of Disk/IO
|
||||||
|
@ -198,7 +198,7 @@ Get the Glances container:
|
|||||||
|
|
||||||
docker pull nicolargo/glances:alpine-latest-full
|
docker pull nicolargo/glances:alpine-latest-full
|
||||||
|
|
||||||
The followings tags are availables:
|
The following tags are availables:
|
||||||
|
|
||||||
- *alpine-latest-full* for a full Alpine Glances image (latest release) with all dependencies
|
- *alpine-latest-full* for a full Alpine Glances image (latest release) with all dependencies
|
||||||
- *latest-full* for a full Debian Glances image (latest release) with all dependencies
|
- *latest-full* for a full Debian Glances image (latest release) with all dependencies
|
||||||
@ -414,7 +414,7 @@ or in a CSV format thanks to the stdout-csv option:
|
|||||||
2018-12-08 22:04:23 CEST,5.4,5949136896,4,1.04,0.99,1.04
|
2018-12-08 22:04:23 CEST,5.4,5949136896,4,1.04,0.99,1.04
|
||||||
...
|
...
|
||||||
|
|
||||||
or in a JSON format thanks to the stdout-json option (attibute not supported in this mode in order to have a real JSON object in output):
|
or in a JSON format thanks to the stdout-json option (attribute not supported in this mode in order to have a real JSON object in output):
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
|
|
||||||
|
@ -181,7 +181,7 @@ public_ip_disabled=False
|
|||||||
# Need to create an aacount: https://censys.io/login
|
# Need to create an aacount: https://censys.io/login
|
||||||
censys_url=https://search.censys.io/api
|
censys_url=https://search.censys.io/api
|
||||||
# Get your own credential here: https://search.censys.io/account/api
|
# Get your own credential here: https://search.censys.io/account/api
|
||||||
# Enter your creadential and uncomment the following lines
|
# Enter your credential and uncomment the following lines
|
||||||
#censys_username=<censys_api_id>
|
#censys_username=<censys_api_id>
|
||||||
#censys_password=<censys_secret>
|
#censys_password=<censys_secret>
|
||||||
# List of fields to be displayed in user interface (comma separated)
|
# List of fields to be displayed in user interface (comma separated)
|
||||||
@ -249,7 +249,7 @@ disable=False
|
|||||||
# * careful: optional careful threshold (in MB)
|
# * careful: optional careful threshold (in MB)
|
||||||
# * warning: optional warning threshold (in MB)
|
# * warning: optional warning threshold (in MB)
|
||||||
# * critical: optional critical threshold (in MB)
|
# * critical: optional critical threshold (in MB)
|
||||||
# * refresh: interval in second between two refreshs
|
# * refresh: interval in second between two refreshes
|
||||||
#folder_1_path=/tmp
|
#folder_1_path=/tmp
|
||||||
#folder_1_careful=2500
|
#folder_1_careful=2500
|
||||||
#folder_1_warning=3000
|
#folder_1_warning=3000
|
||||||
@ -372,7 +372,7 @@ port_default_gateway=True
|
|||||||
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
||||||
# web_x_description is optional (if not set, define to URL)
|
# web_x_description is optional (if not set, define to URL)
|
||||||
# web_x_timeout is optional and overwrite the default timeout value
|
# web_x_timeout is optional and overwrite the default timeout value
|
||||||
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximatively)
|
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximately)
|
||||||
#
|
#
|
||||||
#web_1_url=https://blog.nicolargo.com
|
#web_1_url=https://blog.nicolargo.com
|
||||||
#web_1_description=My Blog
|
#web_1_description=My Blog
|
||||||
@ -385,10 +385,10 @@ port_default_gateway=True
|
|||||||
|
|
||||||
[docker]
|
[docker]
|
||||||
disable=False
|
disable=False
|
||||||
# Only show specific containers (comma separeted list of container name or regular expression)
|
# Only show specific containers (comma separated list of container name or regular expression)
|
||||||
# Comment this line to display all containers (default configuration)
|
# Comment this line to display all containers (default configuration)
|
||||||
#show=telegraf
|
#show=telegraf
|
||||||
# Hide some containers (comma separeted list of container name or regular expression)
|
# Hide some containers (comma separated list of container name or regular expression)
|
||||||
# Comment this line to display all containers (default configuration)
|
# Comment this line to display all containers (default configuration)
|
||||||
#hide=telegraf
|
#hide=telegraf
|
||||||
# Define the maximum docker size name (default is 20 chars)
|
# Define the maximum docker size name (default is 20 chars)
|
||||||
@ -453,7 +453,7 @@ path=/tmp
|
|||||||
# generate_every to a non zero value corresponding to the seconds between
|
# generate_every to a non zero value corresponding to the seconds between
|
||||||
# two generation. Set it to 0 to disable graph auto generation.
|
# two generation. Set it to 0 to disable graph auto generation.
|
||||||
generate_every=60
|
generate_every=60
|
||||||
# See followings configuration keys definitions in the Pygal lib documentation
|
# See following configuration keys definitions in the Pygal lib documentation
|
||||||
# http://pygal.org/en/stable/documentation/index.html
|
# http://pygal.org/en/stable/documentation/index.html
|
||||||
width=800
|
width=800
|
||||||
height=600
|
height=600
|
||||||
@ -478,7 +478,7 @@ db=glances
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
@ -498,7 +498,7 @@ token=EjFUTWe8U-MIseEAkaVIgVnej_TrnbdvEcRkaB1imstW7gapSqy6_6-8XD-yd51V0zUUpDy-kA
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
|
@ -238,7 +238,7 @@ disable=False
|
|||||||
# * careful: optional careful threshold (in MB)
|
# * careful: optional careful threshold (in MB)
|
||||||
# * warning: optional warning threshold (in MB)
|
# * warning: optional warning threshold (in MB)
|
||||||
# * critical: optional critical threshold (in MB)
|
# * critical: optional critical threshold (in MB)
|
||||||
# * refresh: interval in second between two refreshs
|
# * refresh: interval in second between two refreshes
|
||||||
#folder_1_path=/tmp
|
#folder_1_path=/tmp
|
||||||
#folder_1_careful=2500
|
#folder_1_careful=2500
|
||||||
#folder_1_warning=3000
|
#folder_1_warning=3000
|
||||||
@ -359,7 +359,7 @@ port_default_gateway=True
|
|||||||
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
||||||
# web_x_description is optional (if not set, define to URL)
|
# web_x_description is optional (if not set, define to URL)
|
||||||
# web_x_timeout is optional and overwrite the default timeout value
|
# web_x_timeout is optional and overwrite the default timeout value
|
||||||
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximatively)
|
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximately)
|
||||||
#
|
#
|
||||||
#web_1_url=https://blog.nicolargo.com
|
#web_1_url=https://blog.nicolargo.com
|
||||||
#web_1_description=My Blog
|
#web_1_description=My Blog
|
||||||
@ -372,10 +372,10 @@ port_default_gateway=True
|
|||||||
|
|
||||||
[docker]
|
[docker]
|
||||||
disable=False
|
disable=False
|
||||||
# Only show specific containers (comma separeted list of container name or regular expression)
|
# Only show specific containers (comma separated list of container name or regular expression)
|
||||||
# Comment this line to display all containers (default configuration)
|
# Comment this line to display all containers (default configuration)
|
||||||
#show=telegraf
|
#show=telegraf
|
||||||
# Hide some containers (comma separeted list of container name or regular expression)
|
# Hide some containers (comma separated list of container name or regular expression)
|
||||||
# Comment this line to display all containers (default configuration)
|
# Comment this line to display all containers (default configuration)
|
||||||
#hide=telegraf
|
#hide=telegraf
|
||||||
# Define the maximum docker size name (default is 20 chars)
|
# Define the maximum docker size name (default is 20 chars)
|
||||||
@ -440,7 +440,7 @@ path=/tmp
|
|||||||
# generate_every to a non zero value corresponding to the seconds between
|
# generate_every to a non zero value corresponding to the seconds between
|
||||||
# two generation. Set it to 0 to disable graph auto generation.
|
# two generation. Set it to 0 to disable graph auto generation.
|
||||||
generate_every=60
|
generate_every=60
|
||||||
# See followings configuration keys definitions in the Pygal lib documentation
|
# See following configuration keys definitions in the Pygal lib documentation
|
||||||
# http://pygal.org/en/stable/documentation/index.html
|
# http://pygal.org/en/stable/documentation/index.html
|
||||||
width=800
|
width=800
|
||||||
height=600
|
height=600
|
||||||
@ -465,7 +465,7 @@ db=glances
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
@ -485,7 +485,7 @@ token=EjFUTWe8U-MIseEAkaVIgVnej_TrnbdvEcRkaB1imstW7gapSqy6_6-8XD-yd51V0zUUpDy-kA
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
|
@ -40,7 +40,7 @@ critical is reached:
|
|||||||
|
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
Use && as seprator for multiple commands
|
Use && as separator for multiple commands
|
||||||
|
|
||||||
|
|
||||||
Within ``/etc/glances/actions.d/fs-critical.py``:
|
Within ``/etc/glances/actions.d/fs-critical.py``:
|
||||||
|
@ -10,7 +10,7 @@ dynamically.
|
|||||||
|
|
||||||
You can display:
|
You can display:
|
||||||
|
|
||||||
- bytes per second (default behavor / Bytes/s, KBytes/s, MBytes/s, etc)
|
- bytes per second (default behavior / Bytes/s, KBytes/s, MBytes/s, etc)
|
||||||
- requests per second (using --diskio-iops option or *B* hotkey)
|
- requests per second (using --diskio-iops option or *B* hotkey)
|
||||||
|
|
||||||
There is no alert on this information.
|
There is no alert on this information.
|
||||||
|
@ -21,11 +21,11 @@ under the ``[docker]`` section:
|
|||||||
|
|
||||||
[docker]
|
[docker]
|
||||||
disable=False
|
disable=False
|
||||||
# Only show specific containers (comma separeted list of container name or regular expression)
|
# Only show specific containers (comma separated list of container name or regular expression)
|
||||||
show=thiscontainer,andthisone,andthoseones.*
|
show=thiscontainer,andthisone,andthoseones.*
|
||||||
# Hide some containers (comma separeted list of container name or regular expression)
|
# Hide some containers (comma separated list of container name or regular expression)
|
||||||
hide=donotshowthisone,andthose.*
|
hide=donotshowthisone,andthose.*
|
||||||
# Show only specific containers (comma separeted list of container name or regular expression)
|
# Show only specific containers (comma separated list of container name or regular expression)
|
||||||
#show=showthisone,andthose.*
|
#show=showthisone,andthose.*
|
||||||
# Define the maximum docker size name (default is 20 chars)
|
# Define the maximum docker size name (default is 20 chars)
|
||||||
max_name_size=20
|
max_name_size=20
|
||||||
|
@ -50,7 +50,7 @@ configuration file.
|
|||||||
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
# web_x_url is the URL to monitor (example: http://my.site.com/folder)
|
||||||
# web_x_description is optional (if not set, define to URL)
|
# web_x_description is optional (if not set, define to URL)
|
||||||
# web_x_timeout is optional and overwrite the default timeout value
|
# web_x_timeout is optional and overwrite the default timeout value
|
||||||
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximatively)
|
# web_x_rtt_warning is optional and defines the warning respond time in ms (approximately)
|
||||||
#
|
#
|
||||||
web_1_url=https://blog.nicolargo.com
|
web_1_url=https://blog.nicolargo.com
|
||||||
web_1_description=My Blog
|
web_1_description=My Blog
|
||||||
|
@ -19,7 +19,7 @@ sparkline using 'S' hot key or --sparkline command line option (need the
|
|||||||
sparklines Python lib on your system). Please be aware that sparklines use
|
sparklines Python lib on your system). Please be aware that sparklines use
|
||||||
the Glances history and will not be available if the history is disabled
|
the Glances history and will not be available if the history is disabled
|
||||||
from the command line. For the moment sparkline is not available in
|
from the command line. For the moment sparkline is not available in
|
||||||
client/server mode (see isse ).
|
client/server mode (see issue ).
|
||||||
|
|
||||||
.. image:: ../_static/sparkline.png
|
.. image:: ../_static/sparkline.png
|
||||||
|
|
||||||
|
18
docs/api.rst
18
docs/api.rst
@ -15,7 +15,7 @@ GET API status
|
|||||||
--------------
|
--------------
|
||||||
|
|
||||||
This entry point should be used to check the API status.
|
This entry point should be used to check the API status.
|
||||||
It will return nothing but a 200 return code if everythin is OK.
|
It will return nothing but a 200 return code if everything is OK.
|
||||||
|
|
||||||
Get the Rest API status::
|
Get the Rest API status::
|
||||||
|
|
||||||
@ -109,7 +109,7 @@ Get a specific field::
|
|||||||
# curl http://localhost:61208/api/3/amps/name
|
# curl http://localhost:61208/api/3/amps/name
|
||||||
{"name": ["Dropbox", "Python", "Conntrack", "Nginx", "Systemd", "SystemV"]}
|
{"name": ["Dropbox", "Python", "Conntrack", "Nginx", "Systemd", "SystemV"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/amps/name/Dropbox
|
# curl http://localhost:61208/api/3/amps/name/Dropbox
|
||||||
{"Dropbox": [{"count": 0,
|
{"Dropbox": [{"count": 0,
|
||||||
@ -213,7 +213,7 @@ Get a specific field::
|
|||||||
# curl http://localhost:61208/api/3/diskio/disk_name
|
# curl http://localhost:61208/api/3/diskio/disk_name
|
||||||
{"disk_name": ["sda", "sda1", "sda2", "sda5", "dm-0", "dm-1"]}
|
{"disk_name": ["sda", "sda1", "sda2", "sda5", "dm-0", "dm-1"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/diskio/disk_name/sda
|
# curl http://localhost:61208/api/3/diskio/disk_name/sda
|
||||||
{"sda": [{"disk_name": "sda",
|
{"sda": [{"disk_name": "sda",
|
||||||
@ -287,7 +287,7 @@ Get a specific field::
|
|||||||
# curl http://localhost:61208/api/3/fs/mnt_point
|
# curl http://localhost:61208/api/3/fs/mnt_point
|
||||||
{"mnt_point": ["/", "/var/snap/firefox/common/host-hunspell"]}
|
{"mnt_point": ["/", "/var/snap/firefox/common/host-hunspell"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/fs/mnt_point//
|
# curl http://localhost:61208/api/3/fs/mnt_point//
|
||||||
{"/": [{"device_name": "/dev/mapper/ubuntu--gnome--vg-root",
|
{"/": [{"device_name": "/dev/mapper/ubuntu--gnome--vg-root",
|
||||||
@ -460,7 +460,7 @@ Get a specific field::
|
|||||||
"vboxnet0",
|
"vboxnet0",
|
||||||
"mpqemubr0"]}
|
"mpqemubr0"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/network/interface_name/lo
|
# curl http://localhost:61208/api/3/network/interface_name/lo
|
||||||
{"lo": [{"alias": None,
|
{"lo": [{"alias": None,
|
||||||
@ -542,7 +542,7 @@ Get a specific field::
|
|||||||
# curl http://localhost:61208/api/3/ports/host
|
# curl http://localhost:61208/api/3/ports/host
|
||||||
{"host": ["192.168.0.254"]}
|
{"host": ["192.168.0.254"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/ports/host/192.168.0.254
|
# curl http://localhost:61208/api/3/ports/host/192.168.0.254
|
||||||
{"192.168.0.254": [{"description": "DefaultGateway",
|
{"192.168.0.254": [{"description": "DefaultGateway",
|
||||||
@ -971,7 +971,7 @@ Get a specific field::
|
|||||||
535974,
|
535974,
|
||||||
536119]}
|
536119]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/processlist/pid/477633
|
# curl http://localhost:61208/api/3/processlist/pid/477633
|
||||||
{"477633": [{"cmdline": ["/snap/firefox/1877/usr/lib/firefox/firefox"],
|
{"477633": [{"cmdline": ["/snap/firefox/1877/usr/lib/firefox/firefox"],
|
||||||
@ -1108,7 +1108,7 @@ Get a specific field::
|
|||||||
"SODIMM",
|
"SODIMM",
|
||||||
"BAT BAT0"]}
|
"BAT BAT0"]}
|
||||||
|
|
||||||
Get a specific item when field matchs the given value::
|
Get a specific item when field matches the given value::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/sensors/label/acpitz 1
|
# curl http://localhost:61208/api/3/sensors/label/acpitz 1
|
||||||
{"acpitz 1": [{"critical": 105,
|
{"acpitz 1": [{"critical": 105,
|
||||||
@ -1151,7 +1151,7 @@ GET all stats
|
|||||||
Get all Glances stats::
|
Get all Glances stats::
|
||||||
|
|
||||||
# curl http://localhost:61208/api/3/all
|
# curl http://localhost:61208/api/3/all
|
||||||
Return a very big dictionnary (avoid using this request, performances will be poor)...
|
Return a very big dictionary (avoid using this request, performances will be poor)...
|
||||||
|
|
||||||
GET stats history
|
GET stats history
|
||||||
-----------------
|
-----------------
|
||||||
|
@ -17,7 +17,7 @@ starts every time the 'g' key is pressed in the CLI interface.
|
|||||||
# generate_every to a non zero value corresponding to the seconds between
|
# generate_every to a non zero value corresponding to the seconds between
|
||||||
# two generation. Set it to 0 to disable graph auto generation.
|
# two generation. Set it to 0 to disable graph auto generation.
|
||||||
generate_every=60
|
generate_every=60
|
||||||
# See followings configuration keys definitions in the Pygal lib documentation
|
# See following configuration keys definitions in the Pygal lib documentation
|
||||||
# http://pygal.org/en/stable/documentation/index.html
|
# http://pygal.org/en/stable/documentation/index.html
|
||||||
width=800
|
width=800
|
||||||
height=600
|
height=600
|
||||||
|
@ -56,7 +56,7 @@ following:
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
@ -98,7 +98,7 @@ following:
|
|||||||
# => foo.mem
|
# => foo.mem
|
||||||
# You can also use dynamic values
|
# You can also use dynamic values
|
||||||
#prefix=foo
|
#prefix=foo
|
||||||
# Followings tags will be added for all measurements
|
# Following tags will be added for all measurements
|
||||||
# You can also use dynamic values.
|
# You can also use dynamic values.
|
||||||
# Note: hostname is always added as a tag
|
# Note: hostname is always added as a tag
|
||||||
#tags=foo:bar,spam:eggs,domain:`domainname`
|
#tags=foo:bar,spam:eggs,domain:`domainname`
|
||||||
|
@ -25,5 +25,5 @@ and run Glances with:
|
|||||||
$ glances --export mqtt
|
$ glances --export mqtt
|
||||||
|
|
||||||
The topic_structure field aims at configuring the way stats are exported to MQTT (see #1798):
|
The topic_structure field aims at configuring the way stats are exported to MQTT (see #1798):
|
||||||
- per-metric: one event per metric (default behavor)
|
- per-metric: one event per metric (default behavior)
|
||||||
- per-plugin: one event per plugin
|
- per-plugin: one event per plugin
|
||||||
|
@ -47,7 +47,7 @@ or in a CSV format thanks to the stdout-csv option:
|
|||||||
2018-12-08 22:04:23 CEST,5.4,5949136896,4,1.04,0.99,1.04
|
2018-12-08 22:04:23 CEST,5.4,5949136896,4,1.04,0.99,1.04
|
||||||
...
|
...
|
||||||
|
|
||||||
or as a JSON format thanks to the stdout-json option (attibute not supported in this mode):
|
or as a JSON format thanks to the stdout-json option (attribute not supported in this mode):
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
|
|
||||||
@ -124,7 +124,7 @@ When the list is displayed, you can navigate through the Glances servers with
|
|||||||
up/down keys. It is also possible to sort the server using:
|
up/down keys. It is also possible to sort the server using:
|
||||||
- '1' is normal (do not sort)
|
- '1' is normal (do not sort)
|
||||||
- '2' is using sorting with ascending order (ONLINE > SNMP > PROTECTED > OFFLINE > UNKNOWN)
|
- '2' is using sorting with ascending order (ONLINE > SNMP > PROTECTED > OFFLINE > UNKNOWN)
|
||||||
- '3' is using sorting with descending order (UNKNOW > OFFLINE > PROTECTED > SNMP > ONLINE)
|
- '3' is using sorting with descending order (UNKNOWN > OFFLINE > PROTECTED > SNMP > ONLINE)
|
||||||
|
|
||||||
SNMP
|
SNMP
|
||||||
^^^^
|
^^^^
|
||||||
|
@ -134,7 +134,7 @@ def start(config, args):
|
|||||||
snapshot_end = tracemalloc.take_snapshot()
|
snapshot_end = tracemalloc.take_snapshot()
|
||||||
snapshot_diff = snapshot_end.compare_to(snapshot_begin, 'filename')
|
snapshot_diff = snapshot_end.compare_to(snapshot_begin, 'filename')
|
||||||
memory_leak = sum([s.size_diff for s in snapshot_diff])
|
memory_leak = sum([s.size_diff for s in snapshot_diff])
|
||||||
print("Memory comsumption: {0:.1f}KB (see log for details)".format(memory_leak / 1000))
|
print("Memory consumption: {0:.1f}KB (see log for details)".format(memory_leak / 1000))
|
||||||
logger.info("Memory consumption (top 5):")
|
logger.info("Memory consumption (top 5):")
|
||||||
for stat in snapshot_diff[:5]:
|
for stat in snapshot_diff[:5]:
|
||||||
logger.info(stat)
|
logger.info(stat)
|
||||||
|
@ -53,7 +53,7 @@ class AmpsList(object):
|
|||||||
)
|
)
|
||||||
|
|
||||||
header = "glances_"
|
header = "glances_"
|
||||||
# For each AMP scrip, call the load_config method
|
# For each AMP script, call the load_config method
|
||||||
for s in self.config.sections():
|
for s in self.config.sections():
|
||||||
if s.startswith("amp_"):
|
if s.startswith("amp_"):
|
||||||
# An AMP section exists in the configuration file
|
# An AMP section exists in the configuration file
|
||||||
|
@ -32,7 +32,7 @@ if zeroconf_tag:
|
|||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
# Global var
|
# Global var
|
||||||
# Recent versions of the zeroconf python package doesnt like a zeroconf type that ends with '._tcp.'.
|
# Recent versions of the zeroconf python package doesn't like a zeroconf type that ends with '._tcp.'.
|
||||||
# Correct issue: zeroconf problem with zeroconf_type = "_%s._tcp." % 'glances' #888
|
# Correct issue: zeroconf problem with zeroconf_type = "_%s._tcp." % 'glances' #888
|
||||||
zeroconf_type = "_%s._tcp.local." % 'glances'
|
zeroconf_type = "_%s._tcp.local." % 'glances'
|
||||||
|
|
||||||
|
@ -203,7 +203,7 @@ else:
|
|||||||
return s.encode('utf-8', errors=errors)
|
return s.encode('utf-8', errors=errors)
|
||||||
|
|
||||||
def system_exec(command):
|
def system_exec(command):
|
||||||
"""Execute a system command and return the resul as a str"""
|
"""Execute a system command and return the result as a str"""
|
||||||
try:
|
try:
|
||||||
res = subprocess.check_output(command.split(' '))
|
res = subprocess.check_output(command.split(' '))
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
@ -47,7 +47,7 @@ class GlancesFilter(object):
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def filter_input(self):
|
def filter_input(self):
|
||||||
"""Return the filter given by the user (as a sting)"""
|
"""Return the filter given by the user (as a string)"""
|
||||||
return self._filter_input
|
return self._filter_input
|
||||||
|
|
||||||
@property
|
@property
|
||||||
@ -57,7 +57,7 @@ class GlancesFilter(object):
|
|||||||
|
|
||||||
@filter.setter
|
@filter.setter
|
||||||
def filter(self, value):
|
def filter(self, value):
|
||||||
"""Set the filter (as a sting) and compute the regular expression
|
"""Set the filter (as a string) and compute the regular expression
|
||||||
|
|
||||||
A filter could be one of the following:
|
A filter could be one of the following:
|
||||||
- python > Process name of cmd start with python
|
- python > Process name of cmd start with python
|
||||||
|
@ -123,10 +123,10 @@ Examples of use:
|
|||||||
'--disable-plugin',
|
'--disable-plugin',
|
||||||
'--disable-plugins',
|
'--disable-plugins',
|
||||||
dest='disable_plugin',
|
dest='disable_plugin',
|
||||||
help='disable plugin (comma separed list or all). If all is used, then you need to configure --enable-plugin.',
|
help='disable plugin (comma separated list or all). If all is used, then you need to configure --enable-plugin.',
|
||||||
)
|
)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'--enable-plugin', '--enable-plugins', dest='enable_plugin', help='enable plugin (comma separed list)'
|
'--enable-plugin', '--enable-plugins', dest='enable_plugin', help='enable plugin (comma separated list)'
|
||||||
)
|
)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'--disable-process',
|
'--disable-process',
|
||||||
@ -253,7 +253,7 @@ Examples of use:
|
|||||||
help='Accumulate processes by program',
|
help='Accumulate processes by program',
|
||||||
)
|
)
|
||||||
# Export modules feature
|
# Export modules feature
|
||||||
parser.add_argument('--export', dest='export', help='enable export module (comma separed list)')
|
parser.add_argument('--export', dest='export', help='enable export module (comma separated list)')
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'--export-csv-file', default='./glances.csv', dest='export_csv_file', help='file path for CSV exporter'
|
'--export-csv-file', default='./glances.csv', dest='export_csv_file', help='file path for CSV exporter'
|
||||||
)
|
)
|
||||||
|
@ -125,9 +125,7 @@ class GlancesStdoutIssue(object):
|
|||||||
|
|
||||||
# Display total time need to update all plugins
|
# Display total time need to update all plugins
|
||||||
sys.stdout.write('=' * TERMINAL_WIDTH + '\n')
|
sys.stdout.write('=' * TERMINAL_WIDTH + '\n')
|
||||||
print("Total time to update all stats: {}{:.5f}s{}".format(colors.BLUE,
|
print("Total time to update all stats: {}{:.5f}s{}".format(colors.BLUE, counter_total.get(), colors.NO))
|
||||||
counter_total.get(),
|
|
||||||
colors.NO))
|
|
||||||
sys.stdout.write('=' * TERMINAL_WIDTH + '\n')
|
sys.stdout.write('=' * TERMINAL_WIDTH + '\n')
|
||||||
|
|
||||||
# Return True to exit directly (no refresh)
|
# Return True to exit directly (no refresh)
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
"""Cloud plugin.
|
"""Cloud plugin.
|
||||||
|
|
||||||
Supported Cloud API:
|
Supported Cloud API:
|
||||||
- OpenStack meta data (class ThreadOpenStack, see bellow): AWS, OVH...
|
- OpenStack meta data (class ThreadOpenStack, see below): AWS, OVH...
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import threading
|
import threading
|
||||||
|
@ -640,7 +640,8 @@ class Plugin(GlancesPlugin):
|
|||||||
value = (
|
value = (
|
||||||
self.auto_unit(
|
self.auto_unit(
|
||||||
int(container['network']['rx'] // container['network']['time_since_update'] * to_bit)
|
int(container['network']['rx'] // container['network']['time_since_update'] * to_bit)
|
||||||
) + unit
|
)
|
||||||
|
+ unit
|
||||||
)
|
)
|
||||||
msg = '{:>7}'.format(value)
|
msg = '{:>7}'.format(value)
|
||||||
except KeyError:
|
except KeyError:
|
||||||
@ -650,7 +651,8 @@ class Plugin(GlancesPlugin):
|
|||||||
value = (
|
value = (
|
||||||
self.auto_unit(
|
self.auto_unit(
|
||||||
int(container['network']['tx'] // container['network']['time_since_update'] * to_bit)
|
int(container['network']['tx'] // container['network']['time_since_update'] * to_bit)
|
||||||
) + unit
|
)
|
||||||
|
+ unit
|
||||||
)
|
)
|
||||||
msg = ' {:<7}'.format(value)
|
msg = ' {:<7}'.format(value)
|
||||||
except KeyError:
|
except KeyError:
|
||||||
@ -750,11 +752,13 @@ def sort_docker_stats(stats):
|
|||||||
sort_by = 'cpu_percent'
|
sort_by = 'cpu_percent'
|
||||||
|
|
||||||
# Sort docker stats
|
# Sort docker stats
|
||||||
sort_stats_processes(stats['containers'],
|
sort_stats_processes(
|
||||||
sorted_by=sort_by,
|
stats['containers'],
|
||||||
sorted_by_secondary=sort_by_secondary,
|
sorted_by=sort_by,
|
||||||
# Reverse for all but name
|
sorted_by_secondary=sort_by_secondary,
|
||||||
reverse=glances_processes.sort_key != 'name')
|
# Reverse for all but name
|
||||||
|
reverse=glances_processes.sort_key != 'name',
|
||||||
|
)
|
||||||
|
|
||||||
# Return the main sort key and the sorted stats
|
# Return the main sort key and the sorted stats
|
||||||
return sort_by, stats
|
return sort_by, stats
|
||||||
|
@ -134,7 +134,7 @@ class Plugin(GlancesPlugin):
|
|||||||
# Call the father's method
|
# Call the father's method
|
||||||
super(Plugin, self).update_views()
|
super(Plugin, self).update_views()
|
||||||
|
|
||||||
# Add specifics informations
|
# Add specifics information
|
||||||
try:
|
try:
|
||||||
# Alert and log
|
# Alert and log
|
||||||
self.views['min15']['decoration'] = self.get_alert_log(
|
self.views['min15']['decoration'] = self.get_alert_log(
|
||||||
|
@ -516,7 +516,7 @@ class GlancesPlugin(object):
|
|||||||
|
|
||||||
If key is None, return all the view for the current plugin
|
If key is None, return all the view for the current plugin
|
||||||
else if option is None return the view for the specific key (all option)
|
else if option is None return the view for the specific key (all option)
|
||||||
else return the view fo the specific key/option
|
else return the view of the specific key/option
|
||||||
|
|
||||||
Specify item if the stats are stored in a dict of dict (ex: NETWORK, FS...)
|
Specify item if the stats are stored in a dict of dict (ex: NETWORK, FS...)
|
||||||
"""
|
"""
|
||||||
@ -831,7 +831,9 @@ class GlancesPlugin(object):
|
|||||||
show=sda.*
|
show=sda.*
|
||||||
"""
|
"""
|
||||||
# @TODO: possible optimisation: create a re.compile list
|
# @TODO: possible optimisation: create a re.compile list
|
||||||
return any(j for j in [re.fullmatch(i.lower(), value.lower()) for i in self.get_conf_value('show', header=header)])
|
return any(
|
||||||
|
j for j in [re.fullmatch(i.lower(), value.lower()) for i in self.get_conf_value('show', header=header)]
|
||||||
|
)
|
||||||
|
|
||||||
def is_hide(self, value, header=""):
|
def is_hide(self, value, header=""):
|
||||||
"""Return True if the value is in the hide configuration list.
|
"""Return True if the value is in the hide configuration list.
|
||||||
@ -842,7 +844,9 @@ class GlancesPlugin(object):
|
|||||||
hide=sda2,sda5,loop.*
|
hide=sda2,sda5,loop.*
|
||||||
"""
|
"""
|
||||||
# @TODO: possible optimisation: create a re.compile list
|
# @TODO: possible optimisation: create a re.compile list
|
||||||
return any(j for j in [re.fullmatch(i.lower(), value.lower()) for i in self.get_conf_value('hide', header=header)])
|
return any(
|
||||||
|
j for j in [re.fullmatch(i.lower(), value.lower()) for i in self.get_conf_value('hide', header=header)]
|
||||||
|
)
|
||||||
|
|
||||||
def is_display(self, value, header=""):
|
def is_display(self, value, header=""):
|
||||||
"""Return True if the value should be displayed in the UI"""
|
"""Return True if the value should be displayed in the UI"""
|
||||||
|
@ -60,7 +60,7 @@ class Plugin(GlancesPlugin):
|
|||||||
stats = glances_processes.get_count()
|
stats = glances_processes.get_count()
|
||||||
elif self.input_method == 'snmp':
|
elif self.input_method == 'snmp':
|
||||||
# Update stats using SNMP
|
# Update stats using SNMP
|
||||||
# Not availaible
|
# Not available
|
||||||
pass
|
pass
|
||||||
|
|
||||||
# Update the stats
|
# Update the stats
|
||||||
|
@ -373,7 +373,7 @@ class Plugin(GlancesPlugin):
|
|||||||
msg = self.layout_stat['pid'].format(p['pid'], width=self.__max_pid_size())
|
msg = self.layout_stat['pid'].format(p['pid'], width=self.__max_pid_size())
|
||||||
else:
|
else:
|
||||||
# Display programs, so the PID should not be displayed
|
# Display programs, so the PID should not be displayed
|
||||||
# Instead displays the number of childrens
|
# Instead displays the number of children
|
||||||
msg = self.layout_stat['pid'].format(
|
msg = self.layout_stat['pid'].format(
|
||||||
len(p['childrens']) if 'childrens' in p else '_', width=self.__max_pid_size()
|
len(p['childrens']) if 'childrens' in p else '_', width=self.__max_pid_size()
|
||||||
)
|
)
|
||||||
|
@ -291,9 +291,10 @@ class GlancesProcesses(object):
|
|||||||
p.info
|
p.info
|
||||||
for p in psutil.process_iter(attrs=sorted_attrs, ad_value=None)
|
for p in psutil.process_iter(attrs=sorted_attrs, ad_value=None)
|
||||||
# OS-related processes filter
|
# OS-related processes filter
|
||||||
if not (BSD and p.info['name'] == 'idle') and
|
if not (BSD and p.info['name'] == 'idle')
|
||||||
not (WINDOWS and p.info['name'] == 'System Idle Process') and
|
and not (WINDOWS and p.info['name'] == 'System Idle Process')
|
||||||
not (MACOS and p.info['name'] == 'kernel_task') and
|
and not (MACOS and p.info['name'] == 'kernel_task')
|
||||||
|
and
|
||||||
# Kernel threads filter
|
# Kernel threads filter
|
||||||
not (self.no_kernel_threads and LINUX and p.info['gids'].real == 0)
|
not (self.no_kernel_threads and LINUX and p.info['gids'].real == 0)
|
||||||
]
|
]
|
||||||
@ -322,7 +323,7 @@ class GlancesProcesses(object):
|
|||||||
top_process = psutil.Process(proc['pid'])
|
top_process = psutil.Process(proc['pid'])
|
||||||
extended_stats = ['cpu_affinity', 'ionice', 'num_ctx_switches']
|
extended_stats = ['cpu_affinity', 'ionice', 'num_ctx_switches']
|
||||||
if LINUX:
|
if LINUX:
|
||||||
# num_fds only avalable on Unix system (see issue #1351)
|
# num_fds only available on Unix system (see issue #1351)
|
||||||
extended_stats += ['num_fds']
|
extended_stats += ['num_fds']
|
||||||
if WINDOWS:
|
if WINDOWS:
|
||||||
extended_stats += ['num_handles']
|
extended_stats += ['num_handles']
|
||||||
|
@ -16,7 +16,7 @@ from subprocess import Popen, PIPE
|
|||||||
def secure_popen(cmd):
|
def secure_popen(cmd):
|
||||||
"""A more or less secure way to execute system commands
|
"""A more or less secure way to execute system commands
|
||||||
|
|
||||||
Multiple command should be seperated with a &&
|
Multiple command should be separated with a &&
|
||||||
|
|
||||||
:return: the result of the commands
|
:return: the result of the commands
|
||||||
"""
|
"""
|
||||||
|
@ -110,7 +110,7 @@ class GlancesStats(object):
|
|||||||
# on the console but do not crash
|
# on the console but do not crash
|
||||||
logger.critical("Error while initializing the {} plugin ({})".format(name, e))
|
logger.critical("Error while initializing the {} plugin ({})".format(name, e))
|
||||||
logger.error(traceback.format_exc())
|
logger.error(traceback.format_exc())
|
||||||
# An error occure, disable the plugin
|
# An error occurred, disable the plugin
|
||||||
if args is not None:
|
if args is not None:
|
||||||
setattr(args, 'disable_' + name, False)
|
setattr(args, 'disable_' + name, False)
|
||||||
else:
|
else:
|
||||||
|
@ -47,7 +47,7 @@ class GlancesStatsClientSNMP(GlancesStats):
|
|||||||
self.load_modules(self.args)
|
self.load_modules(self.args)
|
||||||
|
|
||||||
def check_snmp(self):
|
def check_snmp(self):
|
||||||
"""Chek if SNMP is available on the server."""
|
"""Check if SNMP is available on the server."""
|
||||||
# Import the SNMP client class
|
# Import the SNMP client class
|
||||||
from glances.snmp import GlancesSNMPClient
|
from glances.snmp import GlancesSNMPClient
|
||||||
|
|
||||||
|
2
setup.py
2
setup.py
@ -68,7 +68,7 @@ def get_install_extras_require():
|
|||||||
'sparklines': ['sparklines'],
|
'sparklines': ['sparklines'],
|
||||||
'web': ['bottle', 'requests'],
|
'web': ['bottle', 'requests'],
|
||||||
'wifi': ['wifi']
|
'wifi': ['wifi']
|
||||||
# 'gpu' and 'sensors' ==> See bellow
|
# 'gpu' and 'sensors' ==> See below
|
||||||
}
|
}
|
||||||
if PY3:
|
if PY3:
|
||||||
extras_require['export'].append('influxdb-client')
|
extras_require['export'].append('influxdb-client')
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# This is the maintainence launcher for the snap, make necessary runtime
|
# This is the maintenance launcher for the snap, make necessary runtime
|
||||||
# environment changes to make the snap work here. You may also insert
|
# environment changes to make the snap work here. You may also insert
|
||||||
# security confinement/deprecation/obsoletion notice of the snap here.
|
# security confinement/deprecation/obsoletion notice of the snap here.
|
||||||
set \
|
set \
|
||||||
|
@ -322,7 +322,7 @@ class TestGlances(unittest.TestCase):
|
|||||||
msg='{} view is not a dict'.format(plugin))
|
msg='{} view is not a dict'.format(plugin))
|
||||||
|
|
||||||
def test_097_attribute(self):
|
def test_097_attribute(self):
|
||||||
"""Test GlancesAttribute classe"""
|
"""Test GlancesAttribute classes"""
|
||||||
print('INFO: [TEST_097] Test attribute')
|
print('INFO: [TEST_097] Test attribute')
|
||||||
# GlancesAttribute
|
# GlancesAttribute
|
||||||
from glances.attribute import GlancesAttribute
|
from glances.attribute import GlancesAttribute
|
||||||
@ -345,7 +345,7 @@ class TestGlances(unittest.TestCase):
|
|||||||
self.assertEqual(a.history_mean(nb=3), 4.5)
|
self.assertEqual(a.history_mean(nb=3), 4.5)
|
||||||
|
|
||||||
def test_098_history(self):
|
def test_098_history(self):
|
||||||
"""Test GlancesHistory classe"""
|
"""Test GlancesHistory classes"""
|
||||||
print('INFO: [TEST_098] Test history')
|
print('INFO: [TEST_098] Test history')
|
||||||
# GlancesHistory
|
# GlancesHistory
|
||||||
from glances.history import GlancesHistory
|
from glances.history import GlancesHistory
|
||||||
|
Loading…
Reference in New Issue
Block a user