I've identified an extra possible improvement. One that is also very important (you could call it even a bug).
The script only properly works if FreeNAS/TrueNAS remains online...
For example:
If you have MCA messages at 16h43m and a crash at 16h49m and FreeNAS/TrueNAS only comes online again at 17h03, it will have missed the cronjob at 16h51 that would search in the 16h4x timeframe and the MCA messages that occurred will NOT be reported!
I'll try to get this resolved hopefully soon... But I'm not sure yet if it is possible / do-able...
resolved