> For the complete MongoDB documentation index, see www.mongodb.com/docs/llms.txt

# Release Notes for MongoDB 9.0

For general guidance on MongoDB version numbering, release types, and upgrade paths, see [MongoDB Versions and Upgrade Paths.](https://www.mongodb.com/docs/mongodb-versions.md#std-label-versions-and-upgrade-paths)

## Patch Releases

### 9.0.4 - Oct 13, 2026

This release contains important security and reliability improvements.

**Important:**

MongoDB 9.0.4 contains fixes for:

- [CVE-2026-96297](https://www.cve.org/CVERecord?id=CVE-2026-96297)

- [CVE-2026-96299](https://www.cve.org/CVERecord?id=CVE-2026-96299)

- [CVE-2026-103965](https://www.cve.org/CVERecord?id=CVE-2026-103965)

- [CVE-2026-104004](https://www.cve.org/CVERecord?id=CVE-2026-104004)

- [CVE-2026-104005](https://www.cve.org/CVERecord?id=CVE-2026-104005)

For the latest information about MongoDB security updates, see [MongoDB Security Bulletins](https://www.mongodb.com/resources/products/alerts?tck=docs).

Issues fixed:

- [SERVER-132946](https://jira.mongodb.org/browse/SERVER-132946) Heap-use-after-free in $\_internalApplyOplogUpdate stage when reading via getMore after aggregate Invocation is destroyed

- [SERVER-130431](https://jira.mongodb.org/browse/SERVER-130431) Mark $graphLookup as DiskUseRequirement::kWritesTmpData

- [SERVER-134618](https://jira.mongodb.org/browse/SERVER-134618) Fix serialization of constant values in $bucket stage

- [SERVER-131412](https://jira.mongodb.org/browse/SERVER-131412) Improve Validation Expression

- [SERVER-131411](https://jira.mongodb.org/browse/SERVER-131411) Improve bulkWrite

- [SERVER-127745](https://jira.mongodb.org/browse/SERVER-127745) Resharding recipient service deadlock on rapid stepdown then stepup

- [SERVER-131625](https://jira.mongodb.org/browse/SERVER-131625) Add Ubuntu 26.04 support for Server.

- [SERVER-132638](https://jira.mongodb.org/browse/SERVER-132638) count with limit 0 fails on a view but works on a collection

- [SERVER-133518](https://jira.mongodb.org/browse/SERVER-133518) StepUp hangs when a stale in-memory chunk operation blocks recovery of a persisted recipient

- [SERVER-133988](https://jira.mongodb.org/browse/SERVER-133988) Deadlock between resharding initialization, chunk migration commit, and setFCV

- [All JIRA issues closed in 9.0.4](https://jira.mongodb.org/issues/?jql=project%20in%20\(SERVER%2CTOOLS%2CWT\)%20AND%20resolution%3D%27Fixed%27%20and%20fixversion%3D%279.0.4%27)

- [9.0.4 Changelog](https://www.mongodb.com/docs/manual/release-notes/9.0-changelog.md#std-label-9.0.4-changelog)

### 9.0.2 - Sept 28, 2026

Issues fixed:

- [SERVER-134970](https://jira.mongodb.org/browse/SERVER-134970) Disable featureFlagChangeStreamOptimizedUpdateLookup

- [SERVER-135099](https://jira.mongodb.org/browse/SERVER-135099) Disable IFR flag featureFlagChangeStreamReaderV2

- [SERVER-134533](https://jira.mongodb.org/browse/SERVER-134533) Starting shard draining during movePrimary can cause metadata inconsistencies

- [SERVER-134808](https://jira.mongodb.org/browse/SERVER-134808) Invalid UTF-8 Database names are not handled well

- [All JIRA issues closed in 9.0.2](https://jira.mongodb.org/issues/?jql=project%20in%20\(SERVER%2CTOOLS%2CWT\)%20AND%20resolution%3D%27Fixed%27%20and%20fixversion%3D%279.0.2%27)

- [9.0.2 Changelog](https://www.mongodb.com/docs/manual/release-notes/9.0-changelog.md#std-label-9.0.2-changelog)

### 9.0.1 - Sept 28, 2026

This release contains important security and reliability improvements.

**Important:**

MongoDB 9.0.1 contains a fix for:

- [CVE-2026-89099](https://www.cve.org/CVERecord?id=CVE-2026-89099)

For the latest information about MongoDB security updates, see [MongoDB Security Bulletins.](https://www.mongodb.com/resources/products/alerts?tck=docs)

Issues fixed:

- [SERVER-134063](https://jira.mongodb.org/browse/SERVER-134063) Shred collection validator constants during parsing

- [All JIRA issues closed in 9.0.1](https://jira.mongodb.org/issues/?jql=project%20in%20\(SERVER%2CTOOLS%2CWT\)%20AND%20resolution%3D%27Fixed%27%20and%20fixversion%3D%279.0.1%27)

- [9.0.1 Changelog](https://www.mongodb.com/docs/manual/release-notes/9.0-changelog.md#std-label-9.0.1-changelog)

### 9.0.0 - Sept 28, 2026

## General Changes

### Change Stream Pre-Image Metrics

Starting in MongoDB 9.0, the `changeStreamPreImages.purgingJob.docsDeleted` and `changeStreamPreImages.purgingJob.bytesDeleted` serverStatus metrics may report estimates rather than exact values. These estimates occur when size and count information is not available for the `config.system.preimages` collection. For details, see [changeStreamPreImages.](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#std-label-server-status-changeStreamPreImages)

MongoDB 9.0 also adds a new `changeStreamPreImages.markerCreation` serverStatus document. This document reports metrics related to the pre-image sampling passes that build the initial truncation information used to remove pre-images. For details, see [changeStreamPreImages.](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#std-label-server-status-changeStreamPreImages)

### Multi-Document Transaction Limit

Starting in MongoDB 9.0, the server limits the number of concurrently open multi-document transactions for external clients. When the number of open transactions reaches the limit set by the [`maxConcurrentMultiDocumentTransactions`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.maxConcurrentMultiDocumentTransactions) parameter (default `10000`), the server rejects new multi-document transactions and returns a `TooManyOpenTransactions` error. To learn more, see [`maxConcurrentMultiDocumentTransactions`.](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.maxConcurrentMultiDocumentTransactions)

### Per-Operation Memory Limit

Starting in MongoDB 9.0, MongoDB limits the total amount of memory that a single query operation can use. By default, the limit is 1 gigabyte or 20% of the memory available to the server process, whichever is greater. Operations that exceed the limit fail with [`ExceededMemoryLimit`](https://www.mongodb.com/docs/manual/reference/error-codes.md#mongodb-error-146) or [`QueryExceededMemoryLimitNoDiskUseAllowed`](https://www.mongodb.com/docs/manual/reference/error-codes.md#mongodb-error-292). In earlier versions, an operation could use an unbounded amount of memory.

The 100 megabyte per-stage memory limit and the spill-to-disk behavior of individual stages are unchanged. To learn more, see [Per-Operation Memory Limit.](https://www.mongodb.com/docs/manual/core/aggregation-pipeline-limits.md#std-label-operation-memory-limit)

You can configure the per-operation memory limit with the following parameters:

- The [`internalQueryMaxMemoryUsageBytesPerOperation`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.internalQueryMaxMemoryUsageBytesPerOperation) parameter limits the total amount of memory that a single query operation can use. The default is 1 gigabyte or 20% of the memory available to the server process, whichever is greater. You can set this parameter at startup or at runtime. You can also configure the parameter with query settings.

- The [`internalQueryMaxSingleExpressionMemoryUsageBytes`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.internalQueryMaxSingleExpressionMemoryUsageBytes) parameter limits the amount of memory that a single expression evaluation can use. The default is 100 megabytes. You can set this parameter at startup or at runtime.

Starting in MongoDB 9.0, the classic query engine reports the `expressionEvaluationPeakMemoryBytes` field in explain output at the `executionStats` verbosity level or higher for the following stages: `$project`, `$addFields`, `$set`, `$unset`, `$replaceRoot`, `$replaceWith`, `$match`, `$bucketAuto`, `$graphLookup`, and `$lookup`. For details, see [Explain Results.](https://www.mongodb.com/docs/manual/reference/explain-results.md#std-label-explain-results)

When an operation fails with [`ExceededMemoryLimit`](https://www.mongodb.com/docs/manual/reference/error-codes.md#mongodb-error-146), the server logs the `Query exceeded the memory limit` message with code `12932700`.

### Server-side JavaScript

Starting in MongoDB 9.0, the server-side JavaScript functions ([`$accumulator`](https://www.mongodb.com/docs/manual/reference/operator/aggregation/accumulator.md#mongodb-group-grp.-accumulator), [`$function`](https://www.mongodb.com/docs/manual/reference/operator/aggregation/function.md#mongodb-expression-exp.-function), and [`$where`](https://www.mongodb.com/docs/manual/reference/operator/query/where.md#mongodb-query-op.-where)) are no longer deprecated. MongoDB 9.0 re-enables these functions using a WebAssembly (WASM)-based JavaScript engine, which improves security through stronger sandboxing and isolation than prior versions. These functions were previously deprecated in MongoDB 8.0.

Server-side JavaScript is not available on the `ppc64le` architecture. To learn more, see [Server-side JavaScript.](https://www.mongodb.com/docs/manual/core/server-side-javascript.md#std-label-server-side-javascript)

### Server Status

MongoDB 9.0 adds the following [`serverStatus`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-dbcommand-dbcmd.serverStatus) metrics:

- [`changeStreamPreImages.markerCreation.scannedInternalCollections`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.changeStreamPreImages.markerCreation.scannedInternalCollections)

- [`changeStreamPreImages.markerCreation.timeElapsedMillis`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.changeStreamPreImages.markerCreation.timeElapsedMillis)

- [`changeStreamPreImages.markerCreation.totalPass`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.changeStreamPreImages.markerCreation.totalPass)

- [`metrics.changeStreams.cursor.batchesReturned`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.batchesReturned)

- [`metrics.changeStreams.cursor.bytesRead`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.bytesRead)

- [`metrics.changeStreams.cursor.bytesReturned`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.bytesReturned)

- [`metrics.changeStreams.cursor.docsExamined`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.docsExamined)

- [`metrics.changeStreams.cursor.docsReturned`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.docsReturned)

- [`metrics.changeStreams.error.nonRetriable.bsonObjectTooLarge`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.nonRetriable.bsonObjectTooLarge)

- [`metrics.changeStreams.error.nonRetriable.changeStreamFatalError`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.nonRetriable.changeStreamFatalError)

- [`metrics.changeStreams.error.nonRetriable.changeStreamHistoryLost`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.nonRetriable.changeStreamHistoryLost)

- [`metrics.changeStreams.error.nonRetriable.other`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.nonRetriable.other)

- [`metrics.changeStreams.error.retriable.interruptedDueToReplStateChange`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.retriable.interruptedDueToReplStateChange)

- [`metrics.changeStreams.error.retriable.other`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.error.retriable.other)

- [`metrics.changeStreams.option.cursor.batchSize`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.cursor.batchSize)

- [`metrics.changeStreams.option.cursor.maxTimeMS`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.cursor.maxTimeMS)

- [`metrics.changeStreams.option.fullDocument.required`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.fullDocument.required)

- [`metrics.changeStreams.option.fullDocument.updateLookup`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.fullDocument.updateLookup)

- [`metrics.changeStreams.option.fullDocument.whenAvailable`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.fullDocument.whenAvailable)

- [`metrics.changeStreams.option.fullDocumentBeforeChange.required`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.fullDocumentBeforeChange.required)

- [`metrics.changeStreams.option.fullDocumentBeforeChange.whenAvailable`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.fullDocumentBeforeChange.whenAvailable)

- [`metrics.changeStreams.option.ignoreRemovedShards`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.ignoreRemovedShards)

- [`metrics.changeStreams.option.matchCollectionUUIDForUpdateLookup`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.matchCollectionUUIDForUpdateLookup)

- [`metrics.changeStreams.option.resumeAfter`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.resumeAfter)

- [`metrics.changeStreams.option.showMigrationEvents`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.showMigrationEvents)

- [`metrics.changeStreams.option.showRawUpdateDescription`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.showRawUpdateDescription)

- [`metrics.changeStreams.option.showSystemEvents`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.showSystemEvents)

- [`metrics.changeStreams.option.startAfter`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.startAfter)

- [`metrics.changeStreams.option.startAtOperationTime`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.startAtOperationTime)

- [`metrics.changeStreams.scope.cluster`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.scope.cluster)

- [`metrics.changeStreams.scope.collection`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.scope.collection)

- [`metrics.changeStreams.scope.db`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.scope.db)

- [`metrics.repl.network.bytesSent`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.repl.network.bytesSent)

- [`metrics.operation.writeConflictRetryLimitHit`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.operation.writeConflictRetryLimitHit)

- [`metrics.operation.writeConflictRetryWaiters`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.operation.writeConflictRetryWaiters)

- [`metrics.query.configuredMaxMemoryUsageBytesPerOperation`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.configuredMaxMemoryUsageBytesPerOperation)

- [`metrics.query.lookupUnwind`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.lookupUnwind)

- [`metrics.query.nonLeadingPushdown.addFields`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.nonLeadingPushdown.addFields)

- [`metrics.query.nonLeadingPushdown.match`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.nonLeadingPushdown.match)

- [`metrics.query.nonLeadingPushdown.project`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.nonLeadingPushdown.project)

- [`metrics.query.nonLeadingPushdown.replaceRoot`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.nonLeadingPushdown.replaceRoot)

- [`metrics.query.operationsFailedDueToMemoryLimit`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.operationsFailedDueToMemoryLimit)

- [`metrics.query.pathArrayness`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.pathArrayness)

- [`metrics.query.pathArrayness.leadingFilter`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.pathArrayness.leadingFilter)

- [`metrics.query.pathArrayness.leadingFilterSimplified`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.pathArrayness.leadingFilterSimplified)

- [`metrics.query.peakMemoryUsageOperation`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.query.peakMemoryUsageOperation)

- [`shardingStatistics.checkMetadataConsistencyStatistics`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.checkMetadataConsistencyStatistics)

- [`shardingStatistics.collectionShardingMetadataStatistics`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics)

- [`shardingStatistics.collectionShardingMetadataStatistics.countCollectionMetadataCacheClears`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countCollectionMetadataCacheClears)

- [`shardingStatistics.collectionShardingMetadataStatistics.countCollectionMetadataCacheSets`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countCollectionMetadataCacheSets)

- [`shardingStatistics.collectionShardingMetadataStatistics.countDiskRecoveriesPerformed`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countDiskRecoveriesPerformed)

- [`shardingStatistics.collectionShardingMetadataStatistics.countInvalidateCollectionMetadataOplogEntriesApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countInvalidateCollectionMetadataOplogEntriesApplied)

- [`shardingStatistics.collectionShardingMetadataStatistics.countInvalidateCollectionMetadataOplogEntriesForDroppedCollections`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countInvalidateCollectionMetadataOplogEntriesForDroppedCollections)

- [`shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataClones`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataClones)

- [`shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataCommits`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataCommits)

- [`shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataDrops`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataDrops)

- [`shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataRenames`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countLocalCollectionMetadataRenames)

- [`shardingStatistics.collectionShardingMetadataStatistics.countMetadataSynchronizersCreated`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countMetadataSynchronizersCreated)

- [`shardingStatistics.collectionShardingMetadataStatistics.countPostRecoveryWaitsResolvedByConfigTime`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countPostRecoveryWaitsResolvedByConfigTime)

- [`shardingStatistics.collectionShardingMetadataStatistics.countPostRecoveryWaitsResolvedByVersionChange`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countPostRecoveryWaitsResolvedByVersionChange)

- [`shardingStatistics.collectionShardingMetadataStatistics.countSetAllowChunkOperationsOplogEntriesApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countSetAllowChunkOperationsOplogEntriesApplied)

- [`shardingStatistics.collectionShardingMetadataStatistics.countUpdateCollectionMetadataChangedChunksApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countUpdateCollectionMetadataChangedChunksApplied)

- [`shardingStatistics.collectionShardingMetadataStatistics.countUpdateCollectionMetadataOplogEntriesApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countUpdateCollectionMetadataOplogEntriesApplied)

- [`shardingStatistics.collectionShardingMetadataStatistics.countVersionMismatchResolutions`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.countVersionMismatchResolutions)

- [`shardingStatistics.collectionShardingMetadataStatistics.totalDiskRecoveryChunksRead`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.totalDiskRecoveryChunksRead)

- [`shardingStatistics.collectionShardingMetadataStatistics.totalDiskRecoveryMillis`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.totalDiskRecoveryMillis)

- [`shardingStatistics.collectionShardingMetadataStatistics.totalPostRecoveryWaitMillis`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.collectionShardingMetadataStatistics.totalPostRecoveryWaitMillis)

- [`shardingStatistics.databaseShardingMetadataStatistics`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics)

- [`shardingStatistics.databaseShardingMetadataStatistics.countCreateDatabaseMetadataOplogEntriesApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countCreateDatabaseMetadataOplogEntriesApplied)

- [`shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataAccessorAccessTypeChanges`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataAccessorAccessTypeChanges)

- [`shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataCacheClears`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataCacheClears)

- [`shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataCacheSets`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countDatabaseMetadataCacheSets)

- [`shardingStatistics.databaseShardingMetadataStatistics.countDbVersionMismatchWaits`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countDbVersionMismatchWaits)

- [`shardingStatistics.databaseShardingMetadataStatistics.countDropDatabaseMetadataOplogEntriesApplied`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countDropDatabaseMetadataOplogEntriesApplied)

- [`shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataClones`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataClones)

- [`shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataCommits`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataCommits)

- [`shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataDrops`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countLocalDatabaseMetadataDrops)

- [`shardingStatistics.databaseShardingMetadataStatistics.countShardCatalogDatabaseWrites`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.countShardCatalogDatabaseWrites)

- [`shardingStatistics.databaseShardingMetadataStatistics.movePrimariesInProgress`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.movePrimariesInProgress)

- [`shardingStatistics.databaseShardingMetadataStatistics.totalDbVersionMismatchWaitMillis`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics.totalDbVersionMismatchWaitMillis)

- [`shardingStatistics.resharding.countSearchIndexAborts`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.resharding.countSearchIndexAborts)

### Renamed Server Status Metrics

MongoDB 9.0 renames the `shardingStatistics.databaseVersionUpdateCounters` document, introduced in MongoDB 8.3, to [`shardingStatistics.databaseShardingMetadataStatistics`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.shardingStatistics.databaseShardingMetadataStatistics). MongoDB 9.0 also replaces the fields of the renamed document with a new set of metrics.

MongoDB 9.0 renames the `metrics.changeStreams.showExpandedEvents` metric to [`metrics.changeStreams.option.showExpandedEvents`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.option.showExpandedEvents). If you monitor the metric by name, update your monitoring to use the new name.

### New Parameters

#### sessionCatalogPartitions Parameter

MongoDB 9.0.1 adds the [`sessionCatalogPartitions`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.sessionCatalogPartitions) parameter, which specifies the number of partitions in the session catalog. Partitioning the session catalog reduces lock contention when there are a large number of sessions.

## Sharding

### `checkMetadataConsistency` Inconsistency Types

MongoDB 9.0 adds the following [`checkMetadataConsistency`](https://www.mongodb.com/docs/manual/reference/command/checkmetadataconsistency.md#mongodb-dbcommand-dbcmd.checkMetadataConsistency) [inconsistency types:](https://www.mongodb.com/docs/manual/reference/inconsistency-type.md#std-label-inconsistency-types)

- [`AuthoritativeShardCatalogCollectionsPresent`](https://www.mongodb.com/docs/manual/reference/inconsistency-type/authoritativeshardcatalogcollectionspresent.md#mongodb-data-AuthoritativeShardCatalogCollectionsPresent)

- [`IncompatibleUniqueIndexOnShardedCollection`](https://www.mongodb.com/docs/manual/reference/inconsistency-type/incompatibleuniqueindexonshardedcollection.md#mongodb-data-IncompatibleUniqueIndexOnShardedCollection)

- [`InconsistentShardCatalogCollectionMetadata`](https://www.mongodb.com/docs/manual/reference/inconsistency-type/inconsistentshardcatalogcollectionmetadata.md#mongodb-data-InconsistentShardCatalogCollectionMetadata)

- [`LegacyShardCacheCollectionsPresent`](https://www.mongodb.com/docs/manual/reference/inconsistency-type/legacyshardcachecollectionspresent.md#mongodb-data-LegacyShardCacheCollectionsPresent)

MongoDB 9.0 removes the `ShardCatalogCacheCollectionMetadataMismatch` inconsistency type.

### `checkMetadataConsistency` Chunk Check Threshold

MongoDB 9.0 adds a `performStrictChunkChecksIfBelowThreshold` option to the [`checkMetadataConsistency`](https://www.mongodb.com/docs/manual/reference/command/checkmetadataconsistency.md#mongodb-dbcommand-dbcmd.checkMetadataConsistency) command. Use this option to set a chunk-count threshold for a shard's chunk comparison. Below the threshold, the command performs a full comparison. At or above it, the command performs a lighter, count-only comparison. For details, see [Chunk Check Threshold.](https://www.mongodb.com/docs/manual/reference/command/checkmetadataconsistency.md#std-label-checkMetadataConsistency-chunk-check-threshold)

### Cursor Namespace in Command Responses

Starting in MongoDB 9.0, when you run a `find`, `aggregate`, or `listIndexes` command on a time series collection, the `cursor.ns` field in the response returns the user-facing namespace you originally targeted. In previous versions, the server could return the internal namespace.

### BSON Validation

MongoDB 9.0 deprecates the [`net.wireObjectCheck`](https://www.mongodb.com/docs/manual/reference/configuration-options.md#mongodb-setting-net.wireObjectCheck) configuration option and its corresponding `--objcheck` and  `--noobjcheckand` CLI arguments. Starting in 9.0, MongoDB validates all BSON objects that the server ingests by default. If the server receives invalid BSON data, MongoDB returns an error.

### Document Validation

MongoDB 9.0 introduces a new schema validation level of `constraint`. With the `constraint` validation level, MongoDB applies the validation rules to all document inserts and updates, and guarantees that *every* document in the collection satisfies the rules. For details, see [Specify constraint Validation.](https://www.mongodb.com/docs/manual/core/schema-validation/specify-validation-level.md#std-label-upgrade-to-constraint-validation)

### Sharding Methods

MongoDB 9.0 introduces the following [`mongosh`](https://www.mongodb.com/docs/mongodb-shell.md#std-program-mongosh) methods:

- [`sh.shardDrainingStatus()`](https://www.mongodb.com/docs/manual/reference/method/sh.sharddrainingstatus.md#mongodb-method-sh.shardDrainingStatus)

- [`sh.getTransitionToDedicatedConfigServerStatus()`](https://www.mongodb.com/docs/manual/reference/method/sh.gettransitiontodedicatedconfigserverstatus.md#mongodb-method-sh.getTransitionToDedicatedConfigServerStatus)

## Time Series

**Note:**

When you upgrade to 9.0, clusters with more than 5,000 time series collections in a single database may take longer to update and face additional write latency spikes. To reduce this impact, drop or delete any unnecessary time series collections.

### Data Storage

Starting in 9.0, MongoDB stores time series collections as a single namespace that contains time series data compressed into buckets. Time series collections are no longer writable non-materialized views.

### renameCollection

Starting in MongoDB 9.0, you can rename time series collections with [`renameCollection`.](https://www.mongodb.com/docs/manual/reference/command/renamecollection.md#mongodb-dbcommand-dbcmd.renameCollection)

## Aggregation

### $queryStats Output

MongoDB 9.0 updates the [`$queryStats`](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#mongodb-pipeline-pipe.-queryStats) output to streamline metrics organization. This update includes the following new output fields:

| Field | Description |
| --- | --- |
| `metrics.cursor` | A document that contains metrics relevant to the cursor and batching protocol |
| `metrics.queryExec` | A document that contains metrics relevant to query execution |
| `metrics.queryPlanner` | A document that contains metrics relevant to the query planner |
| `metrics.writes` | A document that contains metrics relevant to operation writes |

For more information on the new output structure, see [$queryStats Output.](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#std-label-queryStats-output)

#### Command Support

Starting in  9.0, MongoDB collects and reports query statistics for [`update`](https://www.mongodb.com/docs/manual/reference/command/update.md#mongodb-dbcommand-dbcmd.update), [`insert`](https://www.mongodb.com/docs/manual/reference/command/insert.md#mongodb-dbcommand-dbcmd.insert), and [`delete`](https://www.mongodb.com/docs/manual/reference/command/delete.md#mongodb-dbcommand-dbcmd.delete) commands. For details, see [update Command Query Shape](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#std-label-queryStats-update-query-shape), [insert Command Query Shape](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#std-label-queryStats-insert-query-shape), and [delete Command Query Shape.](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#std-label-queryStats-delete-query-shape)

#### Query Stats Enabled by Default

Starting in MongoDB 9.0, `$queryStats` collects stats by default for both read and write operations. MongoDB collects stats for a sample of operations rather than for every operation. MongoDB samples read operations at the rate set by the [`internalQueryStatsSampleRate`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.internalQueryStatsSampleRate) parameter and write operations at the rate set by the [`internalQueryStatsWriteCmdSampleRate`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.internalQueryStatsWriteCmdSampleRate) parameter. Both parameters default to `0.01`, which samples 1% of operations.

Because [`$queryStats`](https://www.mongodb.com/docs/manual/reference/operator/aggregation/querystats.md#mongodb-pipeline-pipe.-queryStats) reports only the operations that MongoDB samples, its output represents a subset of the operations run against your deployment.

## Query Language

### Query Settings as a Command Field

Starting in MongoDB 9.0, you can pass a `querySettings` document directly to the following commands:

- [`find`](https://www.mongodb.com/docs/manual/reference/command/find.md#mongodb-dbcommand-dbcmd.find)

- [`distinct`](https://www.mongodb.com/docs/manual/reference/command/distinct.md#mongodb-dbcommand-dbcmd.distinct)

- [`aggregate`](https://www.mongodb.com/docs/manual/reference/command/aggregate.md#mongodb-dbcommand-dbcmd.aggregate)

These settings apply only to that execution of the command. MongoDB doesn't store the settings on the cluster and doesn't apply them to other queries with the same [query shape.](https://www.mongodb.com/docs/manual/core/query-shapes.md#std-label-query-shapes)

In earlier versions, you could only set query settings with the [`setQuerySettings`](https://www.mongodb.com/docs/manual/reference/command/setquerysettings.md#mongodb-dbcommand-dbcmd.setQuerySettings) command, which stores the settings on the cluster and applies them to every query with the matching query shape.

If a query shape has stored cluster query settings, MongoDB combines those settings with the settings that you pass in the command. If both specify the same field, the stored cluster setting takes precedence.

### Query Knobs

**New in version 9.0**

Starting in MongoDB 9.0, you can override internal server parameters for a single [query shape](https://www.mongodb.com/docs/manual/core/query-shapes.md#std-label-query-shapes) with the `queryKnobs` query setting. The `queryKnobs` setting requires [feature compatibility version](https://www.mongodb.com/docs/manual/reference/command/setfeaturecompatibilityversion.md#std-label-view-fcv) (FCV) `9.0` or later.

For details, see [Query Knobs.](https://www.mongodb.com/docs/manual/reference/command/setquerysettings.md#std-label-setQuerySettings-query-knobs)

### Per-Shape `maxTimeMS`

**New in version 9.0**

Starting in MongoDB 9.0, you can set a `maxTimeMS` time limit for a single [query shape](https://www.mongodb.com/docs/manual/core/query-shapes.md#std-label-query-shapes) with the `setQuerySettings` command. The `maxTimeMS` query setting requires [feature compatibility version](https://www.mongodb.com/docs/manual/reference/command/setfeaturecompatibilityversion.md#std-label-view-fcv) (FCV) `9.0` or later.

For details, see [Command Fields.](https://www.mongodb.com/docs/manual/reference/command/setquerysettings.md#std-label-setQuerySettings-fields)

## Security

### Queryable Encryption Prefix, Suffix, and Substring Query General Availability

MongoDB 9.0 marks the GA of prefix, suffix, and substring queries on encrypted string fields in Queryable Encryption enabled collections. For details, see [enable substring queries](https://www.mongodb.com/docs/manual/core/queryable-encryption/qe-create-encryption-schema.md#std-label-qe-enable-substring-queries) and [Supported Aggregation Expressions.](https://www.mongodb.com/docs/manual/core/queryable-encryption/reference/supported-operations.md#std-label-qe-supported-aggregation-expressions)

To use prefix, suffix, or substring queries with [`mongosh`](https://www.mongodb.com/docs/mongodb-shell.md#mongodb-binary-bin.mongosh), you must separately download the [Automatic Encryption Shared Library](https://www.mongodb.com/docs/manual/core/queryable-encryption/install-library.md#std-label-qe-csfle-install-library) 9.0 or later, then specify the library path to `mongosh` using the [--cryptSharedLibPath](https://www.mongodb.com/docs/mongodb-shell/reference/options/) option.

### `useInternalAuthzForX509` Parameter

MongoDB 9.0 adds the [`useInternalAuthzForX509`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.useInternalAuthzForX509) parameter. When set to `true`, clients that authenticate using `MONGODB-X509` use internal authorization, even when LDAP authorization is configured. For details, see [`useInternalAuthzForX509`.](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.useInternalAuthzForX509)

### `usersInfo` `authenticatedMechanism` Field

MongoDB 9.0 adds the `authenticatedMechanism` field to the [`usersInfo`](https://www.mongodb.com/docs/manual/reference/command/usersinfo.md#mongodb-dbcommand-dbcmd.usersInfo) command. This optional string field specifies an authentication mechanism to determine which authorization backend `usersInfo` queries when looking up user authorization information. For details, see [`usersInfo`.](https://www.mongodb.com/docs/manual/reference/command/usersinfo.md#mongodb-dbcommand-dbcmd.usersInfo)

### `mongocryptd` Deprecated

Starting in MongoDB 9.0, `mongocryptd` is deprecated. Use the Automatic Encryption Shared Library instead. The Automatic Encryption Shared Library replaces `mongocryptd` and does not require you to start a separate process. For details, see [Install and Configure a CSFLE Query Analysis Component](https://www.mongodb.com/docs/manual/core/csfle/reference/install-library.md#std-label-csfle-reference-install-lib) and [Install and Configure a Query Analysis Component.](https://www.mongodb.com/docs/manual/core/queryable-encryption/install-library.md#std-label-qe-csfle-install-library)

### Audit Log Improvements

MongoDB 9.0 adds the `directRemote` field to audit messages in the `mongo` schema and the `direct_endpoint` field to audit messages in the OCSF (Open Cybersecurity Schema Framework) schema. These fields record the literal TCP peer for a session, independent of any client address that a PROXY protocol header asserts. For details, see [mongo Schema Audit Messages](https://www.mongodb.com/docs/manual/reference/audit-message/mongo.md#std-label-event-audit-messages-mongo) and [OCSF Schema Audit Messages.](https://www.mongodb.com/docs/manual/reference/audit-message/ocsf.md#std-label-event-audit-messages-ocsf)

## Replication

### New replSetGetStatus Metrics for Phase Tracking

Starting in MongoDB 9.0, the following metrics are available when using the [`replSetGetStatus`](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-dbcommand-dbcmd.replSetGetStatus) command during a logical initial sync:

- [`replSetGetStatus.initialSyncStatus.phase`](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-data-replSetGetStatus.initialSyncStatus.phase)

- [`replSetGetStatus.initialSyncStatus.totalAttempts`](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-data-replSetGetStatus.initialSyncStatus.totalAttempts)

- [`replSetGetStatus.initialSyncStatus.bytesPerSecond`](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-data-replSetGetStatus.initialSyncStatus.bytesPerSecond)

Each document in [`initialSyncAttempts`](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-data-replSetGetStatus.initialSyncStatus.initialSyncAttempts) also reports the `phase`, `nodeUptimeSecs`, and `phaseDurations` for that attempt. For details, see [`replSetGetStatus.initialSyncStatus.initialSyncAttempts`.](https://www.mongodb.com/docs/manual/reference/command/replsetgetstatus.md#mongodb-data-replSetGetStatus.initialSyncStatus.initialSyncAttempts)

## Diagnostics

### Improved Diagnostics for Unindexable Documents

Starting in MongoDB 9.0, key-extraction failures on [2dsphere](https://www.mongodb.com/docs/manual/core/indexes/index-types/geospatial/2dsphere.md#std-label-2dsphere-index) indexes produce structured diagnostics that make unindexable documents easier to identify:

- Geo key-extraction failures now throw the named error codes [`510`](https://www.mongodb.com/docs/manual/reference/error-codes.md#mongodb-error-510) (`GeoKeyExtractionFailed`) and [`511`](https://www.mongodb.com/docs/manual/reference/error-codes.md#mongodb-error-511) (`GeoKeyExtractionFailedTimeseries`), which replace the previous unnamed assertion codes.

- Failed geo inserts and index builds now include a `writeErrors[].errInfo` document that contains the `failingPath`, `underlyingCode`, `underlyingReason`, and `failingElement` fields. Existing field names are unchanged, but the error reason string is now bounded to 256 characters.

- The [`validate.errors`](https://www.mongodb.com/docs/manual/reference/command/validate.md#mongodb-data-validate.errors) output for geo key-extraction failures now emits a bounded, self-contained message and writes full per-document detail to the [`mongod`](https://www.mongodb.com/docs/manual/reference/program/mongod.md#mongodb-binary-bin.mongod) log. Identical failures on the same index and path are deduplicated into a single message, so to map a failure back to specific documents, consult the log instead of the [`validate`](https://www.mongodb.com/docs/manual/reference/command/validate.md#mongodb-dbcommand-dbcmd.validate) output. Full per-document detail is logged only when [log redaction](https://www.mongodb.com/docs/manual/reference/log-messages.md#std-label-log-message-log-redaction) is disabled. For details, see [`validate`.](https://www.mongodb.com/docs/manual/reference/command/validate.md#mongodb-dbcommand-dbcmd.validate)

### Change Stream Metrics

Starting in MongoDB 9.0, [`serverStatus`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-dbcommand-dbcmd.serverStatus) reports the following change stream cursor metrics on each [`mongod`](https://www.mongodb.com/docs/manual/reference/program/mongod.md#mongodb-binary-bin.mongod) and [`mongos`](https://www.mongodb.com/docs/manual/reference/program/mongos.md#mongodb-binary-bin.mongos) process:

- [`metrics.changeStreams.cursor.open.total`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.open.total), the number of change stream cursors currently open in the process, including idle and pinned cursors.

- [`metrics.changeStreams.cursor.open.pinned`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.open.pinned), the number of open change stream cursors that an operation is actively using.

- [`metrics.changeStreams.cursor.totalOpened`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.totalOpened), the cumulative number of change stream cursors opened in the process, including cursors that have since closed and cursors created when a change stream resumes.

- [`metrics.changeStreams.cursor.lifespan`](https://www.mongodb.com/docs/manual/reference/command/serverstatus.md#mongodb-serverstatus-serverstatus.metrics.changeStreams.cursor.lifespan), the average lifespan, in microseconds, and the total number of the change stream cursors that have closed in the process.

The [`currentOp`](https://www.mongodb.com/docs/manual/reference/command/currentop.md#mongodb-dbcommand-dbcmd.currentOp) command and the [`$currentOp`](https://www.mongodb.com/docs/manual/reference/operator/aggregation/currentop.md#mongodb-pipeline-pipe.-currentOp) stage also report [`currentOp.cursor.changeStreams.optime`](https://www.mongodb.com/docs/manual/reference/command/currentop.md#mongodb-data-currentOp.cursor.changeStreams.optime), the change stream cursor's current position in the oplog. To learn more about change streams, see [MongoDB Change Streams.](https://www.mongodb.com/docs/manual/changestreams.md#std-label-changeStreams)

## Known Issues

This section describes known issues in MongoDB 9.0 and their resolution status.

| In Version | Issue | Status |
| --- | --- | --- |
| 9.0.0, 9.0.1, 9.0.2 | [SERVER-133518](https://jira.mongodb.org/browse/SERVER-133518): A shard can hang during step-up when a chunk operation that was interrupted during a prior step-down blocks recovery of a persisted migration recipient. If the hang occurs, the shard cannot become primary, and writes and reads using primary read preference become unavailable on the shard. Secondaries can continue serving reads. To recover, restart or force-terminate the hung node so another secondary can become a writable primary. | Fixed in MongoDB 9.0.4. |
| 9.0.0 and later | [SERVER-136226](https://jira.mongodb.org/browse/SERVER-136226): Nodes in a sharded cluster open at least [`ShardingTaskExecutorPoolMinSize`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.ShardingTaskExecutorPoolMinSize) connections to each config server. This can exhaust the config servers' available connections and make them unavailable. If [`ShardingTaskExecutorPoolMinSize`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.ShardingTaskExecutorPoolMinSize) is set to a value greater than `1`, set [`ShardingTaskExecutorPoolMinSizeForConfigServers`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.ShardingTaskExecutorPoolMinSizeForConfigServers) to `1` on sharded clusters with dedicated config servers before upgrading to an impacted 9.0 release. If your cluster uses embedded config servers, contact MongoDB Support before upgrading for guidance on the appropriate configuration for your deployment. | Open. |
| 9.0.0 and later | [SERVER-89953](https://jira.mongodb.org/browse/SERVER-89953): At FCV (Feature Compatibility Version) 9.0, [`listIndexes`](https://www.mongodb.com/docs/manual/reference/command/listindexes.md#mongodb-dbcommand-dbcmd.listIndexes) reports `collation: { locale: "simple" }` for indexes that use simple collation. Some object-document mappers (ODMs) interpret this metadata as a difference from an index definition that does not explicitly specify a collation. In Mongoose, this issue causes the `syncIndexes()` method to drop and rebuild otherwise unchanged indexes each time it runs. Applications that call `syncIndexes()` at startup might experience temporarily missing indexes, degraded performance, or service unavailability. If index rebuilds are slow, applications might enter a restart loop. This issue can also affect Doctrine ODM and Beanie. For Beanie, this issue applies when `allow_index_dropping` is `true`. As a workaround, stop calling `syncIndexes()` at application startup. Instead, use `createIndexes()` or run index synchronization as an explicit deployment step. Before running index operations in any environment, you can use `diffIndexes()` to preview which indexes would be created or dropped. If you use Mongoose, upgrade to Mongoose 9.10.4 or 8.24.5, which treat an index definition that does not specify a collation as equivalent to `{ locale: "simple" }`. With these versions, `syncIndexes()` no longer drops unchanged indexes. | Fix targeted for a future 9.0 patch release. |
| 9.0.0 and later | [SERVER-136961](https://jira.mongodb.org/browse/SERVER-136961): If a node has an unclean shutdown for any reason and then restarts to perform a [file copy based initial sync](https://www.mongodb.com/docs/manual/core/replica-set-sync.md#std-label-replica-set-initial-sync-file-copy-based), the node crashes each time it restarts and cannot complete initial sync without manual intervention. To recover a node in a self-managed deployment, do one of the following: Restart the node with the [`initialSyncMethod`](https://www.mongodb.com/docs/manual/reference/parameters.md#mongodb-parameter-param.initialSyncMethod) parameter set to `logical`.; Delete the contents of the node's [`dbPath`](https://www.mongodb.com/docs/manual/reference/configuration-options.md#mongodb-setting-storage.dbPath) directory, then restart the node to begin a new file copy based initial sync. For MongoDB Atlas clusters, contact MongoDB Support to set the `initialSyncMethod` parameter to `logical`. | Open. |
