Thomas Vachuska | 33bd230 | 2015-02-19 14:53:44 -0800 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # ----------------------------------------------------------------------------- |
| 3 | # Kills all remote ONOS log file monitors on the specified node. |
| 4 | # ----------------------------------------------------------------------------- |
| 5 | |
| 6 | [ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1 |
| 7 | . $ONOS_ROOT/tools/build/envDefaults |
| 8 | . $ONOS_ROOT/tools/test/bin/find-node.sh |
| 9 | |
| 10 | less=0 |
| 11 | [ "$1" = "-l" ] && shift && less=1 |
| 12 | |
| 13 | remote=$(find_node $1) |
| 14 | remote=$ONOS_USER@${remote:-$OCI} |
| 15 | |
| 16 | ssh $remote "ps -ef | grep \"tail -n 512\" | grep -v grep | cut -c10-15 | xargs kill" |