From c8df9ab4e9a512d8a693d5700738deff478fa61d Mon Sep 17 00:00:00 2001 From: Lars Kruse Date: Wed, 1 Aug 2018 23:53:04 +0200 Subject: [PATCH] Plguin xen_memory: change 'draw' style from lines to AREASTACK --- plugins/xen/xen_memory | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/plugins/xen/xen_memory b/plugins/xen/xen_memory index c9e217e5..9fdc4d7b 100755 --- a/plugins/xen/xen_memory +++ b/plugins/xen/xen_memory @@ -36,20 +36,17 @@ if [ "$1" = "config" ]; then # free_memory 1476 name=$(echo "$name" | sed -e"s/-/_/") - if [ "$name" = "total_memory" ]; then + if [ "$name" = "total_memory" ] || [ "$name" = "free_memory" ]; then echo "$name.label $name" echo "$name.type GAUGE" + echo "$name.draw AREASTACK" echo "$name.min 0" - echo "$name.info total memory" - fi - if [ "$name" = "free_memory" ]; then - echo "$name.label $name" - echo "$name.type GAUGE" - echo "$name.draw AREA" -# echo "$name.draw STACK" - echo "$name.min 0" - echo "$name.info free memory" - fi + if [ "$name" = "total_memory" ]; then + echo "$name.info total memory" + elif [ "$name" = "free_memory" ]; then + echo "$name.info free memory" + fi + fi done exit 0 fi