[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Description mail alert - Arguments not passed
From: |
Jan-Henrik Haukeland |
Subject: |
Re: Description mail alert - Arguments not passed |
Date: |
Fri, 6 Mar 2015 13:27:48 +0100 |
> On 06 Mar 2015, at 12:44, Kizito Porta Balanyà <address@hidden> wrote:
>
> Hello,
>
> When I receive the alerts , the description doesn't contain the arguments
>
> My monit config:
>
> check program checkSize_SapSprintLogs with path
> "/usr/local/nagios_plugins/check_dirsize11.sh -d
> /cygdrive/c/PROGRA~1/SAP/SAPSPrint/Logs -w 5000000 -c 10000000"
>
> The alert description:
> Description: '/usr/local/nagios_plugins/check_dirsize11.sh'
> failed with exit status (1) -- 6939796 KB - warning
>
> What I would like (arguments added):
> Description: '/usr/local/nagios_plugins/check_dirsize11.sh -d
> /cygdrive/c/PROGRA~1/SAP/SAPSPrint/Logs -w 5000000 -c 10000000' failed
> with exit status (1) -- 6939796 KB - warning
>
> I have something misconfigured? Is it possible?
No, only the program name is used, no arguments. However, why not have your
program write to stdout or stderr this information? _Then_ it will be part of
the alert. That is, instead of having the program write '6939796 KB - warning’
have it write ‘Warning: 6939796 KB is inside the range [5GB..10GB]’ or whatever
it is you need.