• We value your experience with Plesk during 2025
    Plesk strives to perform even better in 2026. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2025.
    Please take this short survey:

    https://survey.webpros.com/

Question Postfix totalize per ip connect

If I correctly understood your task, you can try to do it with

# grep postfix /var/log/maillog | grep -o 'connect from unknown' | wc -l
 
I haven't production server with mail. I think you can adapt my example for your case.
Code:
[root@server log]# grep postfix /var/log/maillog | grep ' connect'
Nov  2 07:13:26 server postfix/smtpd[2194]: connect from localhost[::1]
[root@server log]# grep postfix /var/log/maillog | grep ' connect' | awk '{ print $8 }' | uniq -c | sort -n
      1 localhost[::1]
 
Back
Top