Getting journald to send email on certain events

I found these solutions for syslogd that send emails on certain events like local0.crit or local1.err

How can I make syslogd email certain log messages to me? http://www.johnandcailin.com/blog/john/how-setup-real-time-email-notification-critical-syslog-events

However my system is running on systemd and thus using journal for syslog purposes. How can I implement email based on events without having a cron running that checks all logs each 5 minutes and sends the logs to an address or similar?


Solution 1:

As far as I know there is no such functionality in journald and I don't think it will ever be implemented.

Instead, you may implement your own journal log watcher using the python API to read the journal.