In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
1)。 Use serverStatus to monitor in Shell
Use the command after entering the Shell client using the mongo command:
> db.serverStatus ()
Hostnam
> db.serverStatus () .host
Lock information
> db.serverStatus () .locks
Global lock information
> db.serverStatus () .globalLock
Memory information
> db.serverStatus () .mem
Number of connections information
> db.serverStatus () .connections
Additional information
> db.serverStatus () .extra_info
Index statistics
> db.serverStatus () .indexCounters
Background refresh information
> db.serverStatus () .backgroundFlushing
Vernier information
> db.serverStatus () .cursors
Network information
> db.serverStatus () .network
Replica set information
> db.serverStatus () .repl
Operation counter of copy set
> db.serverStatus () .opcountersRepl
Operation counter
> db.serverStatus () .opcounters
Assertion information Asserts
> db.serverStatus () .asserts
WriteBacksQueued
> db.serverStatus () .writeBacksQueued
Persistence (dur)
> db.serverStatus () .dur
Record status information
> db.serverStatus () .recordStats
Working set configuration
> db.serverStatus ({workingSet: 1}) .workingSet
Indicator information metrics
> db.serverStatus () .metrics
To monitor a specific parameter, put the parameter name in db.serverStatus (). And then you can.
2)。 Use mongostat to monitor in Shell
The serverStatus command is static monitoring, and MongoDB provides a dynamic monitoring execution tool, mongostat. Mongostat dynamically outputs some important information provided by serverStatus, once per second. Mongostat is used in the same way as the mongo client, using commands under the mongostat executable:
. / mongostat
If the MongoDB executable Bin directory has been added to the environment variable, use:
Mongostat
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.