LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-16-2007, 07:51 AM   #1
barrycogan
LQ Newbie
 
Registered: Mar 2007
Posts: 5

Rep: Reputation: 0
Question Linux mail server question please help


Hi all,

I have a dedicated server with a mail server on it. However we have been experiencing troubles with mails sent from not delivering to a lot of hosts. I believe it is something to do with the server not being a fully qualified domain. The server is running Debian Sarge Linux.

The solution we were thinking of was to change the server to just be a relay to the hosting company's pop mail account for the domains we have registered. Would this get around our client's filters? Also is it difficult to do?

Does anyone have any better ideas of what we could do? I am not used to linux so any advice in this matter would be much appreciated!

Best regards and thank you
 
Old 03-16-2007, 09:31 AM   #2
Sagebrush Gardener
LQ Newbie
 
Registered: Mar 2007
Posts: 29

Rep: Reputation: 15
> we have been experiencing troubles with mails sent from not delivering to a lot of hosts.

What troubles exactly? Are you getting bounce messages? If so, the bounce message usually explains exactly what the problem is if you read it closely.

Also, look at /var/log/maillog. It will usually contain helpful clues.

Is reverse DNS working for your server's IP address? Many mail servers reject connections from servers that do not have valid reverse DNS.
 
Old 03-16-2007, 10:02 AM   #3
barrycogan
LQ Newbie
 
Registered: Mar 2007
Posts: 5

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Sagebrush Gardener
> we have been experiencing troubles with mails sent from not delivering to a lot of hosts.

What troubles exactly? Are you getting bounce messages? If so, the bounce message usually explains exactly what the problem is if you read it closely.

Also, look at /var/log/maillog. It will usually contain helpful clues.

Is reverse DNS working for your server's IP address? Many mail servers reject connections from servers that do not have valid reverse DNS.
The mails seem to send fine but 50% of the clients dont get the mail. below is an example form the mail.log file.

Code:
Mar 14 15:04:17 healthcarenetwork sm-mta[10135]: l2EF4HWE010133: to=<*snip*>, ctladdr=<www-data@healthcarenetwork> (33/33), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, pri=121363, relay=scan5.dcu.ie. [136.206.1.27], dsn=5.5.2, stat=Service unavailable
I am new to linux administration Were where might I find the bounced messages?

I will check out the reverse DNS. Does anyone know where I a good tutorial site is for a "newbie"?

[edit]
Reverse DNS lookup can't resolve the ip address of the server. How do I solve this?

Last edited by barrycogan; 03-16-2007 at 12:18 PM.
 
Old 03-16-2007, 01:25 PM   #4
Sagebrush Gardener
LQ Newbie
 
Registered: Mar 2007
Posts: 29

Rep: Reputation: 15
> relay=scan5.dcu.ie. [136.206.1.27], dsn=5.5.2, stat=Service unavailable

Not a lot to see there. But you know that you are connecting to the recipient's server and they don't like you for some reason.

> where might I find the bounced messages?

The bounce messages would be sent to the return address of the email that you sent. Generally that would be the address in the "From:" field of your outgoing email.

> Reverse DNS lookup can't resolve the ip address of the server.

There is a good chance that this is why other mail servers don't like you. Checking for valid reverse DNS is a commonly used filter to reduce incoming spam.

> How do I solve this?

Your reverse DNS needs to be configured by whoever administers the DNS service for your network. You can usually find that out by doing "whois mydomain.com" (though sometimes forward DNS and reverse DNS will be administered in different places). Look for the "Domain servers" information. Hopefully the reverse DNS is served by a DNS server that is under your control. If not, you will have to beg your ISP or whoever administers this information to do it for you.
 
Old 03-21-2007, 11:29 AM   #5
barrycogan
LQ Newbie
 
Registered: Mar 2007
Posts: 5

Original Poster
Rep: Reputation: 0
> relay=scan5.dcu.ie. [136.206.1.27], dsn=5.5.2, stat=Service unavailable

Not a lot to see there. But you know that you are connecting to the recipient's server and they don't like you for some reason.

Quote:
Originally Posted by Sagebrush Gardener
> where might I find the bounced messages?

The bounce messages would be sent to the return address of the email that you sent. Generally that would be the address in the "From:" field of your outgoing email.
ah! That could be a problem considering the email address does not exist outside of a php script on that server.

Quote:
Originally Posted by Sagebrush Gardener
> Reverse DNS lookup can't resolve the ip address of the server.

There is a good chance that this is why other mail servers don't like you. Checking for valid reverse DNS is a commonly used filter to reduce incoming spam.

> How do I solve this?

Your reverse DNS needs to be configured by whoever administers the DNS service for your network. You can usually find that out by doing "whois mydomain.com" (though sometimes forward DNS and reverse DNS will be administered in different places). Look for the "Domain servers" information. Hopefully the reverse DNS is served by a DNS server that is under your control. If not, you will have to beg your ISP or whoever administers this information to do it for you.
OK I have the reverse lookup fixed. The server ip address now resolves to "healthcarenetwork.eu"
Top Level Domain: "healthcarenetwork.eu"

Apahe2ctl is happy repooting now and seems to be a fully qualifed domain name

however mails are still not getting through to hotmail or yahoo addresses but they get through fine to gmail.

Could it be possible that once a server is blacklisted that that even after you fix the FQDN that the server will stay on the black list?
 
Old 03-21-2007, 11:29 PM   #6
Sagebrush Gardener
LQ Newbie
 
Registered: Mar 2007
Posts: 29

Rep: Reputation: 15
> however mails are still not getting through to hotmail
> or yahoo addresses but they get through fine to gmail.

Hmm...

It's possible that they are doing a stricter DNS check. i.e. after resolving the reverse DNS to healthcarenetwork.eu, they then look up healthcarenetwork.eu to be sure it resolves back to the original IP address. But a lot of servers fail this test, so it is not used much.

Or as you say, you may have gotten blacklisted. You can check your blacklist status here:

http://www.senderbase.org/search?sea...String=1.2.3.4

Put in the IP address of your mail server instead of 1.2.3.4.

But you will have a better chance of solving this if you can see the bounce messages. You said...

> the email address does not exist outside of a php
> script on that server.

Still, the PHP script should be able to set the return address of the outgoing emails to a valid email address. (In fact, if it does not have at least a valid domain in the return address, that could be the problem.) I usually set it to something like donotreply@mydomain.com. Normally I send mail for this address to /dev/null using the aliases file. But for troubleshooting, you could alias this to a real email address so you could see the bounce messages. They should tell you exactly what the problem is.
 
Old 03-22-2007, 07:59 AM   #7
barrycogan
LQ Newbie
 
Registered: Mar 2007
Posts: 5

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Sagebrush Gardener
Or as you say, you may have gotten blacklisted. You can check your blacklist status here:

http://www.senderbase.org/search?sea...String=1.2.3.4

Put in the IP address of your mail server instead of 1.2.3.4.
Thankfully the server is not blacklisted.


Quote:
Originally Posted by Sagebrush Gardener
But you will have a better chance of solving this if you can see the bounce messages. You said...

> the email address does not exist outside of a php
> script on that server.

Still, the PHP script should be able to set the return address of the outgoing emails to a valid email address. (In fact, if it does not have at least a valid domain in the return address, that could be the problem.) I usually set it to something like donotreply@mydomain.com. Normally I send mail for this address to /dev/null using the aliases file. But for troubleshooting, you could alias this to a real email address so you could see the bounce messages. They should tell you exactly what the problem is.
No bounce messages are returning.

Hotmail seems to be the only service that is not getting the mails now. (Yahoo were indeed getting messages sent by me yesterday. the person I was asking to check missed it yesterday)

The log file data showing up at the moment for that address is:

Code:
Mar 22 12:53:09 healthcarenetwork sendmail[8954]: l2MCr9nZ008954: to=barry_ac@hotmail.com, ctladdr=www-data (33/33), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31186, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (l2MCr9XD008955 Message accepted for delivery)

Mar 22 12:53:11 healthcarenetwork sm-mta[8957]: l2MCr9XD008955: to=<barry_ac@hotmail.com>, ctladdr=<www-data@healthcarenetwork.hosting365.com> (33/33), delay=00:00:02, xdelay=00:00:02, mailer=esmtp, pri=121443, relay=mx2.hotmail.com. [65.54.244.40], dsn=2.0.0, stat=Sent ( <200703221253.l2MCr9nZ008954@healthcarenetwork.hosting365.com> Queued mail for delivery)


Mar 22 13:27:21 healthcarenetwork sendmail[9037]: l2MDRLF1009037: to=barry_ac@hotmail.com, ctladdr=www-data (33/33), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31186, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (l2MDRLXs009038 Message accepted for delivery)

Mar 22 13:27:23 healthcarenetwork sm-mta[9040]: l2MDRLXs009038: to=<barry_ac@hotmail.com>, ctladdr=<www-data@healthcarenetwork.hosting365.com> (33/33), delay=00:00:02, xdelay=00:00:02, mailer=esmtp, pri=121443, relay=mx2.hotmail.com. [65.54.245.40], dsn=2.0.0, stat=Sent ( <200703221327.l2MDRLF1009037@healthcarenetwork.hosting365.com> Queued mail for delivery)
From what I could gather form searching in google the "Queued mail for delivery" is deemed a success message. Yet the message does not arrive to the inbox for the email address.

Any suggestions?
 
Old 03-22-2007, 04:43 PM   #8
Sagebrush Gardener
LQ Newbie
 
Registered: Mar 2007
Posts: 29

Rep: Reputation: 15
Quote:
From what I could gather form searching in google the "Queued mail for delivery" is deemed a success message.
That is correct. "stat=Sent" indicates a successful delivery. Your server has done its job and the message is now in the hands of the recipient's server.

If hotmail responds with "Queued mail for delivery", that means that your message is now in hotmail's delivery queue. It could be there for quite a while before reaching the recipient's mailbox, depending on how smoothly hotmail is running at the time.

For testing purposes, you might also send a regular email to your target hotmail address at the same time and see how long it takes for that to get through.
 
Old 03-23-2007, 06:52 AM   #9
barrycogan
LQ Newbie
 
Registered: Mar 2007
Posts: 5

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Sagebrush Gardener
That is correct. "stat=Sent" indicates a successful delivery. Your server has done its job and the message is now in the hands of the recipient's server.

If hotmail responds with "Queued mail for delivery", that means that your message is now in hotmail's delivery queue. It could be there for quite a while before reaching the recipient's mailbox, depending on how smoothly hotmail is running at the time.

For testing purposes, you might also send a regular email to your target hotmail address at the same time and see how long it takes for that to get through.
if I send a mail from the Hosting company's pop account associated with the no-reply@createandinnovate.eu address it gets to hotmail fine. If I send via the server, it says that queued for delivery.

So, I did some digging and discovered that one needs to have a senderid created for identification my Microsoft servers. This ensures safe delivery to a hotmail/msn inbox. It requires a modification to the DNS record of the server.

info on it here: MSN Postmaster Guidelines - Section 4: Authenticate your outbound e-mail

Any different solutions? Or should I just run with this Microsoft option?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting 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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Configure & Connect a Linux mail server from a windows mail clients digihall7 Linux - Networking 4 10-23-2006 12:21 PM
how to configure Linux mail client with existing mail server running on WindowsXP? Senthilvnr Linux - Networking 1 07-11-2006 12:02 AM
linux mail server newbie question threegig Linux - Newbie 2 05-16-2006 03:39 AM
can we configure a Linux server with mail server,file server and web server kumarx Linux - Newbie 5 09-09-2004 06:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:03 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration