LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   relaying in sendmail (https://www.linuxquestions.org/questions/linux-networking-3/relaying-in-sendmail-150756/)

spikes57 02-26-2004 10:15 AM

relaying in sendmail
 
Hi All,
I'm trying to set up my sendmail to relay mail on to an ms exchange box. all i want is for the server to accept mail and pass it on, but there are so many files, access . local-host-names . mailertable . etc can anyone just give me the basics eg. put the domain to relay in the access file.

also do i need to create local accounts for each user on the relayed domain? or will the relay just accept all mail addressed with that domain?

cheers,

spikes

benjithegreat98 02-26-2004 11:07 AM

You don't need to create accounts. I do the same thing to a Lotus Domino Server to filter out spam.

You will need to add the domain name to the "relay-domains" file
yourcompany.net

You will need to add something like this to the mailertable file
.yourcompany.net smtp:10.22.15.2

(the smtp:10.22.15.2 is where your exchange server is).

You need to add and internal ip address or range in your access files
10.22.15 RELAY

Some other complications you may experience are internal DNS problems. If fixed that by using bind on the spam filter to get stuff flowing where it should.

You may have to change some stuff in your sendmail.cf/sendmail.mc file, but I can't remember for sure. I guess it depends on your default setup.

spikes57 02-27-2004 04:05 AM

thats some great advice with only one problem i dont have a 'relay-domains' file. i'm using the sendmail that comes default with fedora core 1.

your other points are noted though and i'll start aultering stuff based on them, please post back if you know what sendmail 8.12.10 uses instead of 'relay-domains'


many thanks,

spikes

linuxxed 02-27-2004 06:54 AM

Re: relaying in sendmail
 
Quote:

Originally posted by spikes57
Hi All,
I'm trying to set up my sendmail to relay mail on to an ms exchange box. all i want is for the server to accept mail and pass it on, but there are so many files, access . local-host-names . mailertable . etc can anyone just give me the basics eg. put the domain to relay in the access file.

also do i need to create local accounts for each user on the relayed domain? or will the relay just accept all mail addressed with that domain?

cheers,

spikes

sendmail.org has some excellent documentation.

All you would need is a relay domain because sendmail comes with anti relaying features.

FEATURE(RELAY_DOMAIN_FILE) in sendmail.mc ... check the syntax on sendmail.org. Compile using m4

In the relay domain file which is normally in /etc/mail/ , you need to add the domains which you want to relay. DO NOT add these domains to local-host-names or your sendmail will think that these accounts exist on the same box.

If the domains to which mails are sent have appropriate MX records then you don't even need a mailertable which is used to override MX records.

No you do not need to create any local accounts.

Again check docs on sendmail.org esp the faqs. check the null client configuration too.

benjithegreat98 02-27-2004 08:30 AM

It should also be pointed out that sendmail is upto sendmail 8.10.11

ftp://ftp.sendmail.org/pub/sendmail/...8.12.11.tar.gz

Always good to be up to date. Fedora may have an rpm.. They do:

http://download.fedora.redhat.com/pu...1-3.2.i386.rpm
http://download.fedora.redhat.com/pu...1-3.2.i386.rpm

spikes57 02-27-2004 10:05 AM

hey,
at the moment i do not want to upgrade my sendmail as i dont know what effect it will have on my mail filters, but i'll look into it soon.

but anyway, i have cleared so of the files as suggested and i am going to add indiviuals to the access file. as i cant get the relay domains file to exist. it works for me anyhow as i dont want unknow mail to reach the exchange box.

cheers for your help, i now know a little more about all the files in /etc/mail

spikes

benjithegreat98 02-27-2004 10:44 AM

Quote:

Originally posted by spikes57
. as i cant get the relay domains file to exist.
Just create the file yourself and add the stuff you want. Then restart sendmail.


All times are GMT -5. The time now is 04:59 PM.