Docs Menu
Docs Home
/
데이터베이스 매뉴얼
/ / /

CorruptedChunkShardKey

CorruptedChunkShardKey

라우팅 테이블에 컬렉션 샤드 키 에 해당하지 않는 최소 키 또는 최대 키가 있는 청크 가 포함되어 있습니다.

버전 7.0에 추가.

{
type: "CorruptedChunkShardKey",
description: "<string>",
details: {
namespace: "<string>",
collectionUUID: UUID("<uuid>"),
chunk: <chunk>,
shardKeyPattern: <pattern>
}
}

CorruptedChunkShardKey 불일치 문서에는 다음과 같은 필드가 포함되어 있습니다.

필드
유형
설명

type

문자열

불일치 문서의 유형입니다. 이 불일치 유형에 대해 CorruptedChunkShardKey 값을 반환합니다.

description

문자열

메타데이터 에서 발견된 불일치를 설명합니다.

details

문서

데이터베이스와 샤드 cluster에서 불일치가 존재하는 위치에 대한 추가 정보가 포함된 문서입니다.

details.namespace

문자열

불일치가 존재하는 데이터베이스 및 collection을 나타냅니다.

details.collectionUUID

UUID

손상된 청크 샤드 키가 있는 컬렉션의 UUID입니다.

details.chunk

문서

손상된 샤드 키가 있는 청크입니다.

details.shardKeyPattern

문서

collection 샤드 키 패턴입니다.

db.adminCommand() 메서드를 사용하여 checkMetadataConsistency 명령을 호출합니다.

db.adminCommand( { checkMetadataConsistency: 1 } )

이 메서드는 샤딩 메타데이터에서 발견된 불일치를 보여주는 문서 배치와 함께 커서를 반환합니다. 아래 예는 CorruptedChunkShardKey 불일치 문서가 있는 커서를 보여줍니다.

{
cursor: {
id: Long("0"),
ns: "test.$cmd.aggregate",
firstBatch: [
{
type: "CorruptedChunkShardKey",
description: "Found chunk with a shard key pattern violation",
details: {
namespace: "test.authors",
collectionUUID : new UUID("1ad56770-61e2-48e9-83c6-8ecefe73cfc4"),
chunk: {
_id: ObjectId("64ddd81656be208c6685da1b"),
uuid: new UUID("de934e0a-74d2-412b-9bb8-409abe9754e3"),
min: {
y: 0
},
max: {
x: MaxKey
},
shard: "shard0000",
lastmod: Timestamp(1, 0),
onCurrentShardSince: Timestamp(1, 0),
history: [
{
validAfter: Timestamp(1, 0),
shard: "shard0000"
}
]
},
shardKeyPattern: {
x: 1
}
}
}
],
},
ok: 1
}

돌아가기

CollectionUUID불일치

이 페이지의 내용