Postfix + MySQL + PCRE + Berkeley DB + Cyrus SASL + STARTTLS
In my opinion, this is a match made in mail server heaven. Also, it is a total bitch to set up. Therefore, here it goes to be archived because I know I’ll forget how I did it otherwise and spend 5 hours banging my head on my desk come next year. Note: this all of course depends on where these files are on YOUR system. I installed this on a Redhat / Fedore Core 8 x86_64 machine.
Prerequisites:
1. Read http://www.postfix.org/INSTALL.html
2. From above, you need to create a user/group for postfix BEFORE you try to install postfix.
3. Create a group for postdrop
4. My /var/log/yum.log shows that I installed all of these packages today before I got Postfix to compile. You may or may not need all of them: db4 db4-utils cyrus-imapd mysql-libs pam_mysql zlib zlib-devel openssl-devel db4-devel pcre cyrus-sasl-devel pcre-devel cyrus-sasl-sql
And now, to compile Postfix:
[vic@ares:/tmp$] wget ftp://postfix.cloud9.net/official/postfix-2.5.2-RC1.tar.gz
–02:13:44– ftp://postfix.cloud9.net/official/postfix-2.5.2-RC1.tar.gz
=> `postfix-2.5.2-RC1.tar.gz’
Resolving postfix.cloud9.net… 168.100.10.85
Connecting to postfix.cloud9.net|168.100.10.85|:21… connected.
Logging in as anonymous … Logged in!
==> SYST … done. ==> PWD … done.
==> TYPE I … done. ==> CWD /official … done.
==> PASV … done. ==> RETR postfix-2.5.2-RC1.tar.gz … done.
Length: 3,157,250 (3.0M) (unauthoritative)
100%[=================================================>] 3,157,250 7.27M/s
02:13:46 (7.27 MB/s) - `postfix-2.5.2-RC1.tar.gz’ saved [3157250]
[vic@ares:/tmp$] tar zxf postfix-2.5.2-RC1.tar.gz
[vic@ares:/tmp$] cd postfix-2.5.2-RC1
[vic@ares:/tmp/postfix-2.5.2-RC1$] make tidy
<snip>
[vic@ares:/tmp/postfix-2.5.2-RC1$] make -f Makefile.init makefiles \
‘CCARGS=-DHAS_MYSQL -I/usr/include/mysql \
-DHAS_PCRE -I/usr/include -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl \
-DUSE_TLS -I/usr/include/openssl -DHAS_DB -I/usr/include/db4′ \
‘AUXLIBS=-L/usr/lib64/mysql -lmysqlclient -lz -lm -L/usr/lib64 -lpcre \
-L/usr/lib/sasl2 -lsasl2 -L/usr/lib64/openssl -lssl -lcrypto -L/usr/lib64 -ldb’
<snip>
[vic@ares:/tmp/postfix-2.5.2-RC1$] make
<snip>
[vic@ares:/tmp/postfix-2.5.2-RC1$] sudo su
[root@ares:/tmp/postfix-2.5.2-RC1#] make install
And follow the instructions. I just stuck with all the default options. Tits on a cracker.
References:
http://www.postfix.org/INSTALL.html
You’re currently reading “Postfix + MySQL + PCRE + Berkeley DB + Cyrus SASL + STARTTLS”, an entry on sudo make me a sandwich
- Published:
- 04.03.08 / 1am
- Category:
- Linux
