onos-local-log 412 Bytes
#!/bin/bash
# ----------------------------------------------------------------------------
# Continuously watches the Apache Karaf log; survives 'karaf clean'
# ----------------------------------------------------------------------------
KARAF_LOG=${KARAF_LOG:-~/apache-karaf-$KARAF_VERSION/data/log/karaf.log}

while true; do
    [ ! -f $KARAF_LOG ] && sleep 2 && continue
    tail -n 512 -f -F $KARAF_LOG
done