Link to home
Start Free TrialLog in
Avatar of David Atkin
David AtkinFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Service to delay emails to Gmail

That's right, I have a client who wants to deliberately delay emails to their Gmail.

They would like their emails to be delivered every 4 hours instead of it coming down as they get them.

Any suggestions on how to do this?  Or does anyone know if there is a service that does this?

We're currently looking into doing it with Azure Queues but thought I'd put it out there to see if anyone knows of any other way.  Or if there is a way of doing this native to Gmail.

Thank you in advance.
Avatar of John
John
Flag of Canada image

You could set up a separate Outlook Profile for Gmail and have the interval check every 4 hours, or have it not check at all and ask the user to download Gmail when they feel like it.
Avatar of David Favor
I'm guessing your client's gmail setup is using a POP3 connection to pull email from an external server, so gmail periodically checks this POP3 server to pull email.

If this is correct, the simple way to accomplish this is using CRON jobs + iptables.

1) When system reboots, block access to POP3/POP3s ports (110/995). If you're using a custom port change accordingly.

2) CRON job to run ever 4 hours, which opens your port, then schedules another at job to run, say in 10 minutes to block the port again. Likely 10 minutes is to long. This time should be longer than the interval Gmail uses to check mail + download messages that have arrived in last 4 hours.

This allows all your server mail software to work with no code or config changes.

An optional approach would be to write a simple POP3s proxy which keeps up with any new message IDs which occur in a 4 hour period + only pass these through every 4 hours. Likely some simple PERL code could do this easily.

Likely CRON + iptables is best, as this could be up + working in a few minutes.

Writing a POP3 proxy... well... that would be a great adventure...
Avatar of David Atkin

ASKER

Thank you for your comments,

@Experienced Member - We've considered using Outlook but the company wants to make it company wide and none bypassable.  I.E. no send and receive from the users end.

@David Favor - They're using Gmail for business so there are no POP services involved, unfortunately.  Ideally, I would like to sit something before gmail to control the delivery of mail.  I'm not aware of any Email filtering service that can do this, although I am waiting for a few replies from various providers.
You cannot stop Gmail from getting its mail, only when you choose to receive it.
So Gmail for business has no Settings -> Accounts and Import to import from many POP3 accounts.

I could have sworn it did.

If Gmail owns your MX record, then as the other member mentioned, you have no control over this.

If you must have your 4 hour, then you'd switch to free (non-Biz Gmail) + use the above cron + iptables suggestion.

Or said another way, to have this type of control you have to own your MX record(s), not Gmail.
I understand that I don't have this capability from within GMail.  My intention would be to sit something in front of gmail (Change the MX Records to another service) and then use this service to cause the delay.

I know that I could do this in a bodged kind of way if the client had an internal email server like Exchange, but unfortunately, they don't.

Hope that makes sense.
This question needs an answer!
Become an EE member today
7 DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.