SendMail Configuration Files - Different Types
*)
Explain the functions of each configuration files in Sendmail.
- /etc/mail/access :The access database file is created to accept or reject mail from particular/selected domains.For eg., you may choose to reject all mail coming from known spammers, or to accept to relay all mail from your local network.since relaying is denied by default with the newer versions of sendmial.So this file is more like a anti-spam feature in sendmail.
localhost.localdomain
RELAY
localhost
RELAY
192.168.1.
OK
spammer@aol.com REJECT cyberspammer.com REJECT doctor.com 550 Doctor, whenever I eat Hormel products,
I feel a strong urge to throw up violently. What can I do about this?
Note:By default we have OK which means it accept the particular domain.
/etc/mail/aliases: An alias allows sendmail to redirect mail sent to given address. This mail can be redirected to another email address,a file, or piped through a program.Alias can only be set in local network.Any changes in this file will get updated after running make in /etc/mail to update your database.Eg:admin:root---> all mail sended to admin will be redirected to root.team1:shiju,rahul,ashley--->team1 is the mailbox which contain a set of alias list.So team1@example.com will redirect the mail to rahul,ashley and shiju.
- /etc/mail/local-host-names:It has a list of domain and hostnames sendmail is to be receiving mail for.[all local-host-names and domains]Eg:shiju.commail.shiju.com*.shiju.com
- /etc/mail/mailer.conf:It specifies which MTA is used in the mail server.Eg:Exim,Postix
- /etc/mail/mailertable:This file is used to route a domain to an different hosts or Simply for mail forwarding.For Example all mail coming from network 192.168. route to mail.shiju.com and all email for mydomain.com will be automatically forwarded to a mail server joe@mail.comEg:192.168. smtp:mail.shiju.commydomain.com smtp:joe@mail.com
- /etc/mail/sendmail.cf:Main configuration file for sendmail.Keep your Hands off unless you know what you are doing.Do all editing in sendmail.mc. Use “m4 sendmail.mc>sendmail.cf” command to update the changes.
-
/etc/mail/virtusertable:The
virtusertablemaps mail addresses for virtual domains and mailboxes to real mailboxes. These mailboxes can be local, remote, aliases defined in/etc/mail/aliasesor files.
Eg:
root@example.com root
shiju@example.com joe@www.domain.net
@example.com joe
Comments (1)
This is what I have been searching in many websites and I finally found it here. Amazing article. I am so impressed. Could never think of such a thing is possible with it.
Thailand VPS Server