a673575727 2017-08-11 08:49 采纳率: 46.2%
浏览 1736

求解下 我用java链接mongo有错误

SEVERE: Expecting a single StandAlone, but found more than one. Removing 192.168.0.81:27017 from client view of cluster.
Aug 11, 2017 4:43:39 PM com.mongodb.MultiServerCluster handleStandAloneChanged
SEVERE: Expecting a single StandAlone, but found more than one. Removing 192.168.0.82:27017 from client view of cluster.
Exception in thread "Thread-5" com.mongodb.MongoTimeoutException: Timed out after 10000 ms while waiting to connect. Client view of cluster state is {type=Unknown, servers=[]
at com.mongodb.BaseCluster.getDescription(BaseCluster.java:128)
at com.mongodb.DBTCPConnector.getClusterDescription(DBTCPConnector.java:396)
at com.mongodb.DBTCPConnector.getType(DBTCPConnector.java:569)
at com.mongodb.DBTCPConnector.isMongosConnection(DBTCPConnector.java:370)
at com.mongodb.Mongo.isMongosConnection(Mongo.java:645)
at com.mongodb.DBCollection.findOne(DBCollection.java:865)
at com.mongodb.DBCollection.findOne(DBCollection.java:843)
at com.mongodb.DBCollection.findOne(DBCollection.java:789)
at com.gzace.buzz.up.SendThreadTele.isSysUpgrade(SendThreadTele.java:171)
at com.gzace.buzz.up.SendThreadTele.run(SendThreadTele.java:34)
启动jar包时出现这种错误 以前是能正常运行的
而到客户端时
mongo显示
2017-07-14T20:08:03.890+0800 [initandlisten]
2017-07-14T20:08:03.890+0800 [initandlisten] ** WARNING: mongod started without --replSet yet 1 documents are present in local.system.replset
2017-07-14T20:08:03.890+0800 [initandlisten] ** Restart with --replSet unless you are doing maintenance and no other clients are connected.
2017-07-14T20:08:03.890+0800 [initandlisten] ** The TTL collection monitor will not start because of this.
2017-07-14T20:08:03.890+0800 [initandlisten] ** For more info see http://dochub.mongodb.org/core/ttlcollections
2017-07-14T20:08:03.890+0800 [initandlisten]
请问是有什么问题呢

  • 写回答

1条回答 默认 最新

  • Vane11 2017-08-14 05:14
    关注

    应该是mongo的部署方式发生了改变,先查看下mongo的部署方式是否和以前一样吧

    评论

报告相同问题?

悬赏问题

  • ¥15 微信公众号自制会员卡没有收款渠道啊
  • ¥15 stable diffusion
  • ¥100 Jenkins自动化部署—悬赏100元
  • ¥15 关于#python#的问题:求帮写python代码
  • ¥20 MATLAB画图图形出现上下震荡的线条
  • ¥15 关于#windows#的问题:怎么用WIN 11系统的电脑 克隆WIN NT3.51-4.0系统的硬盘
  • ¥15 perl MISA分析p3_in脚本出错
  • ¥15 k8s部署jupyterlab,jupyterlab保存不了文件
  • ¥15 ubuntu虚拟机打包apk错误
  • ¥199 rust编程架构设计的方案 有偿