Mail Server
Imap with Postfix, Pop3, Fetchmail, PopFile, and Procmail
Local Mail
to ensure that cron mail etc. gets picked up, edit /etc/crontab
MAILTO=anne@lydgate.lan
Check also that /etc/aliases is set to send root's mail to you -
root anne@lydgate.lan
Postfix
/etc/postfix/main.cf
especially lines:
# User configurable parameters
mydestination = $myhostname, localhost.$mydomain, $mydomain
myorigin = $mydomain
masquerade_domains = $mydomain
mynetworks = 192.168.0.0/24,127.0.0.0/8
mailbox_command = /usr/bin/procmail -Y
#SASL support for servers
#
#The following options set parameters needed for postfix
#to use SASl support for authentication of mail servers.
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous
/etc/postfix/sasl_passwd
#Access codes for smtpauth protocol
smtp.mailbox.co.uk lydgate.canne:passwd
#Then you run the command
postmap /etc/postfix/sasl_passwd
/etc/postfix/transport
lydgate.lan smtp[borg.lydgate.lan]
.lydgate.lan smtp[borg.lydgate.lan]
* smtp:[smtp.mailbox.co.uk]
.* smtp:[smtp.mailbox.co.uk]
cd /etc/postfix
postmap transport
Test local mail
Test external mail.
Any change to 'aliases' require eith
newaliases #or
postalias etc/aliases
Fetchmail
/home/anne/.fetchmailrc
Procmail
/home/anne/.procmailrc
Create ~/.forward
| /usr/bin/procmail
Enable the Services
Using chkconfig
chkconfig –add packagename
chkconfig – levels 345 packagename on
chkconfig –list packagename
PopFile
(I no longer use popfile, but it is an incredibly good tagger. It uses modified Bayesian filtering, and very quickly learns what is spam by your personal definition. See http://popfile.sourceforge.net/)
> OK - I've set popfile to listen on port 123, but I can't see how to change the kmail local account to > use that port. The direct access accounts have an obvious place to put a port number, but the local > one is not obvious.
Go to Settings Kmail configuration, Networking tab, Under accounts click on receiving, and then find your POP account for tiscali.co.uk. Click Modify. Under General, change the port to port 123. Then when you connect to Popfile on port 123, it will connect to host server on port 110, get your mail and
deliver it to your Kmail client.
> Fine - I can do that, but that's the account I was using before. It was the Local account that was > pulling via postfix. Are you saying that I can't do it that way now? Fetchmail is still trying to connect > on port 110. Is there a fetchmail config file we could alter?
Sorry, I forgot. In your .fetchmailrc file change this line:
with proto POP3
to read
with proto POP3 port 123
save it and run fetchmail and it should be fine.
Check the Firewall
> > and /etc/hosts.allow and tell me what is there?
>
> 192.168.0. 127.
Add this, just to be sure
ALL: 192.168.0.0/24 :ALLOW
That will allow all Local LAN traffic.
You can also add something like:
ALL: LOCAL :ALLOW
or even
ALL: .lydgate.lan :ALLOW
Dovecot
/etc/dovecot/dovecot.conf – some distros seem to put that in different places. In FC4 I found it in /etc/dovecot.conf.