Search code examples
cassandracassandra-2.0cassandra-cli

Unable to run ccm cli (Cassandra Cluster Manager) on mac


I am trying to run ccm [node] cli on mac but am getting the errors below.
I am using cassandra v2.2.0 and ccm 2.0.3.

11:32:32: ~/opt $ ccm node1 cli
Traceback (most recent call last):
  File "/usr/local/bin/ccm", line 72, in <module>
    cmd.run()
  File "/usr/local/lib/python2.7/site-packages/ccmlib/cmds/node_cmds.py", line 338, in run
    self.node.run_cli(self.options.cmds, self.options.verbose, self.cli_options)
  File "/usr/local/lib/python2.7/site-packages/ccmlib/node.py", line 634, in run_cli
    os.execve(cli, [common.platform_binary('cassandra-cli')] + args, env)
OSError: [Errno 2] No such file or directory

Solution

  • os.execve(cli, [common.platform_binary('cassandra-cli')] + args, env)
    

    It's trying to execute the casssandra-cli command, but cmm can't find it.

    You say you're using Cassandra 2.2.0. In this version of Cassandra, the CLI utility was removed. If you want, you can use version 2.1.9, the last version where this tool is included.

    Anyway, the CLI utility is deprecated. It's recommended to switch from Thrift and CLI to CQL and cqlsh.

    See these references:

    http://docs.datastax.com/en/cassandra/2.1/cassandra/reference/referenceStorage_r.html

    http://www.datastax.com/dev/blog/datastax-community-2-2-0-is-ready-for-download