dse-driver connection refused

◇◆丶佛笑我妖孽 提交于 2020-01-07 06:14:15

问题


I am trying to connect to my Datastax enterprise Cassandra install on a server. When I try to connect I receive an error:

Cassandra connection error  { [Error: All host(s) tried for query failed. First host tried, XX.XX.XX.XX:9042: Error: connect ECONNREFUSED XX.XX.XX.XX:9042. See innerErrors.]
  innerErrors:
   { 'XX.XX.XX.XX:9042':
      { Error: connect ECONNREFUSED XX.XX.XX.XX:9042
          at Object.exports._errnoException (util.js:896:11)
          at exports._exceptionWithHostPort (util.js:919:20)
          at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1073:14)
        code: 'ECONNREFUSED',
        errno: 'ECONNREFUSED',
        syscall: 'connect',
        address: 'XX.XX.XX.XX',
        port: 9042 } },
  info: 'Represents an error when a query cannot be performed because no host is available or could be reached by the driver.',
  message: 'All host(s) tried for query failed. First host tried, XX.XX.XX.XX:9042: Error: connect ECONNREFUSED XX.XX.XX.XX:9042. See innerErrors.' }

I am guessing something in cassandra.yaml is restricting connection to localhost?

Any help would be super appreciated! My cassandra.yaml is a bit too long to post, if needed I can publish a link


回答1:


The answer was in /etc/dse/cassandra/cassandra.yaml

broadcast_rpc_address: <node_address (ex: 127.0.0.1)>
rpc_port: 9160 # <-- Probably, unless you changed it
listen_address: localhost # <-- Cassandra to cassandra communication


来源:https://stackoverflow.com/questions/39519381/dse-driver-connection-refused

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!