Hi all,

mainly Dominik Klein - thanks for the showscores.sh script. But I am
curious, why the script filters numeric values only for failcount
values meaning INFINITY are just ignored:
1. Simulating a failure
Failed actions:
    dom0-fs-Dom0_start_0 (node=vsp11.example.com, call=15, rc=5,
status=complete): not installed

2. Before patch
Resource                    Score     Node
Stickiness #Fail    Migration-Threshold
dom0-drbd-Dom0          -1000000  vsp11.example.com 90         0
dom0-drbd-Dom0          410       vsp9.example.com  90         0
dom0-fs-Dom0            0         vsp9.example.com  0          0
dom0-fs-Dom0            -1000000  vsp11.example.com 0      <== Note no
#Fail value

3. After patch
Resource                    Score     Node
Stickiness #Fail    Migration-Threshold
dom0-drbd-Dom0          -1000000  vsp11.example.com 90         0
dom0-drbd-Dom0          410       vsp9.example.com  90         0
dom0-fs-Dom0            0         vsp9.example.com  0          0
dom0-fs-Dom0            -1000000  vsp11.example.com 0
INFINITY <== Note we can see the INF value now

Would it be feasible to apply this patch:
----------------------------------------------------------------------------------
--- showscores.sh       2010-03-25 14:59:21.000000000 +0000
+++ showscores-new.sh   2010-03-25 15:00:38.000000000 +0000
@@ -91,3 +91,3 @@
 get_failcount() { #usage $0 res node
-        failcount=`crm_failcount -G -r $1 -U $2 -Q 2>/dev/null|grep
-o "^[0-9]*$"`
+        failcount=`crm_failcount -G -r $1 -U $2 -Q 2>/dev/null`
 }
----------------------------------------------------------------------------------

With regards,
Tino

_______________________________________________
Pacemaker mailing list
Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Reply via email to