LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Making fetchmail silent (https://www.linuxquestions.org/questions/linux-software-2/making-fetchmail-silent-172340/)

Gameon 04-20-2004 12:07 AM

Making fetchmail silent
 
Greetings!

I have a simple fetchmail cronjob running in the background to check my mail from my ISP. It works just fine, but it also spams my local mailbox. I'm running the cronjob as follows

*/2 * * * * fetchmail -a -s >> /dev/null

But still I get error messages to the local mail box when the fetchmail is not able for example to connect to my ISP. Or if there is any other kind of temporary problem, it sends an email. How to make it totally shut up? -s should be the silent flag and (at least to my newbie knowledge) >> /dev/null should send all other output far away.

I must be doing something wrong. But what?

ToniT 04-20-2004 02:10 AM

According to the manpage -s suppresses only normal messages that comes to stdout. Errors are coming anyways. To direct them to /dev/null, use line
Code:

*/2 * * * * fetchmail -a -s 2> /dev/null

Gameon 04-20-2004 02:17 AM

Aah. Of course. Should really take my head out of my backside. Thanks for the clarification!


All times are GMT -5. The time now is 07:03 PM.