Closed dlmarion closed 2 years ago
So, I did some testing, and it's not the use of RANDOM
vs $RANDOM
. The log has the same IP being selected over and over again. So, maybe it's something else.
So, I did some testing, and it's not the use of
RANDOM
vs$RANDOM
. The log has the same IP being selected over and over again. So, maybe it's something else.
I'm not that familiar with RANDOM
vs $RANDOM
, but in testing the existing expressions, they seemed to both work for me.
I don't see anything immediately obviously wrong with the use of RANDOM to select nodes from the bash array to kill. But, I wouldn't append to the kill array using the index, like the script is currently doing (array[index]=foo
). Instead, I'd do array=("${array[@]}" foo)
, which I am more familiar with. I don't know if the former works on older bash, but when testing, it did seem to work on mine, so it could be fine. (I'm running 5.2.2)
@dlmarion Those two lines of code look okay to me. It looks like it's a simplified case where it avoids all the array logic if you're only killing up to 1 node. (max_kill == 1). Though, in that case, I suppose it could pick a random one, instead of always selecting the first.
The agitator was refactored as part of https://github.com/apache/accumulo-testing/pull/184. I think there is a bug in the new script, specifically the use of the word
RANDOM
instead of the function$RANDOM
here and here.@ctubbsii - can you confirm?