How to authenticate with cassandra-stress 2.1

cassandra

Is there a way to authenticate to cassandra using the new cassandra-stress tool released with cassandra 2.1? It appears as if the '-un' (username) and '-pw' (password) switches have been removed from the tool.

In the 2.0 version, this is the command I would run:
'cassandra-stress -D nodesfile -un -pw '

The 2.1 version has been totally reworked, and that command fails completely. Looking through the documentation reveals nothing about authenication to the database. Google searches have turned up nothing since it's so new.

I did try one suggestion about putting authentication information into ~/.cassandra/cqlshrc

This seems to work for the cqlsh tool, but not for cassandra-stress. Any suggestions would be greatly appreciated. Thanks!

Best Answer

It seems that it's been moved to the -mode option.

Try cassandra-stress -mode user=username password=password.