Debian Codegraph @

debian/tests/gmond

raw
1 #!/bin/bash
2 #--------------
3 # Testing gmond
4 #--------------
5 MACHINE=127.0.0.1
6 PORT=8649
7
8 # listen to port
9 netcat -z ${MACHINE} ${PORT}
10 if [ $? -eq 0 ]
11 then
12 echo "OK"
13 exit 0
14 else
15 echo "ERROR: gmond not listening" >&1
16 exit 1
17 fi