blob: 1f1e5c680a7bfd8231e16844cb75cf43b2d7bb68 [file] [log] [blame]
Yuta HIGUCHIc588aa32014-11-13 14:28:48 -08001#!/bin/bash
2# -----------------------------------------------------------------------------
3# Removes Raft logs on all instances
4# -----------------------------------------------------------------------------
5
6[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
7. $ONOS_ROOT/tools/build/envDefaults
8
9nodes=$(env | sort | egrep "OC[0-9]+" | cut -d= -f2)
10
11onos-service --cell stop
12
Yuta HIGUCHI43e3a7e2014-11-30 23:22:11 -080013# TODO: use $KARAF_DATA
14for node in $nodes; do onos-ssh $node "rm -v -- $ONOS_INSTALL_DIR/$KARAF_DIST/data/raft/onos-copy-cat-log_*"; done