A very common theme in the Moodle forums is problems with email notifications for things like submitted assignments, forum posts, graded assignments, etc. It’s good to know that I am not the only one having these kinds of LMS problems. I was having issues with email notifications only working every once in a while and I finally had time to dive into the Moodle community and research the issue.
In my research I found that there are two common problems Moodle admins have with email notifications. Turns out I was having both of these problems. The first and more complicated issue is not having a Cron job set up on the web server hosting moodle and the second issue had to do with using SMTP to send email from Moodle.
The first issue was the tough one to figure out. Before researching this issue I didn’t even know what Cron Jobs are which made it difficult for me to troubleshoot the issue. After trolling through Moodle forums I learned that a Cron Job is something that tells the server to run processes such as sending emails and running backup routines. I think I may have missed something in the moodle installation that automatically creates the Cron Job because I didn’t have one created on my hosted server. Once I figured this out I jumped into creating a Cron Job using instructions from the Moodle Documentation Wiki. At first the instructions seemed easy but as usual the Cron Job I created using the instructions gave me errors. The error I was getting was a result of a UNIX command line that the server did not agree with. The Moodle instructions gave other command line options so I tried another option and it solved the problem. The Cron job started working but the email notifications still weren’t working.
At this point the Cron job was working but the emails still weren’t coming which lead me to the second common issue of using SMTP settings to send the email. In Moodle you have the option of sending email through SMTP or PHP. If you use SMTP you need to enter your servers information into Moodle which I did and I think I did correctly but it wasn’t working. I came across several posts regarding this in the Moodle Forums and one post suggested simply not using SMTP and deleting the SMTP information you entered in Moodle. I did this and bang the emails started arriving. Moodle obviously didn’t like what I entered for the SMTP information and wanted to send emails using PHP.
Now I have the email notifications working but they are working a little too well. Submitted assignment email notifications are going to people other than the “Teacher” of the class. I still need to do some fine tuning with this but I have a feeling it is something simple I overlooked.
I hope this post finds other rookie Moodle implementers and helps solve similar issues. Please leave a comment if you have any suggestions for the persisting email notification problems I am having.