This is topic Exim in forum Ask a Geek! at The Geek Culture Forums.


To visit this topic, use this URL:
http://www.geekculture.com/cgi-bin/ultimatebb/ultimatebb.cgi?ubb=get_topic;f=12;t=001705

Posted by TonyRad (Member # 1448) on July 05, 2005, 13:06:
 
Hello everybody.

I'm having a small problem with a service I'm trying to run on one of our servers at work, I've been racking my brains on this one for awhile but just can't get it to work right.

It's called exim, it's a mail sender which replaces sendmail. Basically it isn't sending the mail it is supposed to be receiving from a php form on our web site. I think the issue lies along the lines of the PID, when I start the service it creates a PID file which stores the number so it can close it using that number. Well, the number it stores in the file is a different number than what PS shows me. It's always off by 3. Does anybody know how to fix that?

Better yet does anybody know how to fix the issue of it sending mail?

Or even just a good website that would help me a little more (I've been to a lot of sites already but maybe you may know of some I missed...)

Thanks a lot guys (and gals).

Tony Rad
 
Posted by csk (Member # 1941) on July 05, 2005, 17:38:
 
Hmm, what do the log files say? On my Debian install at home, they live in /var/log/exim, they might be somewhere else depending on what distro you are running.
 
Posted by TonyRad (Member # 1448) on July 05, 2005, 18:29:
 
I'm running it on Debian as well.

The 2 errors that keep getting repeated are:

2005-07-05 19:23:14 1Dpuu8-0006pa-00 == [email protected] T=local_delivery defer (-43): Retry time not yet reached

2005-07-05 19:23:14 1DoIKp-0006OM-00 Message is frozen

Thanks for the help CSK.
 
Posted by csk (Member # 1941) on July 05, 2005, 18:42:
 
Hmm, OK, so it's had trouble delivering them in the past. So if you were to run (as root or via sudo)
code:
exim -bp

you'd see a list of queued messages, right?

So, you can force it to try to redeliver them immediately via
code:
exim -M messageid

Then check out what the error messages are.

Also it might be useful to run some tests directly from the command line to verify whether the problem is exim itself, or between exim and php.

So, if you're trying to email to [email protected], just do
code:
echo "test mail" | mail [email protected]

from the command line, and if that works OK, then exim itself isn't the problem, it's the interface between exim and php
 
Posted by TonyRad (Member # 1448) on July 05, 2005, 22:13:
 
I can actually send mail via exim. I managed to send it to my local account, network account, and external account. The lady who is doing our PHP keeps saying it's something wrong with exim and not the PHP.

I didn't test the first two things you mentioned, I'll do that first thing tomorrow morning though.

Thanks!
 
Posted by csk (Member # 1941) on July 05, 2005, 22:20:
 
quote:
Originally posted by TonyRad:
I can actually send mail via exim. I managed to send it to my local account, network account, and external account. The lady who is doing our PHP keeps saying it's something wrong with exim and not the PHP.

Well, if it works fine not through PHP, there's something wrong there somewhere. Hopefully with the right error messages you can work out the problem, might be as simple as the PHP is sending it to email address(es) slightly different to what you expect (eg omitting the domain name and just sending it to a username).
 
Posted by Tut-an-Geek (Member # 1234) on July 06, 2005, 04:59:
 
Can't you just make her use SMTP for sending the mail?
 
Posted by TonyRad (Member # 1448) on July 06, 2005, 07:14:
 
See I had her add my external email to her php list and I'm not getting any mail to that either.

Exim is supposed to handle the SMTP, she is using the mail() function which should be calling exim and sending it to Communigate, which then sends it to exchange. (I know, it's a big mess of email).

On our old mail server we used sendmail and that worked fine. I guess if we wanted to we could configure sendmail to work on the new server but that is another foreign land for me and this is supposed to be working by today.

Thanks guys
 
Posted by TonyRad (Member # 1448) on July 06, 2005, 07:26:
 
I forced sending the messages. This is what my log shows:

2005-07-06 09:18:42 1DpyPx-0000Eu-00 == [email protected] T=local_delivery defer (13): Permission denied: failed to chdir to /var/www
2005-07-06 09:19:12 1Dnvqw-0004xa-00 Unfrozen by forced delivery
2005-07-06 09:19:12 1Dnvqw-0004xa-00 => tradkiewicz <[email protected]> D=localuser T=local_delivery


another error in log:

** [email protected] R=smarthost T=remote_smtp: SMTP error from remote mailer after RCPT TO:<[email protected]>: host csiserver.cstone.local [172.20.20.201]: 550 5.7.1 Unable to relay for [email protected]


The email I received in my mailbox says this:

From MAILER-DAEMON Wed Jul 06 09:19:12 2005
Envelope-to: [email protected]
From: Mail Delivery System <[email protected]>
To: [email protected]
Subject: Message frozen
Date: Thu, 30 Jun 2005 05:01:02 -0500

Message 1DnvqV-0004xE-00 has been frozen.
The sender is <[email protected]>.

The following address(es) have yet to be delivered:
[email protected] <[email protected]>: mailbox /var/spool/mail/mearnhart has wrong uid (1000 != 1029)


mearnhart is another user on the system who actually just left and should be removed from the system.

It looks like this is all going within our mailserver (dmz1) as well.


Thanks
 
Posted by csk (Member # 1941) on July 06, 2005, 08:29:
 
Hmm, not sure about the second one, but the first one looks to be a permissions issue. Presumably the PHP stuff is sitting somewhere under /var/www and the user exim is running as (mail on my system) doesn't have access, which could cause some problems, in some circumstances.

Any Linux gurus want to step in?
 
Posted by TonyRad (Member # 1448) on July 06, 2005, 08:44:
 
I found her php code is within /var/www/html/ perhaps it needs to be redirected to /var/www/html/ instead of /var/www/ ???
 
Posted by TonyRad (Member # 1448) on July 06, 2005, 09:02:
 
I've also noticed that it's primarily the apache account which is not receiving the mails. I sent an email to myself and apache, I received it, apache did not.
 
Posted by TonyRad (Member # 1448) on July 06, 2005, 19:53:
 
Thanks for the help guys. I somehow managed to get it to work. It's not sending emails to the external world too well at the moment, but it is sending them internally now, so that will work for the time being.

Thanks again!
Tony Rad
 


© 2015 Geek Culture

Powered by Infopop Corporation
UBB.classicTM 6.4.0