NetXMS Support Forum

English Support => General Support => Topic started by: Constantine on August 22, 2024, 03:29:17 PM

Title: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 22, 2024, 03:29:17 PM
Hello! How to make sure that mail does not send notifications about printer errors:
No paper, Door open, Jammed, Low toner, Input tray empty, but notifies by error No toner.
Thanks!




Title: Re: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 22, 2024, 03:33:27 PM
Tried it in different ways, but it didn't work.

Title: Re: Do not report an event by email unless it is "No toner"
Post by: Tatjana Dubrovica on August 23, 2024, 05:00:59 PM
One option is to generate separate event for low tonner and separate event for all other errors - in this case you will just create multiple rules: one for toner (send e-mail) and something else for others (for example to create alarm).

Filtering in in EPP is harder option and for it you should use left side of EPP - filtering side. I would suggest to write filtering script, that will check current DCI value that is available in $event script parameter. 

 
Title: Re: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 26, 2024, 09:39:17 AM
Thank you for your answer, please tell me how to write alarm key like -

DC_THRESHOLD_%i_%<dciId>

for the No toner error.


Title: Re: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 26, 2024, 12:29:28 PM
Colleagues! I think it worked!
Title: Re: Do not report an event by email unless it is "No toner"
Post by: Tatjana Dubrovica on August 26, 2024, 05:03:55 PM
Alarm key can be the same as most probably you have either toner or others and it is not required to make distinction here as they can't coexist
simultaneously for the same device.  
Title: Re: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 27, 2024, 08:47:05 AM
Tell me, how to specify a parameter from dciValue in a script?

Title: Re: Do not report an event by email unless it is "No toner"
Post by: Constantine on August 27, 2024, 08:56:14 AM
$dciValue->value 

it's worked too!