Mail generated every 30 minutes about FreeDNS

Running Nextcloud 24.
/etc/cron.d/freeDNS is configured to run every 30 minutes /bin/bash /usr/local/bin/
That’s okay, but there is an e-mail generated for every successful run with the output of the shell script. It’s generated under the root-account and stored, since there is no real mail functionality. Within one year, about 15 000 mail accumulate.
I like to get rid of this. Did I mis-configure something for this behaviour?

The content of the mail:

FreeDNS client started
Registered IP:| Current IP:

Nextcloud version (eg, 20.0.5):
NextcloudPi version (eg, 20.0.5): v1.50.4
Operating system and version (eg, Ubuntu 20.04): Debian 4.19.260-1 (2022-09-29) x86_64
Apache or nginx version (eg, Apache 2.4.25): apache...
PHP version (eg, 7.4): 7,4

Please ask FreeDNS community as this issue is related to FreeDNS service, and not Nextcloud codebase.

Happy New year.
:firecracker: :tada:

@Heideachim is probably referring to this script nextcloudpi/ at master · nextcloud/nextcloudpi · GitHub which kind of is part of the Nextcloud code base, or more precisely, the NextcloudPi code base.

Ah! Fair. Then Forget my comment. :slight_smile:

Precisely. That’s the install script I got my information from.
But then, why does it generate mails for SUCCESSFUL runs?
I would be grateful if somebody could check, if they get those mails as well. Simply issuing a ‘sudo mail’ (after installing mailutils) should tell. If other people do not get those mails, it’ s simply my installation that is screwed up.

Unfortunatley I can’t check it, since I don’t use NCP. But if I had to guess I’d say the mails are sent by the crontab in /etc/cron.d/freeDNS

If this is the case, and if there is no option to turn it off in the Admin-UI of NCP, I can think of two ways to turn it off:

Edit the crontab…

nano /etc/cron.d/freeDNS

…and add the following line at the very top of the file:


or you could add the following at the end of the line of the cronjob itself, in order to redirect the output to /dev/null:

>/dev/null 2>&1

Hope that helps…

Thanks for those replies! I modified the solution suggested by bb77’s to the following:

*/30  *  *  *  *  root  /bin/bash /usr/local/bin/ 1> /dev/null

This will only kill the output to stdout, but should report any error messages sent to stderr. So if something fails, I still get a mail message, which is okay.
The drawback with this kind of solution (modifying the crontab-file): Whenever a new version of NextCloudPi is installed, this most likely overwrites my changes so I have to re-insert them again by hand.