How to reset default Cassandra credentials without changing source code?
I have check similar problems like How to reset a lost Cassandra admin user's password?. I have three node cluster of Datastax Cassandra 2.0.8 and I am trying to implement authentication. I have set cassandra.yaml in all nodes and restarted them. Problem is that I still cannot login in to cqlsh.
I have also tried to reset password for cassandra user in cqlsh(I have disabled authentication for that):
update system_auth.credentials set salted_hash='$2a$10$vbfmLdkQdUz3Rmw.fF7Ygu6GuphqHndpJKTvElqAciUJ4SZ3pwquu' where username='cassandra';
In logs there is Info about creating cassandra superuser. I have checked keyspace system_auth and it includes credentials,permissions and users. And credentials column family does contain user cassandra:
cqlsh> use system_auth;
cqlsh:system_auth> select * from credentials;
username | options | salted_hash
-----------+---------+---------------------------------------------------------- ----
cassandra | null | $2a$10$vbfmLdkQdUz3Rmw.fF7Ygu6GuphqHndpJKTvElqAciUJ4SZ3pw quu
(1 rows)
But still, when I try:
./cqlsh -u cassandra -p cassandra
I get exception, that user does not exists, but I dont have permissions to create one.
cql.cassandra.ttypes.AuthenticationException: AuthenticationException(why="User cassandra doesn't exist - create it with CREATE USER query first")