如何快速定位并确认当前MongoDB数据库的版本及详细信息?

avatar
作者
猴君
阅读量:0
 MongoDB 版本查看及详情: 1、在命令行中连接到 MongoDB 服务器:

mongo

如何快速定位并确认当前MongoDB数据库的版本及详细信息?

 2、使用db.stats() 命令查看当前数据库的基本信息,包括版本号:

db.stats()

 输出结果中会包含version 字段,显示当前数据库的版本。 3、或者,使用show db 命令查看所有数据库的信息,同样包括版本号:

show db

 在输出结果中查找version 字段。 4、如果需要查看更详细的版本信息,可以使用version() 函数:

db.version()

 输出结果将包含以下详细信息:

"buildInfo": {

"version": "4.4.8",

"gitVersion": "4.4.80gd3d8c6e",

"allocator": "tcmalloc",

"buildEnvironment": {

"target_arch": "x86_64",

"settings": {

"sharding": true,

"ssl": true,

"replication": true,

"ipv6": false,

"wireVersion": 15,

"forks": 17,

"cppVersion": "g++ (Ubuntu 9.3.010ubuntu2) 9.3.0",

"modules": [

"src/mongo/db/exec/indexscan.cpp",

"src/mongo/db/exec/sort.cpp",

"src/mongo/db/exec/merge.cpp",

"src/mongo/db/exec/geo_near.cpp",

"src/mongo/db/exec/geo_stats.cpp",

"src/mongo/db/exec/geo_hash.cpp",

"src/mongo/db/exec/query.cpp",

"src/mongo/db/exec/update.cpp",

"src/mongo/db/exec/insert.cpp",

"src/mongo/db/exec/remove.cpp",

"src/mongo/db/exec/update_stage.cpp",

"src/mongo/db/exec/merge_sort.cpp",

"src/mongo/db/exec/distinct.cpp",

"src/mongo/db/exec/distinct_mongos.cpp",

"src/mongo/db/exec/distinct_stage.cpp",

"src/mongo/db/exec/geo_near_mongos.cpp",

"src/mongo/db/exec/geo_stats_mongos.cpp",

"src/mongo/db/exec/geo_hash_mongos.cpp",

"src/mongo/db/exec/query_stage.cpp",

"src/mongo/db/exec/update_stage_mongos.cpp",

"src/mongo/db/exec/merge_sort_mongos.cpp",

"src/mongo/db/exec/distinct_stage_mongos.cpp",

"src/mongo/db/exec/geo_near_stage.cpp",

"src/mongo/db/exec/geo_stats_stage.cpp",

"src/mongo/db/exec/geo_hash_stage.cpp",

"src/mongo/db/exec/query_scan.cpp",

"src/mongo/db/exec/update_scan.cpp",

"src/mongo/db/exec/remove_scan.cpp",

如何快速定位并确认当前MongoDB数据库的版本及详细信息?

"src/mongo/db/exec/distinct_scan.cpp",

"src/mongo/db/exec/geo_near_scan.cpp",

"src/mongo/db/exec/geo_stats_scan.cpp",

"src/mongo/db/exec/geo_hash_scan.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

如何快速定位并确认当前MongoDB数据库的版本及详细信息?

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_mongos.cpp",

"src/mongo/db/exec/distinct_scan_mongos.cpp",

"src/mongo/db/exec/geo_near_scan_mongos.cpp",

"src/mongo/db/exec/geo_stats_scan_mongos.cpp",

"src/mongo/db/exec/geo_hash_scan_mongos.cpp",

"src/mongo/db/exec/query_scan_mongos.cpp",

"src/mongo/db/exec/update_scan_mongos.cpp",

"src/mongo/db/exec/merge_sort_scan_m

    广告一刻

    为您即时展示最新活动产品广告消息,让您随时掌握产品活动新动态!