잊지 않겠습니다.

NoSQL Solution 검토중, Cassandra 설치 부분에 대해서 번역 및 참고 사항 추가


  • 설정환경 : JAVA 1.6 이상

설치 Progress

  • Download Cassandra application
  • conf/cassandra.yaml 파일 수정
    항목설명Example
    data_file_directoriesDB 파일이 저장될 위치 지정C:\cassandra\data
    commitlog_directoryDB Commit이 발생될 때, 메세지가 저장되는 위치 지정C:\cassandra\commitLogs
    saved_caches_directoryCache의 저장위치C:\cassandra\cache
    storage_portCluster 구성시에 저장 메체들간의 통신 Portdefault:7000
    rpc_portRemote Client Port. Client의 접속 정보를 저장하는 Portdefault:9160
    initial_tokenCluster를 구성시, 첫번째노드로 사용되는 경우에만 0를 설정한다. 다른 경우에는 모두 빈값으로 표시default:(공백)
  • conf/log4j.properties 파일 수정
    항목설명Example
    log4j.appender.R.Filelog4j의 파일 저장 위치/var/log/cassandra/system.log
  • cassandra-env.sh 수정
    항목설명Example
    MAX_HEAP_SIZEcassandra에서 사용할 heap의 사이즈 설정default : 4G, 절대로 작은 값으로 production에 보내지 말것!
    HEAP_NEWSIZEcassandra에서 새로운 heap 요청이 발생하였을 때에, 생성될 sizedefault : 800M, 절대로 작은 값으로 production에 보내지 말것!

위 값들이 너무 작은 경우, OutOfMemory exception이 발생할 가능성이 매우 높음


시작 progress

bin/cassandra.bat -f -- foreground로 실행, CTRL+C로 중지 가능
bin/cassandra.bat    -- background로 실행, Process kill로만 중지 가능

Posted by Y2K
,