Comments (6)
2014-12-04 13:26:58 +0100 [error]: unexpected error error_class=Mongo::ConnectionFailure error=#
no error message?
Could you show me entire error message with stacktrace?
from fluent-plugin-mongo.
Here's the full message:
2014-12-09 17:09:41 +0100 [info]: adding match pattern="log.**" type="copy" [376/9753]
2014-12-09 17:09:41 +0100 [info]: adding match pattern="lively.**" type="copy"
2014-12-09 17:09:41 +0100 [error]: unexpected error error_class=Mongo::ConnectionFailure error=#<Mongo::ConnectionFailure: Failed to connect to any given member.>
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/util/pool_manager.rb:182:in `connect_to_members'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/util/pool_manager.rb:52:in `block in connect'
2014-12-09 17:09:41 +0100 [error]: <internal:prelude>:10:in `synchronize'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/util/pool_manager.rb:47:in `connect'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/mongo_replica_set_client.rb:181:in `block in connect'
2014-12-09 17:09:41 +0100 [error]: <internal:prelude>:10:in `synchronize'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/mongo_replica_set_client.rb:170:in `connect'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/mongo_client.rb:645:in `setup'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/mongo_replica_set_client.rb:474:in `setup'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/mongo-1.8.6/lib/mongo/mongo_replica_set_client.rb:147:in `initialize'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluent-plugin-mongo-0.7.3/lib/fluent/plugin/out_mongo_replset.rb:51:in `new'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluent-plugin-mongo-0.7.3/lib/fluent/plugin/out_mongo_replset.rb:51:in `get_connection'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluent-plugin-mongo-0.7.3/lib/fluent/plugin/out_mongo.rb:190:in `get_or_create_collection'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluent-plugin-mongo-0.7.3/lib/fluent/plugin/out_mongo.rb:85:in `start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/plugin/out_copy.rb:50:in `block in start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/plugin/out_copy.rb:49:in `each'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/plugin/out_copy.rb:49:in `start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/match.rb:40:in `start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/engine.rb:257:in `block in start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/engine.rb:256:in `each'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/engine.rb:256:in `start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/engine.rb:207:in `run'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:420:in `run_engine'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:133:in `block in start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:246:in `call'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:246:in `main_process'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:221:in `block in supervise'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:220:in `fork'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:220:in `supervise'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/supervisor.rb:126:in `start'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/lib/fluent/command/fluentd.rb:160:in `<top (required)>'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/gems/fluentd-0.10.50/bin/fluentd:6:in `<top (required)>'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/bin/fluentd:23:in `load'
2014-12-09 17:09:41 +0100 [error]: /usr/lib/fluent/ruby/bin/fluentd:23:in `<top (required)>'
2014-12-09 17:09:41 +0100 [error]: /usr/sbin/td-agent:7:in `load'
2014-12-09 17:09:41 +0100 [error]: /usr/sbin/td-agent:7:in `<main>'
2014-12-09 17:09:41 +0100 [info]: shutting down fluentd
2014-12-09 17:09:41 +0100 [info]: process finished code=0
2014-12-09 17:09:41 +0100 [warn]: process died within 1 second. exit.
from fluent-plugin-mongo.
It seems mongo client judges mongo replica set nodes are dead.
Could you try Mongo::MongoReplicaSetClient.new(nodes)
in simple ruby script?
from fluent-plugin-mongo.
I ran
#!/usr/bin/env ruby
require 'mongo'
Mongo::MongoReplicaSetClient.new(['172.31.48.10:27999'])
with the following result:
/var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/connection/pool_manager.rb:203:in 'connect_to_members': Failed to connect to any given member. (Mongo::ConnectionFailure)
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/connection/pool_manager.rb:70:in 'block in connect'
from <internal:prelude>:10:in 'synchronize'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/connection/pool_manager.rb:65:in 'connect'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/mongo_replica_set_client.rb:209:in 'block in connect'
from <internal:prelude>:10:in 'synchronize'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/mongo_replica_set_client.rb:198:in 'connect'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/mongo_client.rb:661:in 'setup'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/mongo_replica_set_client.rb:513:in 'setup'
from /var/lib/gems/1.9.1/gems/mongo-1.11.1/lib/mongo/mongo_replica_set_client.rb:175:in 'initialize'
from ./check-mongo.rb:4:in 'new'
from ./check-mongo.rb:4:in '<main>'
Which I guess confirms your suspicion.
from fluent-plugin-mongo.
It seems client or your environment problem.
If updating mongo gem version doesn't fix the problem, I don't know why this problem occurs.
from fluent-plugin-mongo.
Thank you for you assistance, it was indeed caused by a characteristic of the mongo driver. It appears that you must use the exact name provided by rs.status() or connection will fail. This means if it isn't resolvable with DNS, you need to add it to your /etc/hosts on your connecting server. Once I did that the connection worked. - found the answer here: http://stackoverflow.com/questions/11714675/mongo-ruby-driver-cannot-connect-to-replica-set-primary
from fluent-plugin-mongo.
Related Issues (20)
- How to transfer data to Amazon DocumentDB HOT 6
- Plugin does not authenticate with mongo server with ssl_verify=true HOT 1
- Error: Failed to build gem native extension HOT 7
- Fluentd can send data to sharded cluster ?
- new release?
- connecting to mongo replicaset and using SSL as well HOT 8
- Specify values types in a MongoDB collection HOT 2
- Mongo::Auth::Unauthorized
- Linux fluend mogon "\xE7" to UTF-8 in conversion from ASCII-8BIT,Mongodb cannot be written in Chinese
- Error: init is specified, but there're parameters without default values:@type (ArgumentError)
- Release new version? HOT 1
- RPC gracefulReload fails for mongo_replset plugin
- Error installing fluent-plugin-mongo
- Dynamic collection name with date from record field error HOT 1
- Logs not forwarding to Atlas HOT 1
- Connection error with MongoDB 6 and authentication HOT 2
- Please provide option to specify ordered-true/false while inserting to Mongo DB - For performance improvements
- Fluentd not able to find fluent-plugin-mongo as input plugin
- MaxBSONSize error from Mongo DB - Marking as Unrecoverable error to stop retry
- Order of strings matters when using object_id_keys HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fluent-plugin-mongo.