2

Seeing an issue with the Opscenter Agents. Opscenter reports the agents are not connected and in the agent.log on each node, they all report the following:

com.datastax.driver.core.exceptions.NoHostAvailableException: All host(s) tried for query failed (tried: /127.0.0.1:9042 (com.datastax.driver.core. TransportException: [/127.0.0.1:9042] Cannot connect))

I'm not sure when this started, but it's recent and it was working fine previously.

We are running datastax-agent version 5.1.0 and Cassandra version: 2.1.3.

Any tips on where to look would be appreciated.

Phil Burress
  • 133
  • 1
  • 3

1 Answers1

2

EDIT: I am leaving the original answer blockquoted below, but please do not try to follow it. The solution provided here is official and tested working!

As mentioned in the documentation:

Note: As of version 5.1 of OpsCenter, the hosts option in address.yaml now determines which nodes the agent connects to. For further information on configuration changes and migration paths, see the Upgrade Guide.

So, just change your address.yaml to reflect those changes and restart the agent. As an example, in our case we performed the following change from this:

stomp_interface: 10.0.10.10
local_interface: 10.0.10.20

to this:

stomp_interface: 10.0.10.10
hosts: ["10.0.10.20"]

The new hosts property is an array of strings, so you can tailor it down to your needs if you need more than one interfaces. But the above should be enough for a standard setup.

The original answer is lying below, please ignore it.

We have the same problem since we upgraded to Opscenter 5.1.0. The only workaround we found so far is to change the rpc setting in cassandra.yaml:

rpc_address: 0.0.0.0

I know this is NOT a politically correct way, but it does the job without breaking everything and you get your OpsCenter to work until a more official way comes.

PS: I really can't see why anyone would downvote this question, it is a serious problem and it breaks production systems.

Arribah
  • 48
  • 4
  • Do you have opscenter 5.1. collocated with Cassandra DSE 4.6 and cassandra-agent? I've met the same problem and have no idea how to fix it. Right now I'm modifying my Vagrant script to run them on separate VMs – Capacytron Apr 05 '15 at 14:27
  • So it's something related to OpsCenter, DSE and agent collocated on one node. I moved OpsCenter to separate VM and problem with agent failure gone. Weird :( Anyway DataStax recommends to keep OpsCenter on separate node, w'o any Cassandra stuff – Capacytron Apr 05 '15 at 15:16
  • Give me 2 hours and I will update my answer here, there is an official solution :) – Arribah Apr 06 '15 at 08:11
  • Two hours passed :) I would be glad to hear official solution, since I'm running +1 VM locally only for OpsCenter. Would like to collocate OpsCenter with other services. – Capacytron Apr 06 '15 at 11:11
  • Hey, sorry for being late. I'm a devops engineer and these are working hours here, so... :) Anyway, I updated my answer to reflect the changes in 5.1. – Arribah Apr 06 '15 at 12:54