1

I have my mailserver setup configured based on this guideline (German), with the possibly important detail that I use CentOS 8 as a base OS instead of Debian. Everything works fine, except that I cannot manage to integrate rspamd into my setup.

If I wire up postfix to connect to rspamd by including the following lines in main.cf:

smtpd_milters = inet:localhost:11332
non_smtpd_milters = inet:localhost:11332
milter_protocol = 6
milter_mail_macros =  i {mail_addr} {client_addr} {client_name} {auth_authen}
milter_default_action = accept

and send an email, I see the following error from postfix:

postfix/submission/smtpd[125562]: fatal: host/service localhost/11332 not found: Device or resource busy

The worker-proxy.inc config for rspamd looks like

bind_socket = "localhost:11332";
milter = yes;
timeout = 120s;
upstream "local" {
    default = yes;
    self_scan = yes;
}

If I manually connect to rspamd with telnet, I don't see this error:

# telnet localhost 11332
Trying ::1...
Connected to localhost.
Escape character is '^]'.

So rspamd is listening on the expected port but postfix cannot connect to it, I do not know how to debug this any further and would appreciate any advice on how to proceed. Thanks.

2
  • Check the audit log. Aug 18, 2020 at 19:44
  • @MichaelHampton Thanks for the idea. Unfortunately, Audit.log shows nothing of relevance, just IPs from China trying to login as root.
    – dlkmp
    Aug 22, 2020 at 13:38

1 Answer 1

0

After randomly trying various config changes, I stumbled upon the solution. For whatever reason, postfix cannot resolve localhost. I changed the following entries in /etc/postfix/main.cf:

 smtpd_milters = inet:localhost:11332
 non_smtpd_milters = inet:localhost:11332

to

 smtpd_milters = inet:127.0.0.1:11332
 non_smtpd_milters = inet:127.0.0.1:11332

and all of sudden, no more errors!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .