Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > macOS > sendmail problem-help!!!

sendmail problem-help!!!
Thread Tools
apple4ever
Fresh-Faced Recruit
Join Date: Jan 2001
Location: Lancaster, PA 17601
Status: Offline
Reply With Quote
Jan 31, 2002, 11:57 PM
 
I have been banging my head against the wall trying to figure out this problem. I fixed last year when i got X originally, but now I can't remember what I did. I've searched the net, but I haven't come upon an answer. Can anybody help me? Here is the problem:

This shows up in my console:

Jan 31 22:53:57 localhost sendmail[925]: My unqualified host name (localhost) unknown; sleeping for retry

sendmail refuses to send anything out then. This is just on a single machine, and I am trying to get cron reports sent to my username. I had it working, but then I reinstalled OSX because of a disk problem. Now I can't fix it. Help!
Pennsylvania Patriot
Mac Lover
     
rw
Mac Enthusiast
Join Date: Dec 2000
Location: Kirkland, WA, USA
Status: Offline
Reply With Quote
Feb 2, 2002, 02:18 PM
 
Try this in Terminal:

<BLOCKQUOTE><font size="1"face="Geneva, Verdana, Arial">code:</font><HR><pre><font size=1 face=courier> chmod g-w /
chmod g-w /etc
chmod g-w /etc/mail </font>[/code]

I have to do this again each time I update OS X. As a security precaution, sendmail will not write to a group-writable directory. The above commands make the directories containing the mail file group-unwritable. (And each time you update OS X, the updater will make them group-writable again. *sigh*)

If that doesn't solve your problem, and if you are a fluent reader of Geek, you might look for a solution at http://www.sendmail.org.
Dang! I forgot to uncheck the "Show Signature" button again!
     
Camelot
Mac Elite
Join Date: May 1999
Location: San Jose, CA
Status: Offline
Reply With Quote
Feb 3, 2002, 01:51 AM
 
Originally posted by apple4ever:
<STRONG>
Jan 31 22:53:57 localhost sendmail[925]: My unqualified host name (localhost) unknown; sleeping for retry

</STRONG>
sendmail won't work if it can't resolve its own IP address. Chances are 90% of remote mail servers would probably reject the mail anyway, so it's not a bad thing.

The solution is in the sendmail.cf file. About 85 lines into the default sendmail.cf you'll see something like:

<font face = "courier">
# my official domain name

# ... define this only if sendmail cannot automatically determine your domain

#Dj$w.Foo.COM
</font>

(note, it tells you right there what the problem is)

Since sendmail cannot automatically determine your domain, you need to uncomment (remove the #) from the next line and add your server name. For example:

From:

#Dj$w.Foo.COM

to:

Djmail.mydomain.com

Then restart sendmail. It should now startup and run as 'mail.mydomain.com' (of course, you should enter your real domain). Note that your DNS will probably also need to work for remote servers to accept mail from this machine.
Gods don't kill people - people with Gods kill people.
     
   
Thread Tools
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 01:40 AM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,