aboutsummaryrefslogtreecommitdiff
path: root/heartbeat_hammer.sh
blob: 9b60171acf1afa6377f166682b0d12da8439ca22 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash

PRE="ruby -I lib ./bin/mauveclient localhost"

_host () { 
  hostname="imaginary-$i.bytemark.co.uk"
  while( true ) ; do
      sleep $((RANDOM/60))
      echo $hostname
      $PRE -o $hostname -i heartbeat -r +2m -c now -s "heartbeat failed" --detail="<p>The heartbeat wasn't sent for this host</p><p>This indicates that the host might be down</p>"
  done
}


for i in `seq 1 50` ; do
  _host $i &
done