From 7b88828210147a163fe937ba19cb02b72ba0a8ea Mon Sep 17 00:00:00 2001 From: Allan Parsons Date: Tue, 30 Jul 2013 13:22:13 -0700 Subject: [PATCH] Update haproxy-sessions-by-servers - Minor update to oversight for creating a filtered list for url parsing as opposed to socket parsing. --- plugins/haproxy/haproxy-sessions-by-servers | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/haproxy/haproxy-sessions-by-servers b/plugins/haproxy/haproxy-sessions-by-servers index 816fb9e9..896a3e05 100755 --- a/plugins/haproxy/haproxy-sessions-by-servers +++ b/plugins/haproxy/haproxy-sessions-by-servers @@ -28,14 +28,13 @@ function parse_url { if [ ! -z "$url" ]; then LINE1=`curl -s "$url" | head -1 | sed 's/# //'` - LINE2=`curl -s "$url" | grep "$PXNAME,$SVNAME"` + LINE2=`curl -s "$url" | grep "$PXNAME" | grep -v "$PXNAME,$SVNAME" | tr ',' ' '` fi if [ ! -z "$socket" ]; then LINE1=`echo "show stat" | socat unix-connect:"$socket" stdio | head -1 | sed 's/# //'` LINE2=`echo "show stat" | socat unix-connect:"$socket" stdio | grep "$PXNAME" | grep -v "$PXNAME,$SVNAME" | tr ',' ' '` - CMD="echo show stat | socat unix-connect:$socket stdio | grep $PXNAME | grep -v PXNAME,$SVNAME" #echo $CMD #exit fi