Timeout to short smtp and pop3

Started by mapsy, December 07, 2010, 04:35:52 PM

Previous topic - Next topic

mapsy

Hi Victor,

When monitoring a smtp service sometimes I get an alarm that the service isn't working. Which is not true.

It sends a test mail, but waits to short for a 250 (queued) answer. The mailserver does send it, checked with Wireshark.

Tried to build the source but with no luck. Need to modify portchecker.
Can you make the time out longer or adjustable?

Many thanks.
Maurice Spronkers

Victor Kirhenshtein

Hi!

Attached is modified portcheck.nsm, which uses same timeout value as for connect to wait for data available from server, so you can use ServiceCheck.SMTP parameter like following:

ServiceCheck.SMTP(host, mail@domain, 5000)

to use 5 seconds timeout on connect and waiting for data. Don't forget that NetXMS server by default waits obnly 2 seconds for results from agent, so if your check takes longer time, you need to increase value of server's configuration parameter AgentCommandTimeout.

Best regards,
Victor

mapsy

Hi Victor,

Thanks for your support.

Kind regards,
Maurice