Cassandra死了,但是pid文件存在 [英] Cassandra dead but pid file exists
问题描述
我对cassandra不熟悉,并尝试在centos 7.0上安装cassandra-2.1.2。
完全安装后,执行cqlsh命令并创建一些键空间和列族。
在我看来乍看之下它工作得很好。
I have novice to cassandra and tried my hands to install cassandra-2.1.2 on centos 7.0. After complete installation execute cqlsh command and created few keyspace(s) and column family. Which seems to me in first glance its working perfectly.
但是后来我意识到以下问题:
But later onwards i realized below issues:
1-当我执行 service cassandra status命令时,出现以下错误:
1- when i execute "service cassandra status" command, i got below error:
输出:Cassandra死了,但是pid文件存在。
Output:Cassandra dead but pid file exists.
我搜索了上述问题,并找到了一些链接
I googled the above issue and found some links
http://www.datastax.com/support-forums/topic/dse-dead-but-pid-file-exists
https://baioradba.wordpress.com/2014/06/13/how-to-install-cassandra-on-centos-6-5/
发现我在上面的链接中提到了相同的配置,但是仍然存在相同的错误。
and found that I had same configuration mentioned in above links but the same error still persists.
请告诉我根本原因和解决方法。
Please tell me the root cause and how to resolve it.
2-第二个问题在cassandra.log文件中。
2- Second issue is in the cassandra.log file.
当我分析解析cassandra.log文件时,期望如下:
When I analysed the cassandra.log file there was an expection as :
期待变量URI:[cassandra.config]。请为文件添加前缀file:///(对于本地文件)或file://< server> /(对于远程文件)。正在终止。
下面是完整的日志:
12:01:40.816 [main] ERROR o.a.c.config.DatabaseDescriptor - Fatal configuration error
org.apache.cassandra.exceptions.ConfigurationException: Expecting URI in variable: [cassandra.config]. Please prefix the file with file:/// for local files or file://<server>/ for remote files. Aborting.
at org.apache.cassandra.config.YamlConfigurationLoader.getStorageConfigURL(YamlConfigurationLoader.java:73) ~[apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.config.YamlConfigurationLoader.loadConfig(YamlConfigurationLoader.java:84) ~[apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.config.DatabaseDescriptor.loadConfig(DatabaseDescriptor.java:158) ~[apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.config.DatabaseDescriptor.<clinit>(DatabaseDescriptor.java:133) ~[apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:110) [apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:465) [apache-cassandra-2.1.3.jar:2.1.3]
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:554) [apache-cassandra-2.1.3.jar:2.1.3]
Expecting URI in variable: [cassandra.config]. Please prefix the file with file:/// for local files or file://<server>/ for remote files. Aborting.
致命的配置错误;无法启动。
Fatal configuration error; unable to start. See log for stacktrace.
我再次在google中搜索了相同的问题,但是链接没有那么有用,因为它们包含了cassandra.config的Java类代码。
I again searched the same issue in google and but the links were not that useful as they contained the java class code for cassandra.config .
再次请告知根本原因以及如何解决该问题?
Again please tell the root cause and how to resolve it?
预先感谢。
推荐答案
rm /var/run/cassandra.pid
Run ps -ef | grep cassandra
杀死<< c $ c> pid code> cassandra 进程。
Kill the pid
of the cassandra
process.
开始 cassandra
这篇关于Cassandra死了,但是pid文件存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!