Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I get sendmail to act as my outgoing mail server for one or more domains?

Mail Relaying

How do I get sendmail to act as my outgoing mail server for one or more domains?

by  PcLinuxGuru  Posted    (Edited  )
First edit the /etc/mail/access file so that ALL IP's and Domains you want to ALLOWED to be relayed. I recommend rejecting all relaying then allowing certain IP's and domains.

Here is an example:

ALL REJECT
localhost.localdomain RELAY
localhost RELAY
127.0.0.1 RELAY
mydomain RELAY
myotherdomains RELAY
mydomainipblock RELAY
myexchangeserveripaddress RELAY

After you are done adding your domains, IP Blocks, and IP's you need to save the file and rebuild the access database. You can rebuild the database by typing this at the command prompt:

makemap hash /etc/mail/access < /etc/mail/access

Restart sendmail: (/etc/init.d/sendmail restart)

You should now be able to relay your email.
Register to rate this FAQ  : BAD 1 2 3 4 5 6 7 8 9 10 GOOD
Please Note: 1 is Bad, 10 is Good :-)

Part and Inventory Search

Back
Top