On Wednesday 09 September 2009 16:56:28 Xavier Parizet wrote: > J. Roeleveld a écrit : > > On Wednesday 09 September 2009 14:49:37 Xavier Parizet wrote: > >> J. Roeleveld a écrit : > >>> On Wednesday 09 September 2009 14:19:45 Xavier Parizet wrote: > >>>> J. Roeleveld a écrit : > >>>>> Hi All, > >>>>> > >>>>> I know this is probably off-topic, but I'm hopefull someone on this > >>>>> list knows how to do this. > >>>>> > >>>>> My current situation: > >>>>> Postfix gets an email delivered for user X > >>>>> Postfix passes this to cyrus (lmtp-transport) > >>>>> if user X does not exist within cyrus, the email gets bounced. > >>>>> > >>>>> I would like this bounced email to be delivered to a seperate cyrus > >>>>> email folder. > >>>>> > >>>>> I tried to find the answer on google, but all the solutions I found > >>>>> either only work with the postfix local delivery agent (eg. not > >>>>> compatible with cyrus) or requires a list to be maintained using all > >>>>> the known email-boxes. > >>>>> > >>>>> I prefer a fall-back solution where an email directed at a user not > >>>>> listed in either the alias table (stored in ldap) or not known to > >>>>> cyrus is redirected to a specific cyrus mailbox. > >>>> > >>>> A solution could be doing a catch-all alias (see [1]) : > >>>> if your domain is example.com, then add an alias mapping @example.com > >>>> to oneaddr...@example.com either using virtual alias or > >>>> /etc/postfix/aliases . > >>>> > >>>> HTH. > >>>> > >>>> [1] http://www.postfix.org/VIRTUAL_README.html > >>> > >>> I did notice this option, but it would require me to duplicate the > >>> alias table into a alias file. I tried setting a "@<domain>" entry in > >>> my ldap-tree, but this did not work. > >> > >> If you use LDAP as a virtual backend, then [1] will then be a better > >> place to look. Setting mailacceptinggeneralid ldap attribute to > >> @<domain> seems to be the solution (if you use "standard" LDAP scheme). > >> > >> HTH. > >> > >> [1] http://www.postfix.org/LDAP_README.html#example_virtual > > > > I tried this, but when looking at the ldap logs, I notice that the > > 'domain' part does not exist in the search string. > > Eg. '%s' only shows the user, '%d' is empty, eg. query is ignored > > > > Does anyone know how I can force postfix to add the domain to the search > > query? > > Is mydomain parameter set in /etc/postfix/main.cf ?
Yes, I believe this is necessary for postfix to actually accept emails? Or how else do I get this configured? Thanks, Joost