简体   繁体   中英

Unable to start Cassandra DataStax DDC Server

I have a fresh installation of Cassandra 3.7 with DatStax DDC in Windows. I am trying to start the Cassandra database as a service.I am using net start DataStax_DDC_Server to start the service. The service is not starting and exiting without reporting an error. I am getting the following error in the logs.

java.lang.RuntimeException: Failed to create failed snapshot tracking file [C:\Cassandra\.toDelete]. Aborting
    at org.apache.cassandra.db.WindowsFailedSnapshotTracker.deleteOldSnapshots(WindowsFailedSnapshotTracker.java:99)
    at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:177)
    at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:585)
    at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:714)

What is causing this error and how do I fix this?

Look at the logs in the installation folder. Eg c:\\Program Files\\DataStax-DDC\\logs .

The datastax_ddc_server-stderr.xxxxx.log will give you details about what the problem is. For me the error was cdc_raw_directory is missing and -Dcassandra.storagedir is not set so i opened c:\\Program Files\\DataStax-DDC\\apache-cassandra\\conf\\cassandra.yaml , found the cdc_raw_directory setting and simply uncommented it.

After fixing that you also get an Error when you will try to run cassandra.bat from command line.

it will tell you that \\conf\\\\\\hotspot_compiler cannot be found

Fix: go to C:\\Program Files\\DataStax-DDC\\apache-cassandra\\conf

modify cassandra-env.ps1

just change CASSANDRA_CONF\\conf\\hotsport_compiler to CASSANDRA_HOMEconf\\hotsport_compiler

WITHOUT the backslash... this is not a typo ^^

finally cassandra.bat will start and cqlshell will work.

.. then close the command window where you started cassandra.bat (as admin) press CONTROL+C

..and finally you can start the service as admin: net start DataStax_DDC_Server

Below is the process that i followed to get my cqlsh working on windows 10 (64 bit)

Msi Installation file used : datastax-ddc-64bit-3.9.0

After i have installed datastax: 1) Opened cqlsh, it started closing on me. 2) researched answers in stack overflow and found that i need to add raw directory. 3) Based on TugboatCaptain answer I enclosed cdc_raw_directory based on my installation folder in conf\\cassandra.yaml file 4) Opened Errlog file and noticed there is mistake showing in the path "C:\\Program Files\\DataStax-DDC\\data\\cdc_raw" at "\\DataStax-DDC" error while scanning double quoted scalar. 5) I removed "\\" before "DataStax-DDC" from cdc_raw_directory value in conf\\cassandra.yaml file and started Datastax DDC Server 3.9.0 6) Opened again the Err file and noticed the error is shifted to "\\data" 7) I removed "\\" from cdc_raw_directory in conf\\cassandra.yaml file and saved the file and started Datastax DDC Server 3.9.0 8) Opened again the Err file and noticed the error is shifted to "\\data" 9) repeated the process of removing "\\" and saved the file until i was able to start the service. 10) Finally my service started, Hope this helps and also attached screenshots from my pc.

Finally my cdc_raw_directory value looked like below:

Final Image from "conf\\cassandra.yaml" once my service has started

This is the my cqsl shell screenshot

Mylog file(logs\\datastax_ddc_server-stderr.2019-03-24.log) screenshot

I had the same problem (I'd start and it automatically says service stopped). I got it fixed as follows:

go to C:\\Program Files\\DataStax-DDC\\apache-cassandra\\conf edit cassandra.yaml

change

cdc_raw_directory: /var/lib/cassandra/cdc_raw

to: cdc_raw_directory: "C:/Program Files/DataStax-DDC/data/cdc_raw"

Make sure that there are no spaces before "cdc_raw_directory" ie not " cdc_raw_directory" because Python is space sensitive

尝试以管理员身份运行CMD提示,为我解决了问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM