summaryrefslogtreecommitdiffstats
path: root/remote/logs.sh
diff options
context:
space:
mode:
Diffstat (limited to 'remote/logs.sh')
-rwxr-xr-xremote/logs.sh32
1 files changed, 32 insertions, 0 deletions
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