Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Sat Jun 02, 2012 6:39 pm 
Offline
Senior Newbie

Joined: Mon Nov 28, 2011 11:59 pm
Posts: 13
Hi, all mail I send from PHP mail() is getting flagged as spam in Gmail and other email services. Any suggestions? Thank you in advance.


Top
   
 Post subject:
PostPosted: Sat Jun 02, 2012 7:02 pm 
Offline
Senior Member
User avatar

Joined: Tue Mar 17, 2009 5:11 am
Posts: 129
Location: UK
Have you set-up your reverse DNS?


Top
   
PostPosted: Sat Jun 02, 2012 7:17 pm 
Offline
Senior Member
User avatar

Joined: Sun Dec 27, 2009 11:12 pm
Posts: 1038
Location: Colorado, USA
hardwire wrote:
Any suggestions?

Ummmm....maybe provide some actual details? (although Mr.Nod's is a good guess)


Top
   
 Post subject:
PostPosted: Sat Jun 02, 2012 7:41 pm 
Offline
Senior Newbie

Joined: Mon Nov 28, 2011 11:59 pm
Posts: 13
Yes, I have already setup my reverse DNS. BTW, I'm using self hosted service (sendmail). Thanks.


Top
   
 Post subject:
PostPosted: Sat Jun 02, 2012 8:33 pm 
Offline
Senior Newbie

Joined: Mon Nov 28, 2011 11:59 pm
Posts: 13
I made another try to send mail to gmail account, it now goes to inbox. However, in hotmail account it still flagged as SPAM. Any ideas would be much appreciated.


Top
   
 Post subject:
PostPosted: Sat Jun 02, 2012 9:03 pm 
Offline
Senior Member
User avatar

Joined: Thu Nov 24, 2011 12:46 pm
Posts: 139
Location: Mesa AZ
Providing the actual email and domain would allow checking for possible issues.. Otherwise there are a lot of reasons why your email might be marked as spam.

Email marked as spam is normally a result of:

o Invalid mail server communication
o Improper use of headers
o Syntax errors in headers
o Improper HELO
o Invalid or improper rDNS
o Blocked or marked IP
o Poor reputation of host
o Improper SPF setting
o Incorrect DKIM Signature
...

If you want to send a PM, I can provide you with a test email address that you can send to to see what the issues might be.

_________________
Kevin a.k.a. Dweeber


Top
   
 Post subject:
PostPosted: Sat Jun 02, 2012 9:38 pm 
Offline
Senior Member
User avatar

Joined: Sun Dec 27, 2009 11:12 pm
Posts: 1038
Location: Colorado, USA
The problem with all this secret PM stuff (and it's the 2nd thread in a couple of days to have it) is it invalidates the whole community support thing.

By PM'ing the info required to solve the problem, it means that all future readers that come across this thread via key word search are left hanging.

Either publicly provide the info required to SOLVE YOUR PROBLEM, or if your privacy is so important, hire someone to fix it for you and keep it off a community support forum.


Top
   
 Post subject:
PostPosted: Tue Jun 05, 2012 8:07 pm 
Offline
Senior Newbie

Joined: Mon Nov 28, 2011 11:59 pm
Posts: 13
Hi,

I have used PHPMailer API to make this work (just like to share it to this thread). Anyway, some tips from Dweeber (in our private message):
Code:
Received: from hostname.domainname.com (li311-99.members.linode.com. [178.79.111.11]) 
        by mx.google.com with ESMTPS id 39si911193wet.123.2012.06.02.19.55.45
        (version=TLSv1/SSLv3 cipher=OTHER);
        Sat, 02 Jun 2012 19:55:45 -0700 (PDT)

- Make sure that hostname.domainname.com has an A record.
- The rDNS for 178.79.111.11 points to hostname.domainname.com
- All email addresses used by the mail system need to be valid including the From (Envelope Sender), From, Reply-To headers.
- Server generated scripts can generate perfectly formatted and fully RFC compliant email. Keys are including proper
o Date headers
o Valid Message-ID headers
o Proper Envelope Senders


Top
   
PostPosted: Mon Jun 11, 2012 5:28 pm 
Offline
Newbie

Joined: Mon Jun 11, 2012 5:16 pm
Posts: 2
It's a new Centos thing. Telnet into port 25 on your installation. You will probably get an EHLO of localhost.localdomain. That is why you are being pegged as a spammer. Make sure to set your hosts file.

telnet localhost 25

if you get back:
[root@mailserver ~]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.

Then you need to set your hostname in /etc/config/network and in /etc/hosts

You have it right when a telnet to port 25 EHLOs your domain name, NOT localhost.localdomain

I'm sorry I can't be more help, It was several months ago that I solved this. I'm surprised, given how common this is, that this is not better documented.


Top
   
PostPosted: Mon Jun 11, 2012 5:31 pm 
Offline
Newbie

Joined: Mon Jun 11, 2012 5:16 pm
Posts: 2
Once you have this fixed, not before, go to http://www.spamhaus.org/lookup/ put your ip address in, get back the results of who pegged you as a spammer and request to be removed from the list

THEN you won't have any more trouble with emails in Centos.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group