Thanks for your response.
I am already using the same plugin. But requirement is, Client requires an alert if 50 matches found in 15 mins. i am using below command, It is triggering alert when 50 matches found. But it considering upcoming polling intervals as well. So if it found 30 matches in first polling interval, It won't stop there. It will take upcoming polling intervals match count into account and trigger an alert when it reaches 50.
command[check_logfilesnew]=/usr/local/nagios/libexec/check_logfiles -t 50 -logfile /tmp/test.log -tag test -criticalpattern "ERROR" -criticalthreshold 50
Is there any way to look for 50 matches in 15 mins in logfile monitor plugin?