MongoDB profiler is an internal tool that enables DBAs and developers to collect information about executed MongoDB requests.
Profiler has three levels:
0 – profile is off
1 – profiler collects information on slow requests
2 – profiler collects all information
For production purposes level 1 is what DBA needs. In general, it is best to set it to some reasonable SLA required threshold, like 1,000 milliseconds (1 second), etc.
Level 2 is best for development purposes to get a complete log of executed requests.
Below is the list of profile related commands:
# set profiling to level 1 capture requests with duration over 500 ms
db.setProfilingLevel(1,500)
#get current profiler level
db.getProfilingLevel()
# get current profiler settings
MongoDB Enterprise > db.getProfilingStatus()
{ "was" : 1, "slowms" : 500 }
To return operations slower than 500 milliseconds, run a query similar to the following:
db.system.profile.find( { millis : { $gt : 50 } } ).pretty()
Enteros UpBeat High Load Capture continuously captures history of executed mongodb requests across all collection as well as other mongo db, OS, SAN and other operational statistics across muliple systems.
When the spike is identified, it can be cross-correlated across MongoDB nodes and correlated with MongoDB requests. A detailed report is generated to pinpoint what requests are were active during the problem time.
Also, please check my presentation on MongoDB performance tuning
The views expressed on this blog are those of the author and do not necessarily reflect the opinions of Enteros Inc. This blog may contain links to the content of third-party sites. By providing such links, Enteros Inc. does not adopt, guarantee, approve, or endorse the information, views, or products available on such sites.
Are you interested in writing for Enteros’ Blog? Please send us a pitch!
RELATED POSTS
Why BFSI Leaders Are Turning to Enteros for Database Optimization, AI Ops, and Cloud FinOps Excellence
- 16 April 2026
- Database Performance Management
Introduction The Banking, Financial Services, and Insurance (BFSI) sector is undergoing a massive digital transformation. With the rise of digital banking, real-time payments, fraud detection systems, and AI-driven financial services, organizations are becoming increasingly dependent on high-performance data infrastructure. From managing millions of transactions per second to enabling real-time risk analysis and personalized customer experiences, … Continue reading “Why BFSI Leaders Are Turning to Enteros for Database Optimization, AI Ops, and Cloud FinOps Excellence”
How to Optimize Telecom Sector Growth with Enteros AIOps Platform, Resource Metadata, Hierarchy Metadata, Spot Instances, and RevOps Efficiency
Introduction The telecom sector is at the center of global digital transformation, enabling connectivity for billions of users, businesses, and emerging technologies like IoT, 5G, and edge computing. As demand for high-speed, reliable communication services continues to rise, telecom providers are under immense pressure to scale operations efficiently while maintaining performance and controlling costs. However, … Continue reading “How to Optimize Telecom Sector Growth with Enteros AIOps Platform, Resource Metadata, Hierarchy Metadata, Spot Instances, and RevOps Efficiency”
Who Should Adopt Enteros for Retail Growth Management with AI SQL and Cloud FinOps Efficiency
Introduction The retail sector is evolving at an unprecedented pace, driven by digital transformation, omnichannel experiences, and data-driven decision-making. From global eCommerce giants to mid-sized retail chains, businesses are increasingly relying on cloud infrastructure, databases, and analytics platforms to fuel growth. However, this rapid expansion introduces a fundamental challenge:how to scale efficiently while maintaining performance, … Continue reading “Who Should Adopt Enteros for Retail Growth Management with AI SQL and Cloud FinOps Efficiency”
How to Optimize Technology Sector Growth with Enteros Database Management Platform, Cloud FinOps, and RevOps Efficiency
Introduction The technology sector is at the forefront of innovation, powering digital transformation across industries. From SaaS platforms and cloud-native applications to AI-driven solutions, technology companies are scaling rapidly to meet growing global demand. However, this rapid expansion introduces a critical challenge:how to sustain growth while maintaining high-performance systems, controlling cloud costs, and aligning operations … Continue reading “How to Optimize Technology Sector Growth with Enteros Database Management Platform, Cloud FinOps, and RevOps Efficiency”