MongoDB平衡器未启动

问题描述 投票:0回答:1

sh.status()

--- Sharding Status --- 
  sharding version: {
    "_id" : 1,
    "minCompatibleVersion" : 5,
    "currentVersion" : 6,
    "clusterId" : ObjectId("5dfa6c3cb121a735f9ad8f6e")
  }
  shards:
        {  "_id" : "s0",  "host" : "s0/localhost:37017,localhost:37018,localhost:37019",  "state" : 1 }
        {  "_id" : "s1",  "host" : "s1/localhost:47017,localhost:47018,localhost:47019",  "state" : 1 }
        {  "_id" : "s2",  "host" : "s2/localhost:57017,localhost:57018,localhost:57019",  "state" : 1 }
  active mongoses:
        "4.2.1" : 1
  autosplit:
        Currently enabled: yes
  balancer:
        Currently enabled:  yes
        Currently running:  no
                Balancer active window is set between 00:00 and 23:59 server local time
        Failed balancer rounds in last 5 attempts:  0
        Migration Results for the last 24 hours: 
                No recent migrations
  databases:
        {  "_id" : "apple",  "primary" : "s2",  "partitioned" : true,  "version" : {  "uuid" : UUID("20431f1a-ddb1-4fac-887e-c4c5db01b211"),  "lastMod" : 1 } }
                apple.user
                        shard key: { "userId" : 1 }
                        unique: false
                        balancing: true
                        chunks:
                                undefined   undefined
                        too many chunks to print, use verbose if you want to force print
        {  "_id" : "config",  "primary" : "config",  "partitioned" : true }
                config.system.sessions
                        shard key: { "_id" : 1 }
                        unique: false
                        balancing: true
                        chunks:
                                undefined   undefined
                        too many chunks to print, use verbose if you want to force print

[使用sh.startBalancer()]开始平衡后,当我看到状态时平衡器的运行状态仍为false。

创建分片时是否需要配置?

sh.status()---分片状态---分片版本:{“ _id”:1,“ minCompatibleVersion”:5,5,“ currentVersion”:6,“ clusterId”:ObjectId(“ 5dfa6c3cb121a735f9ad8f6e”)}分片: ...

mongodb nosql sharding
1个回答
0
投票

当我看到使用sh.startBalancer()开始平衡后,状态平衡器的运行状态仍然为假。

© www.soinside.com 2019 - 2024. All rights reserved.