首页 > 解决方案 > 如何列出 Cassandra shell 中的所有用户?

问题描述

在 CQL shell 中,如何列出所有用户?我似乎在 Stack Overflow 上的任何地方都找不到它。

标签: cassandracql

解决方案


Prior to the introduction of roles in Cassandra 2.2, authentication and authorization were based around the concept of a USER.

Cassandra 2.2 onward CQL uses database roles to represent users and group of users. So to list users use below command accordingly.

LIST USERS;  -- cassandra version < 2.2

LIST ROLES;  -- cassandra version >= 2.2

推荐阅读