Redirect Cronjob to /dev/null

Hi there @all,

having a small issue with one of my Cron Job. I need to use this job for my Moodle system. But having a problem, that meanwhile I have a lot of Emails about the Cronjob-report.
I have seen in the Webmin Documentation, that I should put the output to /dev/null. But how can I do that?
The command which I have in the Cron Job Task is:

/usr/bin/php /home/username/domains/sub.domain.com/public_html/moodle/admin/cli/cron.php

One more thing, the Inbox of my Server now has over 133000 Emails. Is there a way to delete them all at once?

Thanks a lot

Append your command with:

> /dev/null 2>&1

Like so:

/usr/bin/php /home/username/domains/sub.domain.com/public_html/moodle/admin/cli/cron.php > /dev/null 2>&1

1 Like

Thanks a lot @calport it stopped sending the Reportmails

This topic was automatically closed 4 days after the last reply. New replies are no longer allowed.