Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

First post - was directed here from stackoverflow!

The problem: Google marks seemingly correctly formatted emails from my apache/postfix server as spam. Sample email as follows;

(I have replaced my domain with and the IP with a pretend IP)

Received: by with SMTP id o21cs22383ybg;
        Fri, 26 Feb 2010 23:11:55 -0800 (PST)
Received: by with SMTP id f11mr1470919ibw.50.1267254715619;
        Fri, 26 Feb 2010 23:11:55 -0800 (PST)
Return-Path: <>
Received: from ( [])
        by with ESMTP id 29si1651619iwn.31.2010.;
        Fri, 26 Feb 2010 23:11:55 -0800 (PST)
Received-SPF: pass ( domain of designates as permitted sender) client-ip=;
Authentication-Results:; spf=pass ( domain of designates as permitted sender)
Received: by (Postfix, from userid 48)
    id ACB735030340; Sat, 27 Feb 2010 18:11:53 +1100 (EST)
Subject: Quote for David Brent (00125512123)
X-Mailer: PHP/5.2.10
Message-Id: <>
Date: Sat, 27 Feb 2010 18:11:53 +1100 (EST)

Name: David Brent

Mobile: 00125512123



Date: 2010-20-21

Time: 21:00

Location: Syd

Eventype: Musicians

Message: Yep, this should work!!!!

how did you hear about us: Newspaper
  • I have tried sending it to non-google emails, and they arrive fine.
  • I have tried posting to several different google accounts, all end up as spam.
  • uses Google Apps as email provider.
  • I have added "v=spf1 a mx ~all" as TXT in my NS.
  • I used to check reverse DNS and the IP seems to be resolving back to the domain name just fine.
  • My IP is not blacklisted in spam-lists (as far as my checks can tell). I host at - in Australia.

The headers seem fine, and the SPF look up seems to pass (?).. Any ideas?

Kind regards

share|improve this question

migrated from Feb 27 '10 at 13:43

This question came from our site for computer enthusiasts and power users.

Hmm.. So you are suggesting then that I train the Google engine to allow emails from my domain? Sounds like a bit of an an ugly hack to me? – Anonymous Feb 27 '10 at 12:55
Thanks all. For some reason I cant seem to edit or comment on your answers. Anyway, I decided to implement DKIM, but I'm running into troubles here as well:‌​er-i – GBC Feb 28 '10 at 3:27
I'm not suggesting you train the Google e-mail engine, just pointing out that in the arms race between the spammers and the mail washers you're going to get false positives as well as false negatives. – ChrisF Feb 28 '10 at 18:34
You need to give your real domain and real IP so someone can help you. The reason we need this information is to check if you have properly configured things like your PTR records. Obfuscating this information prevents us from helping you. – Dave Cheney Mar 1 '10 at 8:13
up vote 3 down vote accepted

mxtoolbox has a pretty comprehensive blacklist checker. I know you already checked but this might be useful to others who come across this post as well.

Your best bet - as mentioned by caelyx - is to implement DomainKeys and be done with all this nonsense. Yahoo and Gmail both green light dkim signed email till they have reason to do otherwise (users tagging it spam). If this is at all business related it's a pretty obvious choice ROI wise. An hour or so of configuration and testing equals much fewer issues with spam filters.

share|improve this answer

Google's got an FAQ at

It's probably triggering on a content rule (since SPF authentication seems to be working fine).

If you've got access to a couple of gmail accounts (yours, coworkers, etc), try sending some of that email to them and marking them as "Not Spam" within gMail; see if the filter learns.

Absolute worst case, try either (a) changing up the formatting, or (b) signing the message with DomainKeys/DKIM.

share|improve this answer
DomainKeys is older but on the way out. DKIM is the IETF standard and on the way in. Choose DKIM for new deployments. And it's not any kind of worst case -- anyone running a mail-system who cares about exchanging email with others should look at deploying DKIM, so that others can see that mails really did come from the domain owner. (That doesn't say "domain owner is not spammer", but does let reputation be built up per-domain). – Phil P Mar 8 '10 at 3:30

I had issues not being able to email a company that i always used to, and it happened because they migrated over to Google email servers and in the security checks they started using Forward Confirmed Reverse DNS Lookup.

Go to this ipadmin site and make sure your email server is configured properly


share|improve this answer

Yep, this should work!!!!

how did you hear about us: Newspaper

Is a pretty spammy looking message. First, you need to flag all the prior messages from that server as not spam. Then, you should make sure any messages you send are valid. For example:

"This message is to confirm that you have signed up for our service. ABC Corporation is looking forward to having you as a client"

Would probably not be caught.

share|improve this answer

Try this Email Server Test. if it does not flag anything, best thing is to contact Google postmaster.

share|improve this answer
Thanks! Great resource. Emails seem clean though. All passes. I got a 5.5 score on the SpamAssassain-test, but I'm pretty sure it's wrong as it didn't make sense at all.. To make sure It was wrong I did this SpamAssassain-test: and got a score of 0.1 (perfect). – GBC Mar 2 '10 at 1:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.