0

I'm trying to create a cluster with version 3.4, but it keeps giving me an error. The strange thing is that if I try to do it with version 2.1.5 for example, everything runs smoothly.

So for instance if I try to create a cluster with ccm create -v 3.4 -n 3 mycluster This is what I get:

WARN:Downloading 3.4 failed, due to [Errno 2] No such file or directory. Trying to build from git instead.
http://git-wip-us.apache.org/repos/asf/cassandra.git git:cassandra-3.4
Cloning Cassandra...
Traceback (most recent call last):
  File "/usr/local/bin/ccm", line 5, in <module>
    pkg_resources.run_script('ccm==2.1.4', 'ccm')
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 528, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1401, in run_script
    exec(script_code, namespace, namespace)
  File "/usr/local/lib/python2.7/dist-packages/ccm-2.1.4-py2.7.egg/EGG-INFO/scripts/ccm", line 74, in <module>

  File "build/bdist.linux-x86_64/egg/ccmlib/cmds/cluster_cmds.py", line 158, in run
  File "build/bdist.linux-x86_64/egg/ccmlib/cluster.py", line 63, in __init__
  File "build/bdist.linux-x86_64/egg/ccmlib/cluster.py", line 76, in load_from_repository
  File "build/bdist.linux-x86_64/egg/ccmlib/repository.py", line 77, in setup
  File "build/bdist.linux-x86_64/egg/ccmlib/repository.py", line 203, in clone_development
ccmlib.common.CCMError: Building C* version git:cassandra-3.4 failed. Attempted to delete /home/pedro/.ccm/repository/gitCOLONcassandra-3.4 but failed. This will need to be manually deleted

However if I do ls -a /home/pedro/.ccm/repository/ -l, I don't see the folder that had to be manually deleted according to the stacktrace:

total 12
drwxrwxr-x 3 pedro pedro 4096 Mar 25 18:01 .
drwxrwxr-x 3 pedro pedro 4096 Mar 25 17:59 ..
drwxrwxr-x 9 pedro pedro 4096 Mar 25 17:36 2.1.5
-rw-rw-r-- 1 pedro pedro    0 Mar 25 17:59 last.log
Pedro Gordo
  • 1,825
  • 3
  • 21
  • 45

3 Answers3

0

I tried your cluster creation and it works fine for me. I have git 2.5.4 installed might be worth looking at your version of git. I would also look at your java version and update it if you are behind.

Melv
  • 13
  • 4
0

Ok, so it was one of those problems... On my .profile (I'm on Ubuntu), I was initializing the JAVA_HOME, after the PATH, so when the PATH was export the value "JAVA_HOME/bin" didn't existed. Although it's somewhat embarassing, I'm maintaning this post up, because I couldn't possibly figure this out from the output of the error, so maybe this can help someone out.

Pedro Gordo
  • 1,825
  • 3
  • 21
  • 45
0

I ran into this error as well, however my solution was different:

kill the current cassandra process: sudo ps auwx | grep cassandra sudo kill -9 PID

stop the ccm as well: ccm stop

remove the current cluster: ccm remove

build a cluster with the same version of Cassandra that you are running ccm create mycluster -v 3.9 -n 3

Mark Crawford
  • 269
  • 1
  • 4