cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Carlos Pérez Miguel <cperez...@gmail.com>
Subject Re: specifying initial cassandra schema
Date Tue, 17 Jan 2012 20:35:43 GMT
Hi Ramesh

You can use the schematool command. I am using it for the same
purposes in Cassandra 0.7.9.

I use the following line in my cassandra startup script:

$CASSANDRA_HOME/bin/schematool HOSTNAME 8080 import

where HOSTNAME is the hostname of your test machine. It will import
the schema from your cassandra.yaml file.
If you execute it and there is already a schema in the cassandra
cluster, you'll get a exception from schematool but no impact to the
cluster.

Bye

Carlos Pérez Miguel



2012/1/17 Ramesh Natarajan <ramesh25@gmail.com>:
> I usually start cassandra and then use cassandra-cli to import a
> schema.   Is there any  automated way to load a fixed schema when
> cassandra starts automatically?
>
> I have a test setup where i run cassandra on a single node. I have a
> OS image packaged with cassandra and it automatically starts cassandra
> as a part of OS boot up.
>
> I saw some old references to specify schema in cassandra.yaml.  Is
> this still supported in Cassandra 1.x?  Are there any examples?
>
> thanks
> Ramesh

Mime
View raw message