MongoDB DBA · Question 285 · Multiple choice

3. Which of the following statements are always true about shard keys? Check all that apply:

Answer options

  1. A.
    Shard keys are permanent: the selected shard key cannot be changed after sharding
  2. B.
    Shard keys must be supported by an index
  3. C.
    Shard key values must be unique: the shard key value in every document in the sharded collection must be unique

Answer confidence: High

Correct answer: A, B

Explanation language: Chinese

在 4.4/考试语境中分片键一经分片就不可更改(5.0 起才可通过 reshardCollection 重分片或 refineCollectionShardKey 微调),A 是考点;分片键必须有一个以它为前缀的索引支撑,创建分片集合时 MongoDB 会自动建立(C)。B 错:分片键值不要求唯一,唯一性只由 _id 保证。

Papers containing this question

This question appears in 3 bank records. Public pages combine identical prompts and options. Selected questions display the highest-confidence record; the others show a short preview. Paper-based learning preserves each record's answer, explanation, and confidence.

AUTHOR · PROJECTS · OPEN SOURCE

Author & MongoDB projects

Building data platforms, MongoDB migration and sync tools, and cloud operations products.

Contact the author for any MongoDB needs.

Contact the author ↗mlhp123@outlook.com

Support the author

If this question bank helps you, optional donations are welcome.

Scan with Alipay to support the authorOpen full-size donation image ↗