Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have a postfix mailserver running. Mails sent from users to Gmail are showing up in Gmail, so it works in general. Same for all other freemail hosts I know.

The problem is that some users have no local mailbox but a forwarding to Gmail. If someone sends a mail to such a user my mail server forwards the mail to Gmail. This works, even if the original domain has a SPF record with "-all". But if a Gmail users sends a mail to my server which is then forwarded to Gmail again the mail never shows up in Gmail.

I already tried: - Check the logs. Gmail SMTP just reports "OK" but the mail seems to get discarded in a later step. - Enable SRS. Still no mail in Gmail

Anyone out there who has a running setup able to forward mails from Gmail to Gmail? Is there something I am missing that's causing Google to classify my mail as spam so badly that it doesn't even go to the Spam folder?

share|improve this question
1  
I Peter, did you sort this out? We are facing the exact same problem: our LOGs show a 250 OK, which means that the email has been accepted at Gmail; but the email neves shows up in the Gmail's account inbox. Thank you. –  user102013 Nov 24 '11 at 11:16

2 Answers 2

"if a Gmail users sends a mail to my server which is then forwarded to Gmail again the mail never shows up in Gmail"

This is probably not a spam situation, but it may be a situation of how "mail routing loops" are being detected based upon your description.

Most email systems will have some form of "looping" detection in place, otherwise loops like this can digress into a "run away" situation where email systems are brought down to their knees. In those situations, the more powerful system will usually win with the "losing" system taking a pretty disruptive crash.

If you are sure that situations like those that you described to not involve any actual loops where the gmail sender is somehow copying back to themselves through your system, then you might consider contacting the Google folks directly for assistance. They may need to adjust their loop detection or may have some guidance around how your system can forward to theirs in a way that does not trip their loop detection incorrectly.

share|improve this answer
1  
This is exactly what happend on my server. I can't send mails from my gmail account via relay to my gmail account. Tried it with another gmail account and everything works fine. Thank you! –  Lukas Schulze Feb 2 '12 at 19:10
    
Glad things worked out for you. –  user48838 Feb 3 '12 at 1:51

Are you sending email back to the same gmail account that you are posting the email from?

If a message goes from abc@gmail.com to def.whatever and then back to abc@gmail.com, gmail will not put the message in the inbox. https://support.google.com/mail/answer/6588?hl=en You can change this behavior by specifying the def@whatever as an alternate email address alias in your account options.

This troubleshooter might help you as well.
https://support.google.com/mail/troubleshooter/2935079?hl=en

Before you do all of this though, check your postfix logs at /var/log/maillog and make sure you are getting a positive response from gmail. Something similar to

status=sent (250 2.0.0 OK 1404098487 fv4si21511978pbb.224 - gsmtp)

If you're getting something else, ie:

status=SOFTBOUNCE (host gmail-smtp-in.l.google.com[74.125.25.27] said: 550-5.7.1 [107.161.16.11      12] Our system has detected that this message is 550-5.7.1 likely unsolicited mail.

Well, then, you know the problem.

share|improve this answer

Your Answer

 
discard

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.