MongoError:驱动程序与此服务器版本不兼容

时间:2022-11-28 07:00:02

I've just installed Mongo, Node, etc. and when I try to update the database via my nodejs server, I get this error:

我刚刚安装了Mongo,Node等,当我尝试通过我的nodejs服务器更新数据库时,我收到此错误:

MongoError: driver is incompatible with this server version

Here are the versions I have:

以下是我的版本:

  • Node v0.12.2 (latest is v0.12.3)
  • 节点v0.12.2(最新版本是v0.12.3)

  • Express v4.12.4 (latest is v4.12.4)
  • Express v4.12.4(最新版本是v4.12.4)

  • Mongodb v3.0.3 (latest is v3.0.3)
  • Mongodb v3.0.3(最新版本是v3.0.3)

  • Mongodb Node.js Driver v2.0.33 (latest is v2.0.33)
  • Mongodb Node.js驱动程序v2.0.33(最新版本是v2.0.33)

  • Mongoskin v1.3.23 (latest is v1.3.23)
  • Mongoskin v1.3.23(最新版本是v1.3.23)

I have the latest versions of everything, and I've searched the node mongodb driver git to find out what version of mongodb is supported but I couldn't find anything :(

我有一切的最新版本,我已经搜索节点mongodb驱动程序git找出支持mongodb的版本,但我找不到任何东西:(

I also read the other SO questions about it, and it says to update your mongodb, but mine is the latest release!

我还读了关于它的其他SO问题,它说要更新你的mongodb,但我的是最新版本!

Any help?

1 个解决方案

#1


11  

I suspect the mongoskin peerDependency declaration specifying ~1.4 is your issue. To confirm, directly run npm install mongodb@latest and write a test file that requires mongodb directly and connects to and queries your database. I suspect that will work fine which will confirm that the mongoskin peerDependency is the issue. You may need to file an issue with mongoskin and ask them to update to support the 2.x releases of node-mongodb-native.

我怀疑指定~1.4的mongoskin peerDependency声明是你的问题。要确认,直接运行npm install mongodb @ latest并编写一个直接需要mongodb并连接并查询数据库的测试文件。我怀疑它会正常工作,这将确认mongoskin peerDependency是问题。您可能需要向mongoskin提出问题,并要求他们更新以支持node-mongodb-native的2.x版本。

#1


11  

I suspect the mongoskin peerDependency declaration specifying ~1.4 is your issue. To confirm, directly run npm install mongodb@latest and write a test file that requires mongodb directly and connects to and queries your database. I suspect that will work fine which will confirm that the mongoskin peerDependency is the issue. You may need to file an issue with mongoskin and ask them to update to support the 2.x releases of node-mongodb-native.

我怀疑指定~1.4的mongoskin peerDependency声明是你的问题。要确认,直接运行npm install mongodb @ latest并编写一个直接需要mongodb并连接并查询数据库的测试文件。我怀疑它会正常工作,这将确认mongoskin peerDependency是问题。您可能需要向mongoskin提出问题,并要求他们更新以支持node-mongodb-native的2.x版本。