From aa29ce5a243320559f8f83d9434bc55f20ae9aec Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Sun, 25 Aug 2019 06:45:30 +0200 Subject: Overview screens also ported to remote mode --- remote/logs.sh | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100755 remote/logs.sh (limited to 'remote/logs.sh') diff --git a/remote/logs.sh b/remote/logs.sh new file mode 100755 index 0000000..91257c0 --- /dev/null +++ b/remote/logs.sh @@ -0,0 +1,32 @@ +#! /bin/bash + +. lib/status.sh + +function filter_syslog { + log="$1" + lines=${2:-20} + + tail -n $lines $log | sed -r 's/(MAC|OUT|IN|TOS|PREC|ID|RES)=[[:alnum:]:]*[[:space:]]//g' +} + + +decorate "Serv1:" purple; echo +filter_syslog /var/log/messages_darkserv1 + +echo +echo + +decorate "Serv3:" purple; echo +filter_syslog /var/log/messages_darkserv3 + +echo +echo + +decorate "Serv4:" purple; echo +filter_syslog /var/log/messages_darkserv4 + +#echo +#echo + +#decorate "Styx:" purple; echo +#filter_syslog /var/log/styx -- cgit v1.2.3