错误:MongoDB 错误类型:服务器选择超时:没有可用服务器

问题描述 投票:0回答:1

我收到此错误:

Environment variables loaded from .env Prisma schema loaded from prisma\schema.prisma Datasource "db": MongoDB database "cluster0" at "cluster0.skcypxf.mongodb.net" Error: MongoDB error Kind: Server selection timeout: No available servers. Topology: { Type: ReplicaSetNoPrimary, Set Name: atlas-r6xb85-shard-0, Servers: [ { Address: ac-n5qimbd-shard-00-00.skcypxf.mongodb.net:27017, Type: Unknown, Error: Kind: I/O error: received fatal alert: InternalError, labels: {} }, { Address: ac-n5qimbd-shard-00-01.skcypxf.mongodb.net:27017, Type: Unknown, Error: Kind: I/O error: received fatal alert: InternalError, labels: {} }, { Address: ac-n5qimbd-shard-00-02.skcypxf.mongodb.net:27017, Type: Unknown, Error: Kind: I/O error: received fatal alert: InternalError, labels: {} } ] }, labels: {} 0: schema_core::commands::schema_push::Calculate 
来自
 at schema-engine\core\src\commands\schema_push.rs:29      1: schema_core::state::SchemaPush at schema-engine\core\src\state.rs:436

mongodb next.js prisma
1个回答
0
投票

您的服务器使用动态 IP 地址。 您必须更新 MongoDB 的防火墙

© www.soinside.com 2019 - 2024. All rights reserved.