Yeah I am using GNU+Linux and SSH. Hmm but I don't want to have a look at logs. Moodle must have some way of collecting or marking which forum posts trigger mails because it can only tell the mail server that mails should be send when the cronjob gets run, no? I know it's not a mail server, but how would it tell the mail server what mails need to be send if it doesn't have a list somewhere? Moodle can't send these directly itself afaik, this is what the cronjob is for, right?
What logging moodle does can be found in 'reports' which is queying mdl_logstore_standard_log table.
Go look at that. Think that's the only logs you got in the moodle interface that's related to forum postings/mail ... but no mailque. There are 9 tables for forums. If one did explain on all 9 of them, one at a time, one might see a column sorta related to what you are asking, I think.
"but I don't want to have a look at logs" ... Errr, uhhh ... sorry, but once moodle packages up whatever it's supposed to send, a cron job/task will attempt to send as many and as soon as it can - that's handed over to the mail server and it's que.
Other wise, 'bounces' (postmaster notifications which are in RFC guidelines for administering a mail server) don't come back to Moodle code they go back to the sending ***mail server*** ... and, I for one, would NOT want Moodle to attempt to handle that!
Do you have any tool to browse Moodle tables?
'spirit of sharing', Ken
Forums could be forced subscribed.
Find all the forums via overview of plugins. Visit each forum and check settings.
Even changing config ... forums have already sent the mail ... Elvis left the building.
I had this happen about a week or so ago with a newbie Moodle admin ... thankful that I had Postfix in front of any other smarthost (smtp relay) cause I let Moodle do it's thing and manually cleared the mailques as messages came in thus preventing the moodle server from getting blacklisted god knows where. And didn't mess with config of forums .... 125 of them ... nor the related tables. Did have a long talk with the newbie Moodle admin though. Not his fault ... he didn't know that 8000+ users were subscribed to a hidden forum that had never been used by former Moodle Admin.
Not ideal ... a pain in the arse ... but ....
'spirit of sharing', Ken
Hey Ken. Thanks for sticking with me. Moodle has to keep track of the forum notifications somewhere because if not how would it be able to tell the mail server which mails it would need to send out when the cronjob runs?
I want to find that place and delete the forum notifications so that no one gets spammed with old notifications that are not needed anymore.
That's why I think logs won't cut it -- afaik logs only document what has happened, they do not store what is supposed to happen later, right?
Modifying the forum configs for subscriptions may cut it. That's a good idea. However I would need to find out if it really will work.
I can be sure that no mails were already created by the mail server because the cronjob for Moodle to tell the mail server to create mails has not been run for a long time/ever.
"sorry, but once moodle packages up whatever it's supposed to send, a cron job/task will attempt to send as many and as soon as it can - that's handed over to the mail server and it's que."
Yeah, I know the cronjob has not been run so how do I find that package that Moodle has packaged up of what it's supposed to send? I want to delete exactly that or change it so nothing will get send. Probably Moodle checks in the database whether a forum post has been sent to the subscribed users. So I would need to find that information and overwrite it manually to "yes the mails have already been sent" or "there are no subscribers."
I am looking at the database with mysql terminal tool and try to find where Moodle keeps track of what notifications need to be send when the cronjob gets run. Is there an official documentation about what table does what and what column is for what purpose?
I have more ideas how to solve the problem now so thank you again Ken!
There's human 'logic' (maybe that's you and I) ... then there's 'computer logic' ... then there's 'program logic' ... etc. Are they all the same? ... ie, do they all 'think alike'? Not really a question for response ... just a thought.
Anyhoo ... one of the 8 tables
See what's in them on your system. None of the 'clients' I help use forums.
In mdl_forum_posts. There's a 'mailed' column and a 'mailnow' column ... if user opts to 'mailnow' in things like forums, etc., Elvis tries the leave the building right away - which, I think, would mean data is packaged up and control handed off to mail systems.
There is no task/part of cron job that attempts cancelling or clearing a mailque ... locally or on an SMTP server somewhere. Deleting the row??? Might confuse other related tables but, hopefully, moodle would recover and one would not be stuck with looking at an error every day.
And depending upon the number of persons to get the message, that could be really quickly accomplished, or, in the case of 8000 users forced subscribed that could tax a server, do all sorts of different things related to mail systems.
Then there are user preferences for handling mail or messages.
Could have simply said ... dunno ... but, did dunno with an explanation ... maybe it will lead you somewhere.
Maybe if we made a plea to the real Moodle Guru's one would jump in here and clear the confusion.
*Calling ALL Moodle Guru's!!! Got a minute? HELP Lexi K out!*
'spirit of sharing', Ken
Hey Ken, I just risked it and turned off notification subscriptions. There were only two relevant forums anyway. It seems to have worked, although I can't tell for sure yet. Will post again if I know more so people with the same problem in the future know whether turning off notification subscriptions is a possible solution. Thanks again