/Main_Page

::You must have ninja focus to complete your mission::NinjaFocus::

Exim-top-senders.sh

Views:


#!/bin/bash

renice 10 $$

# Some nasty byte escape sequence showed up in an email address
# \222 - possibly �� (Latin Capital Letter Thorn)
export LC_ALL='C'

cat /var/log/exim/main.[0-9] \
    | egrep "<[=\-] .* \[[^ ]+\] P=[a-z]*smtp.* " \
    | sed -e 's/^.* \[\(\([[:digit:]]\{1,3\}\.\)\{3\}[[:digit:]]\{1,3\}\)\] .*$/\1/' \
    | sort \
    | uniq -c \
    | sort -n \
    | tail -20

Main Menu

Personal tools

Toolbox