Description
ShardCatalogCacheCollectionMetadataMismatchA shard is missing metadata or routing information for a collection.
New in version 8.2.
Format
{
type: "ShardCatalogCacheCollectionMetadataMismatch",
description: "<string>",
details: {
namespace: "<string>",
collectionUUID: UUID("<uuid>"),
details: "<array>"
}
}ShardCatalogCacheCollectionMetadataMismatch inconsistency documents contain these fields:
| Field | Type | Description |
|---|---|---|
| string | Type of inconsistency document. Returns a value of |
| string | Describes the inconsistency found in the metadata. |
| document | Document with additional information on where the inconsistency exists in the database and sharded cluster. |
| string | Indicates the database and collection where the inconsistency exists. |
| UUID | UUID of the collection. |
Example
Use the db.adminCommand() method to call the checkMetadataConsistency command:
db.adminCommand( { checkMetadataConsistency: 1 } )The method returns a cursor with a batch of documents showing the inconsistencies found in the sharding metadata. The example below shows a cursor with a ShardCatalogCacheCollectionMetadataMismatch inconsistency document:
{
cursor: {
id: Long("0"),
ns: "test.$cmd.aggregate",
firstBatch: [
{
type: "ShardCatalogCacheCollectionMetadataMismatch",
description: "Shard is missing metadata or routing information for the collection",
details: {
namespace: "testdb.testcollection",
collectionUUID: new UUID("6dc337aa-4c0f-4f98-bc3a-bdfb516fbf51"),
details: []
}
}
],
},
ok: 1
}