Emails 'pending to be sent later'

HI,

Is there any sort of email priority setting? We are trying to send emails from the participants / registrants screen using the email screen (selecting the appropriate people) and they are sitting in the logs as ‘pending waiting to be sent’ - for a few hours now. Yet we registwer for an event and the email turns up straight away?

any ideas or setting i need to change / set

Cheers

Mark

It sounds like Celery is not running. Because when it is, emails are typically processed and sent immediately.

yes. but why would emails either side of it for registrations be getting sent?

So some get sent? I don’t have an explanation → check the log files on the server. Maybe there’s something wrong w/ the sender or recipient address, resulting in an error from the mail server?

ok - cheers - we will also restart celary, but will also check logs

They still havent moved, was hoping they would, but found this in the logs - is this a read herring or do you thing it is the issue. ‘Normal’ emails like registrations happen in an instance (tested again this morning0 but using the ‘registrants’ pannel, slecting a person, then email from action dropdown, it doesnt send it - in the on-screen logs is says ‘This email is pending and…later’, in the indico.log file i find this.

Task event_reminders is locked; not executing it. To manually unlock it, run indico celery unlock event_reminders

any ideas?

hi,
In fact, looking deeper into the indico.log i am finding many instances of the following - is this usual, or is it the issue?

indico.celery             Task event_reminders is locked; not executing it. To manually unlock it, run `indico celery unlock event_reminders`
 indico.celery             Task survey_start_notifications is locked; not executing it. To manually unlock it, run `indico celery unlock survey_start_notifications`
 indico.celery             Task update_system_notices is locked; not executing it. To manually unlock it, run `indico celery unlock update_system_notices`
 indico.celery             Task registration_retention_period is locked; not executing it. To manually unlock it, run `indico celery unlock registration_retention_period`
 indico.celery             Task temp_cleanup is locked; not executing it. To manually unlock it, run `indico celery unlock temp_cleanup`
 indico.celery             Task category_suggestions is locked; not executing it. To manually unlock it, run `indico celery unlock category_suggestions`
 indico.celery             Task heartbeat is locked; not executing it. To manually unlock it, run `indico celery unlock heartbeat`

Not related. but it usually happens if for some reason celery was either killed while running tasks, or those tasks are still running (pretty much impossible since they are quick ones).

You may want to do a clean restart of celery and then unlock those tasks in case they are still locked.

Also, it’s better if you search for send_email in celery.log or indico.emails in indico.log to find entries related to email sending.

Thanks for that - tried celery logs, no entries, but got this in indico logs, a few times. Is this now something i need to take up with people here, or is it indico related?

[Indico] Test Email" (attempt 8/10); retry in 3600s [{‘mark.golder@geant.org’: (554, b’5.7.1 mark.golder@geant.org: Sender address rejected: Access denied’

Yeah, your mail server does not allow sending emails from that sender address. Ideally the credentials you use for email sending should allow you to use any sender address.

In any case, with the next release it will be possible to force a specific sender address (or sender addresses to be from a specific domain depending on how much your email infrastructure restricts your email senders). That would most likely help there, since you could e.g. force Indico to send all emails from noreply@geant.org if the mail Indico uses is allowed to send (only) from the address.