简体   繁体   中英

How to Find Username Password of cassandra

Well I am new to cassandra and i dont know how to find Username and Password after installing it from a open source. I just install it. When I was going to connect it to netbeans it ask username and password. But in cassandra, i cant find any way to find its username and password. Please tell me steps that I should follow to find my Username and password.

Stop your Cassandra cluster. On each node, cd down to your data directory, and execute:

$ mv system_auth system_auth_20140814

Restart each node. As long as the authenticator is still set (in your cassandra.yaml) to use the PasswordAuthenticator, Cassandra will rebuild the system_auth keyspace, with the default Cassandra super user, which you can use with cqlsh to get back in.

$

./cqlsh -u cassandra -p cassandra
Connected to MyCluster at 127.0.0.1:9042.
[cqlsh 5.0.1 | Cassandra 2.1.0-rc5-SNAPSHOT | CQL spec 3.2.0 | Native protocol v3]
Use HELP for help.
cqlsh>

Notes:

You will have to re-add all of your users, and re-apply all off their permissions. Instead of renaming (mv) the system_auth directory, you could also just delete it (rm). You will have to re-apply the appropriate replication settings to your system_auth keyspace. By default, system_auth only has a replication factor of 1.

If it is a fresh installation try username cassandra and password cassandra

This is the default username and password. Remember to change which can be done via cqlsh.

Hope this helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM