Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cassandra on Windows: Fatal configuration error

We installed Cassandra 2.0.6 in Windows 7 with JRE 7 and we updated the cassandra.yaml file as shown:

data_file_directories: D:\cassandra_data\data
commitlog_directory: D:\cassandra_data\commitlog
saved_caches_directory: D:\cassandra_data\saved_caches

When we are trying to start cassandra server (D:\cassabdra\bin\cassandra.bat) we are getting following error

Starting Cassandra Server
INFO 13:19:39,272 Logging initialized
INFO 13:19:39,299 Loading settings from file:/D:/cassandra/conf/cassandra.yaml
ERROR 13:19:39,540 Fatal configuration error

org.apache.cassandra.exceptions.ConfigurationException: Invalid yaml at org.apache.cassandra.config.YamlConfigurationLoader.loadConfig(YamlConfigurationLoader.java:100) at org.apache.cassandra.config.DatabaseDescriptor.loadConfig(DatabaseDescriptor.java:135) at org.apache.cassandra.config.DatabaseDescriptor.(DatabaseDescriptor.java:111) at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:153) at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:471) at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:560) Caused by: Can't construct a java object for tag:yaml.org,2002:org.apache.cassandra.config.Config; exception=Cannot create property=data_file_directories for JavaBean=org.apache.cassandra.config.Config@1cb839f; No single argument constructor found for class [Ljava.lang.String; in 'reader', line 10, column 1: cluster_name: 'Test Cluster'

like image 672
DaraRamu Avatar asked Mar 14 '14 07:03

DaraRamu


People also ask

Where is the Cassandra configuration file?

The configuration files of Cassandra are located in the /etc/cassandra directory. cassandra. yaml is the file that contains most of the Cassandra configuration, such as ports used, file locations and seed node IP addresses.

How to set JAVA path for Cassandra?

set JAVA_HOME= C:\Program Files\Java\jdk1. 8.0_73 or export JAVA_HOME=/usr/java/jdk1. x.x_x. For Linux-like installs, edit JAVA_HOME in %CASSANDRA_HOME%\bin\cassandra-in.sh.

What is listen_ address in Cassandra?

listen_address. (Default: localhost) The IP address or hostname that Cassandra binds to for connecting to other Cassandra nodes.

What is Cassandra yaml file?

The cassandra. yaml file is the main configuration file for Cassandra. Only the properties that require specific values are covered here. For complete information about all the properties and values, see the Cassandra documentation. Important: After changing properties in the cassandra.

How do I install Cassandra on Windows 10?

To be able to install Cassandra on Windows, first you need to: Download and Install Java 8 and set environment variables. Download and install Python 2.7 and set environment variables. If you already have these dependencies installed, check your version of Python and Java.

Is there a fatal error in Cassandra?

Issue starting Cassandra. A fatal error has been detected by the Java Runtime Environment: - Stack Overflow Issue starting Cassandra. A fatal error has been detected by the Java Runtime Environment: I installed openjdk, and cassandra via brew. I got this error when I started cassandra with cassandra -f:

What are the system requirements for Apache Cassandra?

Apache Cassandra requires Java 8 to run on a Windows system. Additionally, the Cassandra command-line shell (cqlsh) is dependent on Python 2.7 to work correctly. To be able to install Cassandra on Windows, first you need to: Download and Install Java 8 and set environment variables.

What version of Python is required to run Cassandra on Windows?

Additionally, the Cassandra command-line shell ( cqlsh) is dependent on Python 2.7 to work correctly. To be able to install Cassandra on Windows, first you need to:


1 Answers

You should use forward slashes (/), even on Windows:

In you case, it would be:

data_file_directories: 
    - "D:/cassandra_data/data" 
commitlog_directory: "D:/cassandra_data/commitlog" 
saved_caches_directory: "D:/cassandra_data/saved_caches" 
like image 106
jorgebg Avatar answered Oct 30 '22 04:10

jorgebg