cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-2563) Error starting up a cassandra cluster after creating a table in the system keyspace: Attempt to assign id to existing column family.
Date Wed, 27 Apr 2011 17:20:03 GMT

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

Hudson commented on CASSANDRA-2563:
-----------------------------------

Integrated in Cassandra-0.8 #46 (See [https://builds.apache.org/hudson/job/Cassandra-0.8/46/])
    disallow making schema changes to system keyspace
patch by jbellis; tested by cdaw for CASSANDRA-2563


> Error starting up a cassandra cluster after creating a table in the system keyspace:
Attempt to assign id to existing column family.
> ------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-2563
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2563
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8 beta 1
>         Environment: Branch: cassandra-0.8; git pull @ 11:30amPST on 4/26
> Server: RHEL5.5 single node
>            Reporter: Cathy Daw
>            Assignee: Jonathan Ellis
>            Priority: Critical
>             Fix For: 0.8.0
>
>         Attachments: 2563.txt, cassandra.2563.tar
>
>
> *Repro Steps*
> * rm -rf /var/lib/cassandra/*
> * rm -rf /var/log/cassandra/*
> * Start Cassandra
> * In cqlsh, create a column family and insert data
> {noformat}
> cqlsh> CREATE COLUMNFAMILY users (
>    ...   KEY varchar PRIMARY KEY,
>    ...   password varchar,
>    ...   gender varchar,
>    ...   session_token varchar,
>    ...   state varchar,
>    ...   birth_year bigint);
> cqlsh> INSERT INTO users (KEY, password, gender, state, birth_year) VALUES ('user1',
'ch@ngem3', 'f', 'CA', '1971');
> cqlsh> INSERT INTO users (KEY, password, gender, state, birth_year) VALUES ('user2',
'ch@ngem3', 'f', 'CA', '1972');
> cqlsh> INSERT INTO users (KEY, password, gender, state, birth_year) VALUES ('user3',
'ch@ngem3', 'f', 'CA', '1973');
> {noformat}
> * Quit cqlsh
> * Kill Cassandra
> * Startup Cassandra and get error
> {noformat}
>  INFO 18:38:24,509 Loading schema version 087af100-7034-11e0-0000-242d50cf1fde
> ERROR 18:38:24,774 Exception encountered during startup.
> java.io.IOError: org.apache.cassandra.config.ConfigurationException: Attempt to assign
id to existing column family.
> 	at org.apache.cassandra.config.DatabaseDescriptor.loadSchemas(DatabaseDescriptor.java:489)
> 	at org.apache.cassandra.service.AbstractCassandraDaemon.setup(AbstractCassandraDaemon.java:138)
> 	at org.apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandraDaemon.java:313)
> 	at org.apache.cassandra.thrift.CassandraDaemon.main(CassandraDaemon.java:80)
> Caused by: org.apache.cassandra.config.ConfigurationException: Attempt to assign id to
existing column family.
> 	at org.apache.cassandra.config.CFMetaData.map(CFMetaData.java:126)
> 	at org.apache.cassandra.config.DatabaseDescriptor.loadSchemas(DatabaseDescriptor.java:485)
> 	... 3 more
> Exception encountered during startup.
> java.io.IOError: org.apache.cassandra.config.ConfigurationException: Attempt to assign
id to existing column family.
> 	at org.apache.cassandra.config.DatabaseDescriptor.loadSchemas(DatabaseDescriptor.java:489)
> 	at org.apache.cassandra.service.AbstractCassandraDaemon.setup(AbstractCassandraDaemon.java:138)
> 	at org.apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandraDaemon.java:313)
> 	at org.apache.cassandra.thrift.CassandraDaemon.main(CassandraDaemon.java:80)
> Caused by: org.apache.cassandra.config.ConfigurationException: Attempt to assign id to
existing column family.
> 	at org.apache.cassandra.config.CFMetaData.map(CFMetaData.java:126)
> 	at org.apache.cassandra.config.DatabaseDescriptor.loadSchemas(DatabaseDescriptor.java:485)
> 	... 3 more
> {noformat}
> *UPDATE:  This issue happens if I create the CF in the default keyspace.*
> *Workaround*
> {noformat}
> cqlsh> CREATE KEYSPACE cqldb with 
>    ...   strategy_class =  
>    ...     'org.apache.cassandra.locator.SimpleStrategy' 
>    ...   and strategy_options:replication_factor=1;
> cqlsh> use cqldb;
> The create the table and insert data.
> {noformat}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message