Web Hosting Talk







View Full Version : SPAM from Webmin Crons


Eagle_
06-17-2001, 07:37 PM
I use Webmin to setup my crons
works great
just one thing.

I made a script that checks if a certain program is in memory, it checks every minute...
However, every successful execution of the script, results in an email from the cron daemon,
how do I turn this off?

It's driving me NUTS!

Duster
06-17-2001, 08:07 PM
Good luck turning it off, although it clearly is not spam.

Eagle_
06-17-2001, 08:10 PM
LoL

I know that
however, it is still annoying (like spam) plus this draws attention I guess :D :stickout :)

ZachB
06-18-2001, 12:32 AM
alright, I'm not sure whether or not if you are talking about making crontab entries in webmin, or from a shell,
but I'll explain both.

from the shell, you would probly want to type crontab -e (vi knowledge required if you are using it as default :)
and your entry should look something like this
0,10,20,30,40,50 * * * * /home/myuser/programchk >/dev/null 2>&1

if its webmin
just append a ">/dev/null 2>&1" to the program name (without the " 's)

Eagle_
06-18-2001, 02:01 AM
I did that

"/uo/checkmem & >/dev/null 2>&1"

Still sending like crazy...

ZachB
06-19-2001, 01:58 PM
Hey,

alright I just scrolled up and took a look, what language is that script written in and paste it if you can :) and I could take a quick look see if its the script or if I'm just bad on crontab's lately

jnestor
06-19-2001, 05:00 PM
Change it to
/uo/checkmem >/dev/null 2>&1 &

In otherword the & goes at the end

In brief if you run something from cron anything it outputs will be mailed to you. This just redirects the output away to /dev/null where it's lost forever.