Stopping non-error upcp and logwatch e-mails

paulg

Member
PartnerNOC
Dec 16, 2008
10
0
51
Hello,

Does anybody know how to stop non-error upcp and logwatch e-mails from being sent to root's e-mail address? I don't want to disable upcp and logwatch. I just want them to e-mail me only if there are problems. Is this possible?

Thanks,

Paul
 

paulg

Member
PartnerNOC
Dec 16, 2008
10
0
51
In case anybody is wondering, I ended up creating a ticket with Support. They said there is nothing that can be done for upcp. I suspect one could probably change the MAILTO in the cron job that runs it or redirect output to /dev/null but cPanel doesn't offer any configuration. Regarding logwatch, that is just a system utility that can be configured in /etc/logwatch/

Paul
 

domhandy

Member
Nov 3, 2008
7
0
51
United Kingdom
cPanel Access Level
Root Administrator
I changed my logwatch to save the output to /tmp/logwatch instead of emailing me. At least then I don't get the emails every day, but if I need to look at the latest output, it is stored on the server. You can also change the email address it goes to here.

The conf file is at /usr/share/logwatch/default.conf/logwatch.conf
Just uncomment the line about saving the output.

Unfortunately, a cPanel update seems to overwrite the conf file occasionally, so I have to do the changes again.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
If running cPanel updates (/scripts/upcp or the automatic cron) causes that to be overwritten, you could always create a bash script at /scripts/postupcp and use bash commands to revert the file to what you want it to have.