Tuesday, January 4, 2011

Sendmail Notes

To restrict relaying from particular domains and subnets:
- Create or edit a file names /etc/mail/access

- Add lines similar to the following:
Connect:localhost.localdomain RELAY
Connect:localhost RELAY
From:xyz.com RELAY
10 RELAY
Connect:127.0.0.1 RELAY
Connect:10. RELAY
Connect:172.25 RELAY

- Save the file and run :
# makemap hash /etc/mail/access.db < /etc/mail/access


To define the mail relay for each domain:
- Edit the file /etc/mail/mailertable

- Add lines similar to the following:
abc.com smtp:[10.50.1.10]
xyz.com smtp:[10.50.1.10]

- Save the file and run this:
makemap hash /etc/mail/mailertable < /etc/mail/mailertable

No comments:

Post a Comment