Hello,

i was struggling with the ping resource agent since it stopped working and i 
had some log entries about syntax errors for "expr".

Around line 244 in the ping script, the score is getting calculated like this:

    score=`expr $active * $OCF_RESKEY_multiplier`

This doesnt work since the asterisk "*" must be escaped.

I have no idea why it did work for some time, but this fixes it:

    score=`expr $active \* $OCF_RESKEY_multiplier`

or one could use let instead of expr

    let score=$active*$OCF_RESKEY_multiplier

but maybe the bash builtin is faster?

        score=$((active * OCF_RESKEY_multiplier))


Regards,

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

Reply via email to