`
lanhuidong
  • 浏览: 227301 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
社区版块
存档分类
最新评论

Cassadra-0.7.0授权与认证(windows 7)

阅读更多

1.修改配置文件cassandra.yaml,

authenticator: org.apache.cassandra.auth.SimpleAuthenticator

2.在cassandra.bat中加入红色字体表示的部分(注意符号^)

set JAVA_OPTS=^
 -ea^
 -Xms1G^
 -Xmx1G^
 -XX:+HeapDumpOnOutOfMemoryError^
 -XX:+UseParNewGC^
 -XX:+UseConcMarkSweepGC^
 -XX:+CMSParallelRemarkEnabled^
 -XX:SurvivorRatio=8^
 -XX:MaxTenuringThreshold=1^
 -XX:CMSInitiatingOccupancyFraction=75^
 -XX:+UseCMSInitiatingOccupancyOnly^
 -Dcom.sun.management.jmxremote.port=8080^
 -Dcom.sun.management.jmxremote.ssl=false^
 -Dcom.sun.management.jmxremote.authenticate=false^
 -Dlog4j.configuration=log4j-server.properties^
 -Daccess.properties=%CASSANDRA_HOME%\conf\access.properties^
 -Dpasswd.properties=%CASSANDRA_HOME%\conf\passwd.propertiesies

 

3.在access.properties中设置用户权限,如

<modify-keyspaces>=jsmith

Keyspace1.<ro>=jsmith,Elvis Presley
Keyspace1.<rw>=dilbert

 

4.在passwd.properties中设置用户密码,如

jsmith=havebadpass
Elvis\ Presley=graceland4evar
dilbert=nomoovertime

 

5.双击cassandra.bat或者cmd执行cassandra即可启动

 

ps:网上有文章说通过如下命令启动:bin\cassandra -f -Dpasswd.properties=conf/passwd.properties

-Daccess.properties=conf/access.properties,本人在windows下一直启动失败,linux下未曾测试

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics