Error map

WriteConflict: Write conflict during plan execution MongoServerError: WriteConflict error: this operation conflicted with another operation. Please retry your operation or multi-document transaction

MongoDB · layer 5, Data

Open the full error page →

Centre: this error. First ring: errors it is linked with (9). Outer ring: what those are linked with. Colours show the layer of a request each error belongs to. Click any dot to re-centre the map on it; hover to follow its connections. The centre dot opens the error page.

WriteConflict: Write conflict during plan execution — MongoServerError: WriteConflict error: this operation conflicted with another operation. Please retry your operation or multi-document transaction (MongoDB)WriteConfli…the object has been modified — Operation cannot be fulfilled on deployments.apps "x": the object has been modified; please apply your changes to the latest version and try again (Kubernetes)the object has been…ConditionalCheckFailedException — ConditionalCheckFailedException: The conditional request failed (AWS)ConditionalCheckFai…E11000 duplicate key — MongoServerError: E11000 duplicate key error collection: db.users index: email_1 dup key (Node.js)E11000 duplicate keyVersionError: No matching document found for id — Mongoose: VersionError: No matching document found for id "5f..." version 3 modifiedPaths "items" (MongoDB)VersionError: No ma…Atlas: bad auth: Authentication failed — MongoServerError: bad auth : Authentication failed. (Atlas user / special characters in password) (MongoDB)Atlas: bad auth: Au…NoSuchTransaction: Transaction was aborted or expired — MongoServerError: Transaction 1 has been aborted / NoSuchTransaction: transaction has expired (transactionLifetimeLimitSeconds) (MongoDB)NoSuchTransaction: …Sort/Group exceeded memory limit of 100 MB (allowDiskUse) — MongoServerError: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in (MongoDB)Sort/Group exceeded…BSONObj size is invalid / exceeds maximum document size (16MB) — MongoServerError: BSONObj size: 17825792 (0x1100000) is invalid. Size must be between 0 and 16793600(16MB) (MongoDB)BSONObj size is inv…Transaction numbers are only allowed on a replica set member or mongos — MongoServerError: Transaction numbers are only allowed on a replica set member or mongos (MongoDB)Transaction numbers…409 — HTTP 409 Conflict (HTTP)409ConcurrentModificationException — java.util.ConcurrentModificationException (Java)ConcurrentModificat…412 — HTTP 412 Precondition Failed (HTTP)412InterruptedException — java.lang.InterruptedException (sleep interrupted) (Java)InterruptedExceptionTimeoutException — java.util.concurrent.TimeoutException (Java)TimeoutException40001 — ERROR: could not serialize access due to concurrent update (PostgreSQL)400011062 — MySQL ERROR 1062 (23000): Duplicate entry for key (MySQL)106223505 — PostgreSQL: ERROR: duplicate key value violates unique constraint (PostgreSQL)23505buffering timed out — MongooseError: Operation `users.find()` buffering timed out after 10000ms (Node.js)buffering timed outMongoose ValidationError — ValidationError: User validation failed: email: Path `email` is required. (Node.js)Mongoose Validation…OverwriteModelError: Cannot overwrite model once compiled — Mongoose: OverwriteModelError: Cannot overwrite `User` model once compiled. (MongoDB)OverwriteModelError…MissingSchemaError: Schema hasn't been registered for model — Mongoose: MissingSchemaError: Schema hasn't been registered for model "User". Use mongoose.model(name, schema) (MongoDB)MissingSchemaError:…MongoServerSelectionError — MongooseServerSelectionError: connect ECONNREFUSED 127.0.0.1:27017 (Node.js)MongoServerSelectio…NOAUTH — ReplyError: NOAUTH Authentication required. (Node.js)NOAUTHECR token expired — denied: Your authorization token has expired. Reauthenticate and try again. (Amazon ECR) (AWS)ECR token expiredMongoDB Atlas: connection timed out — IP not whitelisted — MongoServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster. One common reason is that you're trying to access the database from an IP that isn't whitelisted (MongoDB)MongoDB Atlas: conn…NotWritablePrimary: not primary and secondaryOk=false — MongoServerError: not primary and secondaryOk=false / NotWritablePrimary: not master (MongoDB)NotWritablePrimary:…OOMKilled — Kubernetes: OOMKilled (exit code 137) (Kubernetes)OOMKilledSIGSEGV — Segmentation fault (core dumped) (Linux)SIGSEGVOOM killer — Killed / Out of memory: Killed process (Linux OOM killer) (Linux)OOM killerEMFILE — Too many open files (EMFILE) (Linux)EMFILECastError ObjectId — CastError: Cast to ObjectId failed for value "x" (type string) at path "_id" (Node.js)CastError ObjectIdRequestEntityTooLargeException — Lambda: Request must be smaller than 6291456 bytes for the InvokeFunction operation (RequestEntityTooLargeException) (AWS)RequestEntityTooLar…No primary found in replica set / ReplicaSetNoPrimary — MongoServerSelectionError: Server selection timed out after 30000 ms — topology type ReplicaSetNoPrimary (MongoDB)No primary found in…Could not find host matching read preference — MongoServerSelectionError: Could not find host matching read preference { mode: "secondary" } for set rs0 (MongoDB)Could not find host…AlreadyInitialized: already initialized — MongoServerError: already initialized (rs.initiate on a configured replica set) (MongoDB)AlreadyInitialized:…

Directly related (9)

the object has been modifiedKubernetes

Operation cannot be fulfilled on deployments.apps "x": the object has been modified; please apply your changes to the latest version and try again

Optimistic-concurrency conflict: the object changed (new resourceVersion) between when you read it and when you tried to update i…

ConditionalCheckFailedExceptionAWS

ConditionalCheckFailedException: The conditional request failed

A write’s ConditionExpression evaluated to false, so DynamoDB didn’t perform it — often exactly as designed.

E11000 duplicate keyNode.js

MongoServerError: E11000 duplicate key error collection: db.users index: email_1 dup key

An insert/update violated a unique index in MongoDB.

VersionError: No matching document found for idMongoDB

Mongoose: VersionError: No matching document found for id "5f..." version 3 modifiedPaths "items"

Mongoose tried to save a document whose array was changed by someone else since you loaded it (optimistic concurrency).

Atlas: bad auth: Authentication failedMongoDB

MongoServerError: bad auth : Authentication failed. (Atlas user / special characters in password)

Atlas rejected the username/password in the connection string.

NoSuchTransaction: Transaction was aborted or expiredMongoDB

MongoServerError: Transaction 1 has been aborted / NoSuchTransaction: transaction has expired (transactionLifetimeLimitSeconds)

A transaction ran longer than the allowed lifetime (60 s default) or was aborted, so later operations fail.

Sort/Group exceeded memory limit of 100 MB (allowDiskUse)MongoDB

MongoServerError: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in

An aggregation stage needed more than 100 MB of RAM and spilling to disk wasn't enabled.

BSONObj size is invalid / exceeds maximum document size (16MB)MongoDB

MongoServerError: BSONObj size: 17825792 (0x1100000) is invalid. Size must be between 0 and 16793600(16MB)

A single document (or an aggregation result row) grew past MongoDB's 16 MB limit.

Transaction numbers are only allowed on a replica set member or mongosMongoDB

MongoServerError: Transaction numbers are only allowed on a replica set member or mongos

You started a transaction (or used retryWrites) on a standalone MongoDB server, which doesn't support them.

Two steps away (26)

409HTTP

HTTP 409 Conflict

The request conflicts with the current state of the resource — e.g. a duplicate or an edit based on an outdated version.

ConcurrentModificationExceptionJava

java.util.ConcurrentModificationException

A collection was modified while being iterated (even in a single thread).

412HTTP

HTTP 412 Precondition Failed

A conditional request header (If-Match, If-Unmodified-Since) didn’t match the current state of the resource.

InterruptedExceptionJava

java.lang.InterruptedException (sleep interrupted)

A blocked thread (sleep, wait, join, queue take) was interrupted by another thread.

TimeoutExceptionJava

java.util.concurrent.TimeoutException

A Future.get(timeout) or async operation didn’t complete in the allowed time.

40001PostgreSQL

ERROR: could not serialize access due to concurrent update

A REPEATABLE READ/SERIALIZABLE transaction conflicted with a concurrent one and must be retried.

1062MySQL

MySQL ERROR 1062 (23000): Duplicate entry for key

An INSERT/UPDATE would create a duplicate value in a PRIMARY or UNIQUE key.

23505PostgreSQL

PostgreSQL: ERROR: duplicate key value violates unique constraint

An INSERT/UPDATE would create a duplicate in a UNIQUE or PRIMARY KEY column — or the id sequence is behind the existing data.

buffering timed outNode.js

MongooseError: Operation `users.find()` buffering timed out after 10000ms

Mongoose queued a query waiting for a connection that never opened.

Mongoose ValidationErrorNode.js

ValidationError: User validation failed: email: Path `email` is required.

A document failed Mongoose schema validation before saving.

OverwriteModelError: Cannot overwrite model once compiledMongoDB

Mongoose: OverwriteModelError: Cannot overwrite `User` model once compiled.

`mongoose.model('User', schema)` was called twice with the same name, typically from hot reloading.

MissingSchemaError: Schema hasn't been registered for modelMongoDB

Mongoose: MissingSchemaError: Schema hasn't been registered for model "User". Use mongoose.model(name, schema)

You used `populate()`/`ref` for a model that hasn't been registered yet.

MongoServerSelectionErrorNode.js

MongooseServerSelectionError: connect ECONNREFUSED 127.0.0.1:27017

The MongoDB driver couldn’t find a reachable server for the connection string.

NOAUTHNode.js

ReplyError: NOAUTH Authentication required.

The Redis server requires a password (or ACL user) but the client didn’t authenticate.

ECR token expiredAWS

denied: Your authorization token has expired. Reauthenticate and try again. (Amazon ECR)

Docker’s login to Amazon ECR has expired — ECR tokens last 12 hours, so pushes and pulls fail until you log in again.

MongoDB Atlas: connection timed out — IP not whitelistedMongoDB

MongoServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster. One common reason is that you're trying to access the database from an IP that isn't whitelisted

Atlas rejects connections from IP addresses that aren't in the project's Network Access list.

NotWritablePrimary: not primary and secondaryOk=falseMongoDB

MongoServerError: not primary and secondaryOk=false / NotWritablePrimary: not master

A write (or read without secondary preference) hit a secondary — the primary changed or you connected directly to a secondary.

OOMKilledKubernetes

Kubernetes: OOMKilled (exit code 137)

The container used more memory than its limit, and the kernel killed it.

SIGSEGVLinux

Segmentation fault (core dumped)

A program accessed memory it wasn’t allowed to, and the kernel killed it with SIGSEGV (exit code 139).

OOM killerLinux

Killed / Out of memory: Killed process (Linux OOM killer)

The kernel ran out of memory and killed a process to recover — the program just prints “Killed” (exit code 137).

EMFILELinux

Too many open files (EMFILE)

The process hit its file-descriptor limit — sockets, files and pipes all count.

CastError ObjectIdNode.js

CastError: Cast to ObjectId failed for value "x" (type string) at path "_id"

A value that isn’t a valid 24-hex-character ObjectId was used in an _id query.

RequestEntityTooLargeExceptionAWS

Lambda: Request must be smaller than 6291456 bytes for the InvokeFunction operation (RequestEntityTooLargeException)

The event payload (or response) is over Lambda’s 6 MB synchronous limit (256 KB for async invocations).

No primary found in replica set / ReplicaSetNoPrimaryMongoDB

MongoServerSelectionError: Server selection timed out after 30000 ms — topology type ReplicaSetNoPrimary

The driver sees the replica set members but none is a primary (election failing or members unreachable).

Could not find host matching read preferenceMongoDB

MongoServerSelectionError: Could not find host matching read preference { mode: "secondary" } for set rs0

The requested read preference (secondary, nearest with tags) matches no available member.

AlreadyInitialized: already initializedMongoDB

MongoServerError: already initialized (rs.initiate on a configured replica set)

`rs.initiate()` was called on a node that already has a replica set configuration.