Dnia 29.09.2019 o godz. 13:21:53 Viktor Dukhovni pisze:
> 
> The trouble is that such accounts are generally restricted to a
> single envelope sender address, likely with a matching single "From"
> address.

You can define in Gmail account settings alternate sender addresses that
this account is allowed to send mail as. That's what I plan to use. As I
use very few sender addresses, I guess that would be sufficient.

> > While putting the gmail.com domain explicitly as a key in transport(5) table
> > is no problem, there is a multitude of companies that are using G Suite and
> > have Gmail-hosted mail with their own domain, and I experience the same
> > issue with them (ie. my mail being put to Spam by Gmail). So there's a need
> > to check if the MX for a destination domain is within google.com or
> > googlemail.com domain, and if yes, to send mail via Gmail server as well. 
> > Is there any way to do it with transport_maps ?
> 
> Postfix has no built-in mechanism for this, and it would be rather
> difficult to do this in a performant manner.  Transport resolution
> happens in the queue-manager on one recipient address at a time.
> Lookups of remote MX hosts, can take multiple seconds, and your
> mail queue can suffer congestive collapse even with a small fraction
> of email to a domain with DNS lookup problems.

Seems no problem for me as this is very low volume mail server, it serves
only a few accounts.

Is it possible to somehow use a script in place of the lookup table for
transport_maps ? Thus I could write a script that checks the MX and returns
the appropriate result.

> There are further complications, since some of these domains could
> use non-standard names (in their own domains) for the Gmail MX
> hosts, or just names owned by Google that you might not be aware
> of.  For example, you may not yet be aware of mx[1234].smtp.goog
> as additional (DNSSEC signed) Gmail MX hosts.

Thanks for pointing that out, do you know of any other such names?

> The real solution is to find a way to deliver mail normally,
> like everyone else, without going to the Junk folder.  For
> that
[...]
> I would not recommend this "solution".  Instead find a way to send
> email that Gmail will not routinely consider to be junk.

If only I could find a way to send mail to Gmail without having it marked as
spam, I would certainly do it! But I couldn't.

I have tried everything what you suggested, to no avail (didn't I already
write this in first email)? I never used IPv6. I didn't have DKIM and SPF on
my domain but I added that recently, after I started to have problems (by
the way SPF is evil, and this article is still valid, despite being written
in 2005: http://david.woodhou.se/why-not-spf.html - that's why I avoided SPF
as long as I could). The only thing I can't do is I cannot completely avoid
forwarding mail to Gmail accounts, because there are some addresses on my
server that need to be kept as forwarding addresses after people moved to
Gmail; but as I see from server logs, very small number of messages is
coming to these addresses and gets forwarded to Gmail.

I registered my domain with Google's "Postmaster Tools" that allow to check
the "reputation" of a given sender domain, but the tool won't show any data
because the volume of mail from my domain is too low (according to their
help page, you need at least hundreds of messages per day, which is far more
than I would ever send :)).

Of course, what I would like is to be able to
deliver mail to Gmail normally, but it seems the issue is on Google's side,
as more and more people are experiencing this issue. Please look for example
at this:
https://www.tablix.org/~avian/blog/archives/2019/04/google_is_eating_our_mail/
or this (this is from 2015!):
https://battlepenguin.com/tech/how-google-and-microsoft-made-email-unreliable/
And that are only two of many, many similar examples I found when searching
the net. Basically, perfectly legitimate emails from properly configured
mailservers get randomly classified as spam or even SMTP rejected by Google. 
Nobody knows what it depends on and it seems nobody can do anything about
this. Of course there is no possibility to contact Google with regard to
such issues, why would they care about non-Gmail users out there on the
Internet at all? ;-> They want everyone to be on Gmail, then there will be
"no problems"...

My emails were delivered to Gmail without any problems for long time. 
Suddenly they started to go to spam. I didn't send any spam and my server
wasn't relaying any. Now my emails still go without problems to people with
whom I corresponded previously, but for the Gmail accounts to which I never
wrote previously, and write to them for the first time, they go straight to
spam. I tried this on three freshly created Gmail accounts one after the
other. My emails sent to these accounts landed right away in spam. Google
said that "message is similar to the ones already caught as spam", which I
understand is probably a generic catch-all phrase they use for all cases, as
all the messages were different and similar neither to each other nor to
anything spam-like. BTW, Gmail indicated that SPF, DKIM and DMARC tests
passed. Clicking "This isn't spam" on one account fixed the problem for
that account, but didn't have any influence on other accounts. So I'm
stuck, for over a week I was trying everything that I could, and still
nothing changed.

The "solution" I was suggesting here is a heavily flawed workaround - I am
completely aware of this - but this seems to be the last resort, as it seems
to be no way to send mail to Gmail "normally".
-- 
Regards,
   Jaroslaw Rafa
   r...@rafa.eu.org
--
"In a million years, when kids go to school, they're gonna know: once there
was a Hushpuppy, and she lived with her daddy in the Bathtub."

Reply via email to