[Dovecot] Can I create multiple sockets and listen on them in parallel.
I currently have a setup which is postfix -> dovecot via lmtp over a unix socket. The socket is located at /var/spool/postfix/private/dovecot-lmtp
I am calling dspam as a milter from postfix.
However I am struggling with getting dspam knowing the correct user for the incoming mail, because after its been through the milter, the virtual alias maps etc end up turning it into my "dovecot" user name, and the two are not easily comparable.
So instead I want to try and set up postfix->dspam->dovecot
But I want to take it in easy stages, and therefore ideally would like to set up dovecot to listen on two sockets simultenously = one for the existing connection from postfix, and one for the future connection from dspam - preferably in the context of the /var/spool/dspam or /var/lib/dovecot directories
That way I can continue to receive existing mail whilst sending a few test mails through dspam.
Does 10-master.conf config file work that way? (debian configuration)
can I change something like this ...
service lmtp { unix_listener /var/spool/postfix/private/dovecot-lmtp { mode = 0600 group = postfix user = postfix } }
into this ...
service lmtp { unix_listener /var/spool/postfix/private/dovecot-lmtp { mode = 0600 group = postfix user = postfix } unix_listener /var/spool/dspam/dovecot-lmtp { mode = 0600 group = dspam user = dspam }
}
and still have dovecot work?
-- Alan Chandler http://www.chandlerfamily.org.uk
Just do it and see what happens. Looks OK to me.. Actually I just fearlessly dared to paste your proposed config snippet into my dovecot config and it didn't blow up and it did create two sockets, so I assume they would both work.
On 03/11/2014 03:10 PM, Alan Chandler wrote:
I currently have a setup which is postfix -> dovecot via lmtp over a unix socket. The socket is located at /var/spool/postfix/private/dovecot-lmtp
I am calling dspam as a milter from postfix.
However I am struggling with getting dspam knowing the correct user for the incoming mail, because after its been through the milter, the virtual alias maps etc end up turning it into my "dovecot" user name, and the two are not easily comparable.
So instead I want to try and set up postfix->dspam->dovecot
But I want to take it in easy stages, and therefore ideally would like to set up dovecot to listen on two sockets simultenously = one for the existing connection from postfix, and one for the future connection from dspam - preferably in the context of the /var/spool/dspam or /var/lib/dovecot directories
That way I can continue to receive existing mail whilst sending a few test mails through dspam.
Does 10-master.conf config file work that way? (debian configuration)
can I change something like this ...
service lmtp { unix_listener /var/spool/postfix/private/dovecot-lmtp { mode = 0600 group = postfix user = postfix } }
into this ...
service lmtp { unix_listener /var/spool/postfix/private/dovecot-lmtp { mode = 0600 group = postfix user = postfix } unix_listener /var/spool/dspam/dovecot-lmtp { mode = 0600 group = dspam user = dspam }
}
and still have dovecot work?
On 11/03/14 20:03, Gedalya wrote:
Just do it and see what happens. Looks OK to me.. Actually I just fearlessly dared to paste your proposed config snippet into my dovecot config and it didn't blow up and it did create two sockets, so I assume they would both work.
On 03/11/2014 03:10 PM, Alan Chandler wrote:
... service lmtp { unix_listener /var/spool/postfix/private/dovecot-lmtp { mode = 0600 group = postfix user = postfix } unix_listener /var/spool/dspam/dovecot-lmtp { mode = 0600 group = dspam user = dspam }
}
and still have dovecot work?
Actually I figured I could do it quickly, and if dovecot stopped working I could revert back.
So I took the plunge, and yes it still seems to be working and yes It created two sockets. Don't know if they both work yet, but the first one does and the second is definitely there.
Thanks for daring for me.
-- Alan Chandler http://www.chandlerfamily.org.uk
On 03/11/2014 04:08 PM, Alan Chandler wrote:
Actually I figured I could do it quickly, and if dovecot stopped working I could revert back.
So I took the plunge, and yes it still seems to be working and yes It created two sockets. Don't know if they both work yet, but the first one does and the second is definitely there.
Thanks for daring for me. It helps to have just a test platform, or like in my case, an "expendable" server which I use only for my own personal mail so it's OK if it's down for 60 seconds here and there..
participants (2)
-
Alan Chandler
-
Gedalya