MONGODB 讀書摘要
If you are starting a brand-new set, you can send the configuration to any member in
the set. If you are starting with data on one of the members, you must send the configuration
to the member with data. You cannot initiate a set with data on more than one
member.
如果RS是全新的,無任何資料的,那麼初始化叢集可以在任意一臺機器上,否則應該在存在資料的節點上進行初始化。你不能夠初始化RS,在2個節點都存在資料的時候。
Note that, in both of the use cases above, you need at most one arbiter. You do not need
an arbiter if you have an odd number of nodes. A common misconception seems to be
that you should add extra arbiters “just in case.” However, it doesn’t help elections go
any faster or provide any data safety to add extra arbiters.
Suppose you have a three members set. Two members are required to elect a primary.
If you add an arbiter, you’ll have a four member set, so three members will be required
to choose a primary. Thus, your set is potentially less stable: instead of requiring 67%
of your set to be up, you’re now requiring 75%.
Having extra members can also make elections take longer. If you have an even number
of nodes because you added an arbiter, your arbiters can cause ties, not prevent them.
最多隻需要一個仲裁者,如果節點數是奇數,那就不需要仲裁者。一種錯誤的理解是,為了以防萬一,總是應該新增額外的仲裁者。
假設有3個節點的成員的RS,需要2個成員才能組成大多數,才能選舉為主節點,如果這時新增了一個仲裁者,RS裡就4個成員了,要有3個成員才能組成大多數。因此RS的穩定性降低了。
新增額外成員也會導致選舉耗時變長,由於新增了仲裁者,現在RS一共有偶數個成員,這樣就可能出現成員票數相同的情況。仲裁者的目的應該是避免出現平票,而不是導致出現平票。
the set. If you are starting with data on one of the members, you must send the configuration
to the member with data. You cannot initiate a set with data on more than one
member.
如果RS是全新的,無任何資料的,那麼初始化叢集可以在任意一臺機器上,否則應該在存在資料的節點上進行初始化。你不能夠初始化RS,在2個節點都存在資料的時候。
Note that, in both of the use cases above, you need at most one arbiter. You do not need
an arbiter if you have an odd number of nodes. A common misconception seems to be
that you should add extra arbiters “just in case.” However, it doesn’t help elections go
any faster or provide any data safety to add extra arbiters.
Suppose you have a three members set. Two members are required to elect a primary.
If you add an arbiter, you’ll have a four member set, so three members will be required
to choose a primary. Thus, your set is potentially less stable: instead of requiring 67%
of your set to be up, you’re now requiring 75%.
Having extra members can also make elections take longer. If you have an even number
of nodes because you added an arbiter, your arbiters can cause ties, not prevent them.
最多隻需要一個仲裁者,如果節點數是奇數,那就不需要仲裁者。一種錯誤的理解是,為了以防萬一,總是應該新增額外的仲裁者。
假設有3個節點的成員的RS,需要2個成員才能組成大多數,才能選舉為主節點,如果這時新增了一個仲裁者,RS裡就4個成員了,要有3個成員才能組成大多數。因此RS的穩定性降低了。
新增額外成員也會導致選舉耗時變長,由於新增了仲裁者,現在RS一共有偶數個成員,這樣就可能出現成員票數相同的情況。仲裁者的目的應該是避免出現平票,而不是導致出現平票。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/22034023/viewspace-1162475/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 專利說明書摘要
- 《高效能javascript》閱讀摘要JavaScript
- 《認知驅動》閱讀摘要
- 《認知覺醒》閱讀摘要
- 《HTTP/2 基礎教程》 閱讀摘要HTTP
- 《刻意練習》+《刻意學習》閱讀摘要
- 樊登讀書會-讀書
- 《單核工作法圖解》閱讀摘要單核圖解
- 《讀書與做人》讀書筆記筆記
- 讀書
- mongodb三本好書推薦MongoDB
- Python 潮流週刊第 46 期(摘要)+ 贈書 7 本Python
- Python 潮流週刊第 41 期(摘要),贈書5本Python
- 深度學習聖經“花書”各章摘要與筆記整理深度學習筆記
- 如何讀書
- 讀書方法
- 如何有效的讀一本書?各位讀書人,確定自己真的會讀書嗎?
- CNESA:2022儲能產業研究白皮書(附摘要版下載)產業
- 《如何有效閱讀一本書》讀書筆記筆記
- 論文太多讀不完?AI化身閱讀小助手,可一鍵生成文章摘要!AI
- 讀書小組閱讀列表
- 共同讀書列表
- 讀書筆記筆記
- 讀書日有感
- 讀書打卡 | 參與沸點#讀書打卡#活動來拿技術書籍?
- 運維摘要運維
- redux摘要2Redux
- 2019讀書計劃
- webpackDemo讀書筆記Web筆記
- Vue讀書筆記Vue筆記
- 讀書計劃-2018
- 散文讀書筆記筆記
- Cucumber讀書筆記筆記
- 2020 讀書計劃
- 2018讀書清單
- HTTP 讀書筆記HTTP筆記
- postgres 讀書筆記筆記
- 讀書筆記2筆記
- 讀書筆記3筆記