Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/cassandra/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Cassandra 使用版本3.4创建群集时出错_Cassandra_Ccm - Fatal编程技术网

Cassandra 使用版本3.4创建群集时出错

Cassandra 使用版本3.4创建群集时出错,cassandra,ccm,Cassandra,Ccm,我试图用3.4版创建一个集群,但它总是给我一个错误。奇怪的是,如果我试着用2.1.5版来做,一切都会顺利进行 例如,如果我尝试使用ccm create-v3.4-n3 mycluster 这就是我得到的: 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/c

我试图用3.4版创建一个集群,但它总是给我一个错误。奇怪的是,如果我试着用2.1.5版来做,一切都会顺利进行

例如,如果我尝试使用
ccm create-v3.4-n3 mycluster
这就是我得到的:

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

我尝试了你的集群创建,它对我来说很好。我已经安装了git 2.5.4,可能值得一看您的git版本。我也会查看您的java版本,如果您落后,我会更新它。

好的,所以这是其中一个问题。。。在我的.profile(我在Ubuntu上)中,我在路径之后初始化JAVA_HOME,因此当路径导出时,“JAVA_HOME/bin”值不存在。
虽然这有点尴尬,但我正在维护这篇帖子,因为我不可能从错误的输出中看出这一点,所以也许这可以帮助某人解决问题。

我也遇到了这个错误,但是我的解决方案不同:

终止当前的cassandra进程: sudo ps auwx | grep cassandra sudo kill-9 PID

同时停止ccm: 连铸机停机

删除当前群集: ccm移除

使用运行的Cassandra的相同版本构建集群 ccm创建mycluster-v3.9-n3

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