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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sendmail issues - Solaris hardening

Status
Not open for further replies.

Cimm

Technical User
Feb 17, 2005
69
US
Hi, I have a problem which dont makes sense to me.
I am using Sun Solaris 5.9, hardening the security a little bit.
I have a working sendmail daemon running.
but, I want to turn that off and run it in crontab instead with sendmail -q parameters running every 15 minutes.

Which will just send out mail, not recieve any.

But once I turn the daemon off, it doesnt work. It stores the mail in /var/spool/clientmqueue

Any idea's or suggestion why the mails isnt being sent.
Once I activate the daemon the mails are sent.
 
Solaris does not need sendmail deamon running for sending mails. My Servers do not run sendmail but use mailx to send email to our Exchange MX. It's just the DNS entry for your domain, which must be set correctly.
I know, this does not answer your question but I think you won't need sendmail running at all

Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Thanks for the answer, and yes you are right the daemon doesnt need to run. That's what I want. But I figured it out after a while searching the files.

I always thought the settings were in sendmail.cf, however for sending files only the submit.cf needs to be modified.

In my case
# "Smart" relay host (may be null)
DSmy.yahoo.com

And set your crontab to
/usr/lib/sendmail -Ac -q

This works fine.

But thanks for the reply.
 
cool, btw. you do not need to set the smarthost if your domain (entry in /etc/resolv.conf) has set a MX record

Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Could you explain MX records?

my resolve.conf has

domain yahoo.com
nameserver 1.1.1.1
nameserver 1.1.1.2
nameserver 1.1.1.3

Have I missed something?

(the names and numbers are made up ) :)

And thanks again.
 
well, most users drive their own domain...

Code:
# more /etc/resolv.conf
domain mydomain.de
nameserver 10.43.17.2
nameserver 10.43.14.20
nameserver 10.43.30.20
# nslookup -type=MX mydomain.de
Server:  dnsserver.mydomain.de
Address:  10.43.17.2

kirchgruppe.de  preference = 10, mail exchanger = mailserver.mydomain.de
....

so sendmail will forward all mails to mailserver.mydomain.de by default (by default sendmail uses DNS)


Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
*** No mail exchanger (MX) records available for mydomain.com

Thats the message I get typing
nslookup -type=MX mydomain.com

This company runs an windows exchange mailserver. And I am forwarding all mails there.

So I guess I need to use smarthost relay then?
The smarthost line contains
exchange.mydomain.com

So if I understand you correctly, by default an MX record is setup, but if not used then you "fake" MX record by putting it in the smart host relay?
 
well, it's not a "fake". the sendmail guys coded this sequence: "get MX record from DNS, if this is empty check the smarthost entry"
You can setup sendmail.cf never asking DNS, since sometimes you have different MX for internal and external mail but only one DNS Server to ask (we do run an internal DNS Server and an internal MX and our ISP does host our external DNS and there is a MX in our Firewall)

Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Alright, thank you very much for the information.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top