Uninstall Cassandra

$ sudo su

remove cassandra

$ apt-get remove cassandra

cleaned the cassandra folders

$ rm -rf /var/lib/cassandra

$ rm -rf /var/log/cassandra

$ rm -rf /etc/cassandra

Install Cassandra

Add the DataStax Community repository to the /etc/apt/sources.list.d/cassandra.sources.list

$ echo "deb http://debian.datastax.com/community stable main" | sudo tee -a /etc/apt/sources.list.d/cassandra.sources.list

Add the DataStax repository key to your aptitude trusted keys.

$ curl -L https://debian.datastax.com/debian/repo_key | sudo apt-key add -

If the above doesn’t work try:

curl -L http://debian.datastax.com/debian/repo_key | sudo apt-key add -

And then

sudo apt-get update and then sudo apt-get install cassandra

Configure and run Cassandra

This is the configuration file cassandra reads at startup

$ sudo vi /etc/cassandra/cassandra.yaml

Change authenticator: AllowAllAuthenticator

to authenticator: PasswordAuthenticator



Bring up cassandra when system boots up

$ sudo update-rc.d cassandra enable

use $ cassandra command to enable the cassandra service

then login with following command and you will be able to add new user and create schema:

cqlsh -u cassandra -p cassandra

Create kespace and user

  1. create keyspace rainbowdba with replication = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };

  2. CREATE USER OC_APP_RAINBOWDBA WITH PASSWORD '0b6e8c45df68f6f16d1c494c6ba443c0';

ALTER USER OC_APP_RAINBOWDBA WITH PASSWORD 'a3c224d4b89192d2ea3ea943dd7e9648'; (may change USER to ROLE)

3) Create the schema accordingly

Ubuntu安装Cassandra的更多相关文章

  1. 转】在Ubuntu中安装Cassandra

    原博文出自于: http://blog.fens.me/category/%E6%95%B0%E6%8D%AE%E5%BA%93/ 感谢! Posted: Mar 22, 2014 Tags: cas ...

  2. Mac OS、Ubuntu 安装及使用 Consul

    Consul 概念(摘录): Consul 是 HashiCorp 公司推出的开源工具,用于实现分布式系统的服务发现与配置.与其他分布式服务注册与发现的方案,比如 Airbnb 的 SmartStac ...

  3. ubuntu安装mysql

    好记性不如烂笔头,记录一下,ubuntu安装mysql的指令. 安装MySQL: sudo apt-get install mysql-server sudo apt-get install mysq ...

  4. ubuntu安装vim时提示 没有可用的软件包 vim,但是它被其它的软件包引用了 解决办法

    ubuntu安装vim时提示 没有可用的软件包 vim-gtk3,但是它被其它的软件包引用了 解决办法 本人在ubuntu系统安装vim  输入 sudo apt-get install vim 提示 ...

  5. docker 1.8+之后ubuntu安装指定版本docker-engine

    这边记录ubuntu安装过程,首先是官网文档 If you haven’t already done so, log into your Ubuntu instance. Open a termina ...

  6. debian/ubuntu安装桌面环境

    apt-get install xorg apt-get install gnome 然后startx ubuntu 安装Gnome桌面 1.安装全部桌面环境,其实Ubuntu系列桌面实际上有几种桌面 ...

  7. 一个ubuntu phper的自我修养(ubuntu安装)

    ubuntu安装篇 一.ubuntu下载 到ubuntu官网下载适合自己电脑配置的系统版本,此处不做展开. 二.制作USB启动盘 在windows下制作USB启动盘,工具是universal usb ...

  8. ubuntu 安装JAVA jdk的两种方法:

    ubuntu 安装jdk 的两种方式: 1:通过ppa(源) 方式安装. 2:通过官网下载安装包安装. 这里推荐第1种,因为可以通过 apt-get upgrade 方式方便获得jdk的升级 使用pp ...

  9. [其他]Ubuntu安装genymotion后unable to load VirtualBox engine

    问题: Ubuntu安装genymotion后unable to load VirtualBox engine 解决办法: 如果没有安装VirtualBox,要先安装VirtualBox. 安装Vir ...

随机推荐

  1. Struts2基础学习(一)—初识Struts2

      目录 一.什么是Struts2 二.搭建Struts2的开发环境 三.Struts2的配置文件 四.MVC模式 一.什么是Struts2      Struts2是一个非常优秀的MVC框架,由传统 ...

  2. C/C++中数组与指针的关系探究

    数组与指针 长期以来,在C/C++中,数组名和指向数组首元素的指针常量到底是以一种什么关系,一直困扰着很多人.很多地方,甚至是一些教科书中都在说,"数组名就是一个指向数组首元素的指针常量&q ...

  3. Struts 2 实现登录以及显示信息

    ---恢复内容开始--- 这个星期主要做了一个项目的开始,基于开始学习Struts2的框架首先要先做好Action的按钮 这是我一个Action的展示,chain中是把一个数据带着去跳转另一个网页中 ...

  4. java小题:福尔摩斯的约会

    原题地址:https://www.nowcoder.com/pat/6/problem/4040 防止广告嫌疑,原题为: 题目描述 大侦探福尔摩斯接到一张奇怪的字条:"我们约会吧! 3485 ...

  5. VS2017 Cordova Ionic2 移动开发-环境搭建

    1. 文档概述 本文档用于说明Visual Studio 2017下使用 Ionic 2进行跨平台开发的运行环境配置. 2. 安装环境 Windows10 3. 安装 Visual Studio 20 ...

  6. Spring配置数据源的几种方法

    一:数据源的配置1.通过JNDI配置数据源    1.在tomcat context.xml中配置数据源        <Resource name="jdbc/ds" au ...

  7. ajax的介绍

    $.ajax({ 11 url: "article.asmx/GetArticleByID", 12 type: "POST", 13 datatype: &q ...

  8. openresty源码剖析——lua代码的加载

    ##Openresty是什么 OpenResty是一个基于 Nginx 与 Lua 的高性能 Web 平台,通过把lua嵌入到Nginx中,使得我们可以用轻巧的lua语言进行nginx的相关开发,处理 ...

  9. Java中双向链表的代码实现

    写在前面: 双向链表是一种对称结构,它克服了单链表上指针单向性的缺点,其中每一个节点即可向前引用,也可向后引用,这样可以更方便的插入.删除数据元素. 由于双向链表需要同时维护两个方向的指针,因此添加节 ...

  10. 利用子集构造法实现NFA到DFA的转换

    概述 NFA非有穷自动机,即当前状态识别某个转换条件后到达的后继状态不唯一,这种自动机不便机械实现,而DFA是确定有限状态的自动机,它的状态转换的条件是确定的,且状态数目往往少于NFA,所以DFA能够 ...