[ 
https://issues.apache.org/jira/browse/CASSANDRA-7905?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14127161#comment-14127161
 ] 

Piero Ottuzzi commented on CASSANDRA-7905:
------------------------------------------

Hi there,

   I found my mistake: in cassandra-rackdc.properties I wrote
dc=DC1
rack=RAC1
but in my create keyspace statement I used dc1 (all lower-case).

Obviously this is a mistake on my side but I would suggest to apply 
.toLowerCase() even to properties read from this file.
As it seems to me both keyspaces and tables and columns are all lower-case even 
if you use upper case in CQL statements.

Bye
Piero


> Not enough replica available for query at consistency ONE (1 required but 
> only 0 alive)
> ---------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-7905
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-7905
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>         Environment: Windows 7 32 bit - Oracle JDK 1.8
>            Reporter: Piero Ottuzzi
>             Fix For: 2.1 rc6
>
>
> Hi,
>    I'm toying around with Cassandra and I setup a local 3 node cluster:
> nodetool -u cassandra -pw cassandra -h node01 status
> Starting NodeTool
> Note: Ownership information does not include topology; for complete 
> information, specify a keyspace
> Datacenter: DC1
> ================
> Status=Up/Down
> |/ State=Normal/Leaving/Joining/Moving
> --  Address          Load       Tokens  Owns    Host ID                       
>         Rack
> UN  192.168.118.254  33,38 KB   2       0,1%    
> ab527444-6ea5-4948-8002-3f92ecc2093f  RAC1
> UN  192.168.118.1    49,84 KB   256     50,1%   
> d707d7d1-642b-46b2-8c98-17b02a947088  RAC1
> UN  192.168.118.2    4,09 KB    256     49,8%   
> a6531780-44ce-4eea-ad9d-1c83b7782d43  RAC1
> All nodes are part of DC1/RAC1.
> Then I created a new keyspace:
> CREATE KEYSPACE IF NOT EXISTS loose_data WITH REPLICATION = { 'class' : 
> 'NetworkTopologyStrategy', 'dc1' : 1 } AND durable_writes = false;
> And finally when I try an insert in this keyspace using Datastax Java Driver 
> 2.1 I get:
> com.datastax.driver.core.exceptions.UnavailableException: Not enough replica 
> available for query at consistency ONE (1 required but only 0 alive)
> As you can see above the cluster is running well and the 3 nodes know each 
> other.
> Inspecting keyspace definition I see:
> cqlsh> SELECT * FROM system.schema_keyspaces;
>  keyspace_name | durable_writes | strategy_class                              
>          | strategy_options
> ---------------+----------------+------------------------------------------------------+----------------------------
>     loose_data |          False | 
> org.apache.cassandra.locator.NetworkTopologyStrategy |                
> {"dc1":"1"}
> So, to my noob eyes, everything looks right... what am I missing?
> Thanks in advance
> Sincerely
> Piero



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to