Does undeliverable e-mail get queued in Moodle?

Does undeliverable e-mail get queued in Moodle?

by James Chase -
Number of replies: 6

I have had the smtp setting misconfigured for some time and e-mails have not been going out. The setting was such that moodle would not have been able to contact the smtp server at all. My question is: once I fix this smtp setting, will all the e-mail it has failed to send suddenly be delivered? Is there a queue somewhere that I need to flush before fixing the smtp setting? I don't want users getting old, irrelevant e-mail. I tried to search in the database but to no avail. 


Thanks!

Average of ratings: -
In reply to James Chase

Re: Does undeliverable e-mail get queued in Moodle?

by Ken Task -
Picture of Particularly helpful Moodlers

Moodle is NOT a mail server.   Like a laptop that is using POP3(s) app for mail.  It basically 'hands off' EMail to either a local MTA (mail transfer agent) like postfix or sendmail (depnding upon operating system).  So the 'stuck que' could be in the queues on the Moodle server (postfix/sendmail) or, if you configured for SMTP, 'stuck que' could be on the SMTP server ... or, more than likely, bounced messages have been obliterated because messages could not be delivered.

To be any more specific than that, you'll have to disclose: Operating system (Windows platforms normally don't have sendmail nor postfix).   If Linux what flavor?   If remotely hosted, who is provider (it might be the provider throttles the # of messages, etc)?   If remotely hosted, have you checked on the sending of mail from applications in your providers documentation/helpdesk/forums?

'spirit of thinkering', Ken

In reply to Ken Task

Re: Does undeliverable e-mail get queued in Moodle?

by James Chase -

Hi Ken,

The "stuck queue" messages are not present on the server on which moodle resides (ubuntu 12.04) which is running postfix. The mailq is empty. Basically moodle was trying to send via a non-existent smtp server, on an old network, from when we migrated it. So it sounds like you're saying Moodle does not maintain any mail_queue internally, within the database or file system for the moodle application, when it cannot reach any smtp server at all. True? 

In reply to James Chase

Re: Does undeliverable e-mail get queued in Moodle?

by ben reynolds -

Actually, Moodle checks the age of any emails waiting to be sent (assignment notifications, forum posts, etc) to prevent what you fear. I think it sends nothing that is over 48 hours old. Maybe 24 hours.

In reply to ben reynolds

Re: Does undeliverable e-mail get queued in Moodle?

by James Chase -

That's great! Does anyone know where that queue is in the database, just so I can verify? There may be something within the past 24-48 hours that I want to remove. 

In reply to James Chase

Re: Does undeliverable e-mail get queued in Moodle?

by Ken Task -
Picture of Particularly helpful Moodlers

Basically, yes that's true.   Hope it never does, either.

'spirit of sharing', Ken