Sendmail relaying, smarthost

I have splunk set up to send mail when certain events happen, and the only mailserver (apparently) that it can use is sendmail. All I want to do is have sendmail forward mail on to our exchange server, roi-mail-01.theroi.com (resolves fine with nslookup), however I have been unable to do that and really need some help. I have in my sendmail.mc this line:
             define(`SMART_HOST',`roi-mail-01.theroi.com')
Which shows up in sendmail.cf as
             DSroi-mail-01.theroi.com
I also have theroi.com added to relay-domains. However, when Sendmail tries to send out mail, I get these in /var/log/mail.log:
             Nov 13 11:38:18 roi-compliance-01 sm-mta[23421]: mADGcI6u023421: <julius@theroi.com>... User unknown
             Nov 13 11:38:18 roi-compliance-01 sm-mta[23421]: mADGcI6u023421: from=<splunk@localhost>, size=3073, class=0,
             nrcpts=0, proto=ESMTP, daemon=MTA-v4, relay=localhost [127.0.0.1]
And I never receive the mail. Any ideas?


sendmailmc
sendmailcf
relay-domains
LVL 1
domgelatoAsked:
Who is Participating?
 
fosiul01Connect With a Mentor Commented:
have a look at this tutorial :

http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch21_:_Configuring_Linux_Mail_Servers#How_To_Configure_Linux_Sendmail_Clients


you can test it, try to send email from root user , you wil see email gone through

and also remember : from exchange serve, you will have to give this linux pc permission to send email other wise exchagne will not relay any emails

0
 
fosiul01Commented:
have you create the mailing list in aliases file ??
and have you edited you virtual table for what to do with recived mail ??
0
 
domgelatoAuthor Commented:
I have not configured either of those files, however I thought that since I'm sending to an email address and not a user that I wouldn't have to. I'm not sure what I would be putting in the aliases file, and I don't even have an /etc/mail/virtualusertable.
0
 
domgelatoAuthor Commented:
alright, got it, I feel like an idiot. I had put our local domain name in local-host-names. Took it out and it worked, clearly it was just redirecting mail to itself instead of using the smarthost since I told it that itself was our local domain. But I got the description of local-host-names from the guide you linked to, so thanks you very much!
0
 
domgelatoAuthor Commented:
Alright, got it, I feel like an idiot. I had put our local domain name in local-host-names. Took it out and it worked, clearly it was just redirecting mail to itself instead of using the smarthost since I told it that itself was our local domain. But I got the description of local-host-names from the guide you linked to, so thanks you very much!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.