I have a server with runs nodejs applications in multiple ports. those ports are not publically accessible. I want to monitor those ports using check_mk . How can I do this
Asked
Active
Viewed 239 times
0
-
1Hi, welcome to the SO club. Try to update your question and make it a bit more clear. Also please take the [tour](https://stackoverflow.com/tour)! Thanks. – Yasen Sep 20 '19 at 10:47
-
Requests for tutorials, documentation, etc are off-topic here. StackOverflow is dedicated to helping solve programming code problems. Your Q seems more appropriate for https://superuser.com or https://serverfault.com , but read their help section regarding on-topic questions . AND please read [Help On-topic](https://stackoverflow.com/Help/On-topic) and [Help How-to-ask](https://stackoverflow.com/Help/How-to-ask) before posting more Qs here. Good luck. – shellter Sep 20 '19 at 14:18
1 Answers
0
You can check the port that nodejs uses by developing a plugin. server side, checking port 3306:
#!/bin/bash
mysql3306=netstat -an | grep LISTEN | grep 3306 | awk '{print $4}' | sed 's/://g'
echo "<<<checks_ports>>>" if [ "$mysql3306" == "3306" ] then echo "3306 1" else echo "3306 0" fi
Then you need to do the checks on the server check_mk