I have a machine running postfix/dbmail. I would like to use the recipient maps feature to check with the dbmail database to see if the user is valid and bounce mail if the user is not there.

When I add users, I use a complete email address as the login name instead of the postfix recommended way of a username that maps to an email address. For example postfix likes to do something like:

[EMAIL PROTECTED]              jsmith
[EMAIL PROTECTED]               jsmith_2
[EMAIL PROTECTED]              jsmith_3

However, when I add users for dbmail I add them in such a way to make their email address their login:

[EMAIL PROTECTED]           [EMAIL PROTECTED]
[EMAIL PROTECTED]           [EMAIL PROTECTED]

so the dbmail-adduser command goes something like

dbmail-adduser [EMAIL PROTECTED] password 0 0 [EMAIL PROTECTED]
dbmail-adduser [EMAIL PROTECTED] password 1 0 [EMAIL PROTECTED]

by entering users in such a way, will it break the recipient maps feature in postfix?

Curtis


Leander Koornneef, IC&S wrote:

I'm not sure what you mean and/or what you want to do exactly. Could you elaborate?

regards,
Leander


On 19-jul-04, at 21:53, Curtis Maurand wrote:


But I was looking to check against the dbmail interface. I have the login names as their email addresses, will the local recipient maps be broken, then?

Curtis

--
Curtis Maurand
mailto:[EMAIL PROTECTED]
http://www.maurand.com


On Fri, 16 Jul 2004, Leander Koornneef wrote:

Hi,

On 15-jul-04, at 19:12, Curtis Maurand wrote:

One of you mentioned having postfix check against the dbmail interface to see if email addresses were valid. I like the idea. Does someone have an example of that kind of setup.


Well, it is quite easy to set up :-)

/etc/postfix/main.cf:
-----
local_recipient_maps = mysql:/etc/postfix/mysql-recipients.cf
-----

/etc/postfix/mysql-recipients.cf:
-----
user = <dbuser>
password = <password>
dbname = <dbname>
table = aliases
select_field = alias
where_field = alias
hosts = <host>
-----

Substitute the values between <> to suit your setup and that's it :-)

regards,
Leander


Currently I'm using straight postfix with dbmail. there is support for mysql compiled into postfix. I was just getting ready to install spamassassin, clamav and amavisd to handle all of that, but the base system is working perfectly with pop beford smtp (very fast, too.) Currently I'm setting up users so that they log in with their email addresses. so the dbmail-adduser command looks something like: dbmail-adduser a [EMAIL PROTECTED] secret 0 0 [EMAIL PROTECTED] [EMAIL PROTECTED] Will things work properly with that kind of setup. That setup allows me to unique logins for each domain hosted on the server.
Thanks in advance,
Curtis
--
Curtis Maurand
mailto:[EMAIL PROTECTED]
http://www.maurand.com
On Wed, 14 Jul 2004, Ross Gohlke wrote:

from DBMail INSTALL.postfix:
To use MySQL or PostgreSQL with Postfix, first install the postfix-mysql or postfix-pgsql packages (they're in Debian, probably also in other distros).
My setup:
Mac OS 10.2
Postfix 2.1.4 (from source)
PostgreSQL 7.4.1 (from source)
I'm not aware of a postfix-pgsql source package. Here's what I did for Postfix:
Download source, untar postfix-2.1.4
Download pgsql patch into postfix-2.1.4 <http://mat.cc/postfix/>
patch -p1 < postfix-pg.postfix-2.0.0.2.patch
make makefiles CCARGS='-traditional-cpp -DHAS-PGSQL -DUSE_SASL_AUTH -DHAS_PCRE -I/Library/Frameworks/SASL2.framework/Headers -I/usr/local/include/sasl -I/usr/local/pgsql/include' AUXLIBS='-lpq -ldb -lpcre -lcrypto -lsasl2 -L/usr/local/lib -L/usr/local/lib/sasl2 -L/usr/local/pgsql/lib -L/usr/lib/sasl2' (this was gleaned from lots of READMEs and google results)
make
sudo make install
The wonder is, everything actually worked.
Per DBMail INSTALL, I added this to /etc/postfix/main.cf:
local_recipient_maps = pgsql:/etc/postfix/sql-recipients.cf
Here's my mail.log file:
Jul 14 23:07:47 boomhaus postfix/smtpd[11496]: fatal: unsupported dictionary type: pgsql Jul 14 23:07:48 boomhaus postfix/master[9889]: warning: process /usr/libexec/postfix/smtpd pid 11496 exit status 1 Jul 14 23:07:48 boomhaus postfix/master[9889]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling Not only did postfix's original PGSQL README not mention anything about the patch (leading me to believe it may no longer be necessary), the patch seems pretty outdated. I tried several different compile options without the patch first.
QUESTION #1
How important is having pgsql support compiled into postfix, from a DBMail perspective?
QUESTION #2
Any ideas what I'm doing wrong?
Thanks,
ross
_______________________________________________
Dbmail mailing list
Dbmail@dbmail.org
https://mailman.fastxs.nl/mailman/listinfo/dbmail

_______________________________________________
Dbmail mailing list
Dbmail@dbmail.org
https://mailman.fastxs.nl/mailman/listinfo/dbmail


_______________________________________________
Dbmail mailing list
Dbmail@dbmail.org
https://mailman.fastxs.nl/mailman/listinfo/dbmail

_______________________________________________
Dbmail mailing list
Dbmail@dbmail.org
https://mailman.fastxs.nl/mailman/listinfo/dbmail


_______________________________________________
Dbmail mailing list
Dbmail@dbmail.org
https://mailman.fastxs.nl/mailman/listinfo/dbmail



Reply via email to