Révision 50a998b4
areastack option
| plugins/lxc/lxc_ram | ||
|---|---|---|
| 12 | 12 |
[lxc_*] |
| 13 | 13 |
user root |
| 14 | 14 |
|
| 15 |
[lxc_ram] |
|
| 16 |
env.areastack true |
|
| 17 |
|
|
| 15 | 18 |
=head1 INTERPRETATION |
| 16 | 19 |
|
| 17 | 20 |
This plugin needs root privilege. |
| 18 | 21 |
|
| 22 |
If env.areastack is set to true, all memory usages of containers will be |
|
| 23 |
drawn as stacked area charts. |
|
| 24 |
This option changes graph order, all of 'Mem usage' comes first and then others. |
|
| 25 |
(default: false) |
|
| 26 |
|
|
| 19 | 27 |
=head1 AUTHOR |
| 20 | 28 |
|
| 21 | 29 |
vajtsz vajtsz@gmail.com |
| ... | ... | |
| 40 | 48 |
|
| 41 | 49 |
active_guests=$(active_guests) |
| 42 | 50 |
|
| 51 |
# configurable: true/false |
|
| 52 |
areastack=${areastack:-false}
|
|
| 53 |
|
|
| 43 | 54 |
if [ "$1" = "autoconf" ]; then |
| 44 | 55 |
lxc_autoconf |
| 45 | 56 |
fi |
| ... | ... | |
| 58 | 69 |
cat <<EOF |
| 59 | 70 |
mem_usage_${g}.label ${n}: Mem usage
|
| 60 | 71 |
mem_usage_${g}.type GAUGE
|
| 72 |
<<EOF |
|
| 73 |
if [ "$areastack" = "true" ]; then |
|
| 74 |
echo "mem_usage_${g}.draw AREASTACK"
|
|
| 75 |
fi |
|
| 76 |
|
|
| 77 |
cat <<EOF |
|
| 61 | 78 |
mem_cache_${g}.label ${n}: Cache
|
| 62 | 79 |
mem_cache_${g}.type GAUGE
|
| 63 | 80 |
mem_active_${g}.label ${n}: Active
|
Formats disponibles : Unified diff