You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

status=deferred (connect to 127.0.0.1[127.0.0.1]: Connection refused)

I have been having a **** of time with a brand new installation of 10.5.6 server, and I thought I might share my findings with the mail server.

Basically I enabled the mail server with what I deemed to be the correct settings and while it worked with the email spam filters and virus scanning off no messages would move when it was on. The error received in the logs was

"Jan 13 12:22:34 macserver postfix/smtp[56552]: connect to 127.0.0.1[127.0.0.1]: Connection refused (port 10024)
Jan 13 12:22:34 macserver postfix/smtp[56552]: 19F0F9C15E: to=<admin@example.org>, relay=none, delay=0.19, delays=0.17/0.02/0/0, dsn=4.4.1, status=deferred (connect to 127.0.0.1[127.0.0.1]: Connection refused)
".

Looking at that, I found it was attempting to connect to port 10024 and doing a #sudo netstat -an | grep 10024 I found that, yes indeed it was not open and nothing was using it.

After scouring around in google I found that amavisd was the problem and I had come to the conclusiong that it was just not launching I then found the following in /var/log/system.log

Jan 14 08:52:05 macserver org.amavis.amavisd[93352]: The value of variable $myhostname is "macserver", but should have been
Jan 14 08:52:05 macserver org.amavis.amavisd[93352]: a fully qualified domain name; perhaps uname(3) did not provide such.
Jan 14 08:52:05 macserver org.amavis.amavisd[93352]: You must explicitly assign a FQDN of this host to variable $myhostname
Jan 14 08:52:05 macserver org.amavis.amavisd[93352]: in amavisd.conf, or fix what uname(3) provides as a host's network name!

I then edited /etc/amavisd.conf and found the following line:

$myhostname = 'mail.example.com'; # must be a fully-qualified domain name!

and changed it to my hostname. I then attempted to load it again using

$sudo /bin/launchctl load /System/Library/LaunchDaemons/org.amavis.amavisd.plist

and found the following in /var/log/system.log

Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: usage: ps [-AaCcEefhjlMmrSTvwXx] [-O fmt | -o fmt] [-G gid[,gid...]]
Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: [-u]
Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: [-p pid[,pid...]] [-t tty[,tty...]] [-U user[,user...]]
Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: ps [-L]
Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: Pid_file "/var/amavis/amavisd.pid" already exists. Overwriting!
Jan 14 08:52:20 macserver org.amavis.amavisd[93370]: Suicide () TROUBLE in pre loophook: No TEMPBASE directory: /var/amavis/tmp at /usr/bin/amavisd line 7881.

$sudo mkdir -p /var/amavis/tmp
$sudo chown _amavisd /var/amavis/tmp
$sudo /bin/launchctl load /System/Library/LaunchDaemons/org.amavis.amavisd.plist

I spent hours on this, and I felt the need to post it somewhere so future people could have an easier time with it. I find the mail implementation in osx 10.4 and 10.5 lacking and a lot of work needs to be done on it to make it easy for those of us whom are not as tech savy.

thanks

imac, Mac OS X (10.5.6), also use freebsd, 10.5 and 10.4 server

Posted on Jan 13, 2009 2:14 PM

Reply
2 replies

Jan 13, 2009 2:19 PM in response to w4r_ch1ld

Some extra notes in relation to this

$myhostname = 'mail.example.com'; # must be a fully-qualified domain name!

you will find that the above line is commented out, make sure you uncomment it.

also, the last error in system.log

Jan 14 08:52:20 macserver org.amavis.amavisd93370: usage: ps -AaCcEefhjlMmrSTvwXx -o fmt [-G gid http://,gid...
Jan 14 08:52:20 macserver org.amavis.amavisd93370: -u
Jan 14 08:52:20 macserver org.amavis.amavisd93370: [-p pid http://,pid... [-t tty http://,tty... [-U user http://,user...
Jan 14 08:52:20 macserver org.amavis.amavisd93370: ps -L
Jan 14 08:52:20 macserver org.amavis.amavisd93370: Pid_file "/var/amavis/amavisd.pid" already exists. Overwriting!
Jan 14 08:52:20 macserver org.amavis.amavisd93370: Suicide () TROUBLE in pre loophook: No TEMPBASE

is still occurring but does not seem to effect the running of amavisd.

status=deferred (connect to 127.0.0.1[127.0.0.1]: Connection refused)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.