1

Topic: AWL with policyd

Hello gentlemen,
I would like to share one problem of mine with you. Maybe you can help...

I have installed my own Freebsd mail server with policyd v1.80, according to the official readme:
http://policyd.sourceforge.net/readme.html.

Everything is working fine, greylisting etc., but I still have problems with auto whitelisting. I've set that I need 5 successful triplets, but nothing happens when mails comes...If I understand it well - cleanup file should check the tables in the database and relocate the host from 'triplet' table to 'whitelist' table right? Or do I need to set up something else? Or the cleanup file is just for deleting the old records from the tables?



Here's the running info:
#/usr/local/etc/rc.d/mysql-server status && /usr/local/etc/rc.d/postfix status && /usr/local/etc/rc.d/policyd status &&
/usr/local/etc/rc.d/policyd_sender_throttle status

mysql is running as pid 16850.
postfix is running as pid 17010.
postfix_policyd_sf is running as pid 17046.
postfix_policyd_sf is not running.

/var/cron/tabs/postfix file:
1    */2    *    *    *    /usr/local/sbin/postfix-policyd-sf-cleanup -c /usr/local/etc/postfix-policyd-sf.conf
1    */2    *    *    *    /usr/local/sbin/postfix-policyd-sf-cleanup -c /usr/local/etc/policyd_sender_throttle.conf

[root@localhost ~]# ps -aux | grep policyd:
root    16872  0.0  0.6 14916  2840  Fri12AM   0:00.04 /usr/local/sbin/postfix-policyd-sf -c /usr/local/etc/postfix-policyd-sf.conf
root    17046  0.0  0.6 14916  2828  Fri12AM   0:00.01 /usr/local/sbin/postfix-policyd-sf -c /usr/local/etc/policyd_sender_throttle.conf
root    28569  0.0  0.2  3496  1064  10:45AM   0:00.00 grep policyd



As you can see the cleanup file is running. I've set also sender_throttle, but then disable it. The rest of the configs are here:

http://dusa.borec.cz/postfix_config.txt
http://dusa.borec.cz/postgrey_config.txt
http://dusa.borec.cz/policyD_config.txt

Thanks for any help people, really appreciate it. Have a nice day!
Dusan

2

Re: AWL with policyd

Do you see some log entries like "greylist=awl" in policyd log file? That's autowhitelist.

I've set that I need 5 successful triplets, but nothing happens when mails come

It's better to show us related configs.

3

Re: AWL with policyd

Hello Zhang, thanks for your fast answer.

Can you open the text files I uploaded in there?
http://dusa.borec.cz/postfix_config.txt
http://dusa.borec.cz/postgrey_config.txt
http://dusa.borec.cz/policyD_config.txt



In the log file I can't find any string "greylist=awl", but thanks to the debug verbosity I can see the cleanup is running correctly:

May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expiring throttlesender records older than 31 days (1303974000)
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: DEBUG: fd: 0, db_deletequery(): DELETE QUICK FROM throttle WHERE _date < 1303974000
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expired: 0 records
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expiring throttlesender instances older than 1 hour (1306648800)
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: DEBUG: fd: 0, db_deletequery(): DELETE QUICK FROM throttle_from_instance WHERE _expire < 1306648800
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expired: 0 records
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expiring throttlerecipient records older than 31 days (1303974000)
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: DEBUG: fd: 0, db_deletequery(): DELETE QUICK FROM throttle_rcpt WHERE _date < 1303974000
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expired: 0 records
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: connected..
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expiring validated records older than 10 days (1305788400)
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: DEBUG: fd: 0, db_deletequery(): DELETE QUICK FROM triplet WHERE _datelast < 1305788400 LIMIT 100000
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expired: 0 records
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: expiring unvalidated records older than 10 days (1305788400)
May 29 09:00:00 localhost postfix-policyd-sf-cleanup: DEBUG: fd: 0, db_deletequery(): DELETE QUICK FROM triplet WHERE _datenew < 1305788400 AND _count = 0 LIMIT 100000

So I suppose the cleanup script is just for cleanup purposes:) How can I auto-whitelist?

4

Re: AWL with policyd

dusanlives wrote:

Can you open the text files I uploaded in there?

Sorry, my mistake.

You have below setting in postfix-policyd.conf:

WHITELISTSENDER=0
WHITELISTDNSNAME=1

And iRedMail has below setting:

WHITELISTSENDER=1
WHITELISTDNSNAME=0

Would you mind to change them to same values as iRedMail default settings and try again?

dusanlives wrote:

So I suppose the cleanup script is just for cleanup purposes:)

Indeed. It just used to remove expired records.

P.S. We don't officially support non-iRedMail mail servers.