Created
June 13, 2017 22:25
-
-
Save javierluraschi/0ce6adf53972e9b8370c3395368f5483 to your computer and use it in GitHub Desktop.
Installing and Initializing Cassandra in OS X
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Install Cassandra: | |
``` | |
curl -OL http://downloads.datastax.com/community/dsc.tar.gz | |
tar -xzf dsc.tar.gz | |
cd dsc-cassandra-3.0.9/bin | |
./cassandra | |
``` | |
Create some tables: | |
``` | |
cd dsc-cassandra-3.0.9/bin | |
./cqlsh | |
CREATE KEYSPACE dev WITH REPLICATION = { | |
'class':'SimpleStrategy','replication_factor':1}; | |
USE dev; | |
CREATE TABLE emp (empid int primary key, emp_name varchar); | |
INSERT INTO emp (empid, emp_name) VALUES (1, 'Fred Smith'); | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment