Postal: Postal - No delivery attempts yet.

Created on 29 Jul 2017  路  23Comments  路  Source: postalhq/postal

Hi Team,

Our Postal system has sent approx 300000 emails till now. But in that 6000+ emails pending in mail queue and the status is showing "No delivery attempts yet.". Is there a way to force Postal to resend all Pending emails ? What can be the reason for this and any possible solution ?

https://www.screencast.com/t/uhAu2hcSb

Thanks

support

Most helpful comment

I got it fixed. Theres a table called queued_messages. Just make locked_by, locked_at, retry_after to NULL and postal will automatically send them again. There were worker processes that locked the messages which doesnt exist anymore. So it was locked forever.

All 23 comments

Presuming that your system is still sending the messages, how many workers do you have? postal status should tell you if you don't already know

You can increase the number of workers in postal.yml like so

workers:
  quantity: 10

4 Workers.. Many of the emails has been sent but many emails are still pending from 2-3 days. You can see the received date in screenshot. Nothing is sending right now as per the send rate showing on dashboard and nothing in logs.

When I am sending new emails, it sending immediately.. but not attempting to send these old emails.

https://www.screencast.com/t/bEeImQem

@laitkor found any fix? I have the same issue.

@laitkor, @Razva,
We had same issue when server was trying to connecto to smtp servers via IPv6 smtp addresses but IPv6 was not supported by ISP, causing connecting issues. Disabling IPv6 resolved issue. Hope this helps.

Hi

i have same issue..is there any solution?

@sahilsunesara Ensure this is not caused by IPv6 connecting issues first, that was our case.

@cyberopus i am not using IPv6... some email goes and some are in queue and still in queue since a long time approx 20 days

Having same issue. One of our webhooks was not working, that caused delivery to be very slow (40message / min).. There was 90k emails in queue, so disabled it and restarted postal. After that most of the messages out of 100k delivered (at 700 message / min) except for 6k thats still in pending state. No delivery attempts made in last 2-3 days though no other emails are being queued. I have 6 workers. Any solution?

I got it fixed. Theres a table called queued_messages. Just make locked_by, locked_at, retry_after to NULL and postal will automatically send them again. There were worker processes that locked the messages which doesnt exist anymore. So it was locked forever.

@vishnus This is in RabbitMQ right?

@knightbenax no, its in DB..

@vishnus please tell me if default value is already NULL then...and still my mails are in pending state.
then what should i do???

@Manishjodhani ideally, it should retry immediately after you restart all postal workers. Also check if they are locked by any process in the same table.

@Manishjodhani I see your screenshot posted in the other issue thread (#498).

Default value of the column might be null.. Do a
select * from queued_messages;

See the columns mentioned in the above comment. It may not be null. So you can update it to null by this query:
update queued_messages set locked_by = NULL, locked_at = NULL, retry_after = NULL;

PS: this will update and make those three columns null for all entries. So do it after double checking the contents of that table.

i think it work but not confirm....i will check it again if it work then i will text here.
@vishnus can you tell one more thing how many worker and thread should i used if my server had 32GB RAM..?

@Manishjodhani you can refer to this discussion #290

I got it fixed. Theres a table called queued_messages. Just make locked_by, locked_at, retry_after to NULL and postal will automatically send them again. There were worker processes that locked the messages which doesnt exist anymore. So it was locked forever.

Hi @vishnus could you please guide me on how to get to the queue messages table?

@Manishjodhani I see your screenshot posted in the other issue thread (#498).

Default value of the column might be null.. Do a
select * from queued_messages;

See the columns mentioned in the above comment. It may not be null. So you can update it to null by this query:
update queued_messages set locked_by = NULL, locked_at = NULL, retry_after = NULL;

PS: this will update and make those three columns null for all entries. So do it after double checking the contents of that table.

@lovelyns Please refer this

This issue is still present.

maybe it's ok to clear db lock after maybe 2 minutes ?..

This problem mainly occurs if your worker processes are stopped unexpectedly so should be a rarity if your servers limits are appropriate and you have enough resources available to meet them.

That said, it could be handy if there was a method for detecting and resolving these "stranded" messages however if this was occurring due to problems with IPv6 then this could cause an infinite loop so would need extra tracking to fail appropriately.

The issue affects my setup too.
Already checked queued_messages table but all those fields were yet set to NULL.
Any hint on how to solve it? or where to keep investgation from?

@jbci if you've used postal status to see that everything is running and you're still not sending emails, have a look at your log files and if you have any questions, please open a new issue as you've already confirmed your problem is different to this one

Was this page helpful?
0 / 5 - 0 ratings

Related issues

stayallive picture stayallive  路  5Comments

elfeffe picture elfeffe  路  3Comments

shinebayar-g picture shinebayar-g  路  3Comments

destroyer998 picture destroyer998  路  5Comments

BlueHatbRit picture BlueHatbRit  路  3Comments