Cassandra-install deployment on the Windows platform. If you are interested in no SQL, please come in and check it out.

Source: Internet
Author: User
Tags cassandra

I. Introduction to casscanra

 

Apache Cassandra is an open-source distributed nosql database system. It was initially developed by Facebook to store inbox and other simple format data. It integrates Google bigtable data models with Amazon Dynamo's fully distributed architecture. Facebook opened Cassandra in 2008. Since then, because of its excellent scalability, Cassandra has been adopted by well-known web_2.0 websites such as Digg and Twitter, and has become a popular distributed structured data storage solution.

Cassandra highlights:

    1. Flexible mode: with Cassandra, such as document storage, you do not have to solve the field in the record in advance. You can add or remove columns when the system is running. This is an amazing improvement in efficiency, especially in large-scale deployment.
    2. Real Scalability: Cassandra is purely horizontal scaling. To add more capacity to the cluster, you can point to another computer. You do not have to restart any process, change application queries, or manually migrate any data.
    3. Multi-Data Center Identification: You can adjust the node layout to avoid a data center fire. A backup data center will have at least full replication of each record.

Some other features that make Cassandra more competitive:

    1. Range Query: if you do not like all key-value queries, you can set the range of keys to query.
    2. List Data Structure: you can add a super column to a 5-dimension table in hybrid mode. This is very convenient for each user's index.
    3. Distributed write operation: allows you to read or write any data in a centralized manner at any time. And there will be no single point of failure.

Ii. installation and deployment

1. Preparation

Http://cassandra.apache.org/download/, the latest version is 0.6.1, can be downloaded directly on the official website.

If the message "The java_home environment variable must be set to run this program ",

Then install the sun Jdk-6 and add the environment variable.

Java_home = D: \ Program Files \ Java \ jdk1.6.0

2. modify the configuration file, find log4j. properties under Conf, and change log4j. appender. R. file to the directory where you store Cassandra,
Log4j. appender. R. File = D: \ webserver \ Cassandra \ log

3. Add Environment Variables
Cassandra_home = D: \ webserver \ cassandra

4, storage-conf.xml configuration file modification, also under the conf file, modify the following nodes to their own directory:
<Commitlogdirectory> D:/webserver/Cassandra/commitlog </commitlogdirectory>
<Datafiledirectories>
<Datafiledirectory> D:/webserver/Cassandra/Data </datafiledirectory>
</Datafiledirectories>

5. Modify the Cassandra. BAT file. Under the bin directory, add a line after the setlocal line to specify the local directory:
Set Cd = D: \ webserver \ cassandra

Run Cassandra. BAT to start. If the configuration is successful, the following prompt is displayed:

starting Cassandra server
listening for transport dt_socket at address: 8888
info 12:54:30, 612 auto diskaccessmode determined to be standard
info 12:54:30, 802 sampling index for D: \ webserver \ Cassandra \ data \ System \ LocationInfo-1-Data.db
info 12:54:30, 817 replaying D: \ webserver \ Cassandra \ commitlog \ CommitLog-1275022117089.log
info 12:54:30, 842 creating new commitlog segment D:/software/webserver/Cassandra/commitlog \ CommitLog-1275022470842.log
info 12:54:30, 857 locationinfo has reached its threshold; switching in a fresh memtable at commitlogcontext (file = 'd:/software/webserver/Cassandra/commitlog \ commitlog-

1275022470842. log', position = 121)
info 12:54:30, 857 enqueuing flush of memtable (locationinfo) @ 22572221
info 12:54:30, 857 writing memtable (locationinfo) @ 22572221
info 12:54:30, 972 completed flushing D: \ webserver \ Cassandra \ data \ System \ LocationInfo-2-Data.db
info 12:54:30, 982 log replay complete
info 12:54:31, 022 saved token found: 58905827723352031130434533459013100020
info 12:54:31, 022 saved clustername found: Test cluster
info 12:54:31, 032 starting up server gossip
info 12:54:31, 072 binding thrift service to localhost/127.0.0.1: 9160
info 12:54:31, 082 Cassandra starting up...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.