mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-06 13:09:50 +00:00
Pick up all messages* files less than two days old rather than
just messages{,.0*} when looking for login failures and refused connections. PR: 23415 Mostly submitted by: phk Convert a few " "s to tabs while I'm here - for consistency.
This commit is contained in:
parent
e0cd22b7b4
commit
38fb35db09
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=71948
17
etc/security
17
etc/security
@ -40,19 +40,20 @@ separator () {
|
||||
}
|
||||
|
||||
catmsgs() {
|
||||
[ -f $LOG/messages.0.gz ] && zcat $LOG/messages.0.gz
|
||||
[ -f $LOG/messages.0 ] && cat $LOG/messages.0
|
||||
[ -f $LOG/messages ] && cat $LOG/messages
|
||||
find $LOG -name 'messages.*' -mtime -2 |
|
||||
sort -t. -r -n +1 -2 |
|
||||
xargs zcat -f
|
||||
[ -f $LOG/messages ] && cat $LOG/messages
|
||||
}
|
||||
|
||||
sflag=FALSE ignore=
|
||||
while getopts ams c
|
||||
do
|
||||
case "$c" in
|
||||
a) ignore="$ignore|^amd:";;
|
||||
m) ignore="$ignore|^mfs:";;
|
||||
s) sflag=TRUE;;
|
||||
esac
|
||||
case "$c" in
|
||||
a) ignore="$ignore|^amd:";;
|
||||
m) ignore="$ignore|^mfs:";;
|
||||
s) sflag=TRUE;;
|
||||
esac
|
||||
done
|
||||
|
||||
yesterday=`date -v-1d "+%b %e "`
|
||||
|
Loading…
Reference in New Issue
Block a user