-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstats.sh
executable file
·35 lines (23 loc) · 1.21 KB
/
stats.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/sh
echo Top 10 device disconnects
grep 'Device disconnected' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 device connects
grep 'Device connected' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 admin logins
grep 'Admin login successful by' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 client associated
grep 'Client associated$' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 client disassociated
grep 'Client disassociated$' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 spoofing protection
grep 'Spoofing protection' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 wifi registration failed
grep 'WiFi registration failed' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 IN BLOCK
grep 'IN: BLOCK' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Top 10 IN ACCEPT
grep 'IN: ACCEPT' out.log | cut -c28- | sort | uniq -c | sort -rn | head -10
echo Last 10 system start
grep 'System start $' out.log | head -10 | sed -e 's/^/ /g'
echo Last 100 cwmp session start
grep 'CWMP: Session start now' out.log | head -100 | sed -e 's/^/ /g'