Hello,
to implement quota checking for mailboxes I use next router:
virtual_user_quota_defer:
driver = redirect
domains = +virtual_domains
local_parts = test
condition = ${if >={${extract{size}{${stat:/var/mail/virtual/$domain/$local_part}}}}{MYSQL_QUOTA_VMBOX} }
data = :defer:User's mailbox size is over quota!
allow_defer
Ok. Let's emulate a SMTP session from remote host:
# telnet myserver 25
Trying 212.x.x.x...
Connected to myserver.
Escape character is '^]'.
220 ESMTP
helo p
250 myserver Hello p [213.x.x.x]
mail from: minotaur@???
250 OK
RCPT TO: test@???
451 Temporary local problem - please try later
^C^]
telnet> Connection closed.
My question is why I get message "Temporary local problem - please try later"
instead of "User's mailbox size is over quota"?
When I change in router :defer: to :fail: then all is ok and I get wanted message.
Any suggestions? Thanks!
--
Kind Regards, Alexander Shikoff
minotaur@???
Mob.: +380 67 946 31 49