I'm seeing this kind of report in many JIRA bugs and I want to generate it for my mongo instance.

What software was used for generating it?

enter image description here


These charts are produced by some internal tools being developed by the MongoDB engineering team for working with time series data as sampled from metrics like MongoDB's serverStatus command and Linux tools such as iostat. There have been a few iterations of tools using languages like Python and Go, but usage and interpretation of data is currently more of an art for engineers familiar with the MongoDB internals. A general challenge is filtering the available metrics into those that are relevant (or possibly relevant) for a performance problem you are trying to understand. The chart images you see in Jira are the result of engineers manually analyzing and filtering metrics of interest.

I'm not aware of a public version of these tools yet, however you should be able to find a library for generating similar compact charts for metrics of interest: the chart format is called sparkline. All of the metrics in your screenshot are from the wiredTiger section of the serverStatus command.

For operational metrics and monitoring, a production environment would normally feed into a metrics aggregation server or service which could provide more interactive monitoring and alerting across your entire deployment(s). For example, MongoDB Cloud Manager (SaaS) and MongoDB Ops Manager (on-premises) both include charts for common metrics. If you want to implement more custom monitoring, a good reference is the list of commands used by the MongoDB Cloud Manager monitoring agent.

MongoDB 3.2+ also includes an FTDC (Full-Time Data Capture) feature which periodically logs metrics (serverStatus, replication status, ...) to compressed files in the diagnostic.data directory in the MongoDB dbPath. The diagnostic history is limited to 200MB of metrics as at MongoDB 3.4. You can see what commands are used in the FTDC source code, eg: src/mongo/db/ftdc/ftdc_mongod.cpp. For versions of MongoDB prior to 3.2 the engineers used to request the same information be collected manually for relevant problematic periods. FTDC information can be useful for MongoDB engineers to be able to request recent metrics history to help diagnose issues for postmortem analysis without having access to your full monitoring solution.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.