Milter Approach
Архива has an embedded Postfix milter server that by default listens on port 8092. The instructions below configure Postfix to forward milter traffic to Архива's milter server.
Make sure you are using Postfix 2.4.6 or greater.
Архива Configuration
- Click Configuration->Listeners.
- Select Milter Listener in the drop down and then click the New Listener button.
- Check "Listen for incoming Sendmail/Postfix requests"
- Leave the Sendmail Milter port as 8092
- Click Save
Postfix Configuration
- Add the following to Postfix’s main.cf file:
smtpd_milters = inet:127.0.0.1:8092
(if Архива is running on a remote server, replace 127.0.0.1 with the ip address of the server where Архива is running)
- Restart postfix
Note: If you want Spamassasin to filter out the SPAM before it hits Архива, configure Spamassassin as a milter (Google the topic for info on how to do this)
Then, specify your milter configuraiton as follows:
In Postfix 2.6, milter_default_action can be set to hold, meaning if the archive server goes down, the messages will be placed indefinitely in a hold queue. Once the archiving service is restored, the administrator can intervene and process the messages in the hold queue.
Always BCC Approach
This approach involves configuring Postfix to send copies of all emails to a specific journal mailbox and then configuring Архива to retrieve emails from the mailbox using IMAP.
Архива Configuration
- Click Configuration->Listeners.
- Select SMTP Listener in the drop down and then click the New Listener button.
- Check "Listen for incoming SMTP/Exchange requests"
- Leave the SMTP port as 8091
- Click Save
To accomplish this:
- Create a new mailbox called "journal" and set a password (on Unix, you would typically use the useradd command to create a new user)
Add the following line to Postfix's main.cf:
always_bcc = journal@domain.com (replace journal@domain with your domain)
- In Архива, select Connections -> IMAP Client -> New Connection. Add a new IMAP journal account connection to the IMAP service running on the Postfix server.
- Optionally: enable IMAP Idle to receive message arrival notification as opposed to polling (if you later find archiving stops after a period, you will need to disable IMAP Idle again)