dcu / mongodb_exporter

MongoDB exporter for prometheus.io
MIT License
356 stars 216 forks source link

What is the metrics to find the db is down or not? #83

Open viggy28 opened 6 years ago

viggy28 commented 6 years ago

I see a lot of metrics, but is there any metric which helps to find whether the db is down or not? Uptime doesn't do the job. (or am i missing something?) I thought if the connection goes to 0, then it potentially means the db is down. Is there a better way? Thanks.

avishefi commented 6 years ago

Look into the serverStatus metrics and replset member health metrics

bryanlarsen commented 6 years ago

@vr001, did you find a good metric to monitor db state? uptime and number of connections do seem like they'd do the trick -- what was the issue with them?