Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Cannot create kudu table after granting database permission

avatar
Explorer

Cannot create kudu table after granting database permission

How to solve this problem?

VERSION:
impala version 3.0.0,kudu version 1.6.0
CDH 6.0.0

Cannot create kudu table after granting database permission。

[bigdata5:21000] yydp_kudu> show grant role yydp;
Query: show grant role yydp
+----------+-----------+-------+--------+-----+-----------+--------------+-------------------------------+
| scope | database | table | column | uri | privilege | grant_option | create_time |
+----------+-----------+-------+--------+-----+-----------+--------------+-------------------------------+
| database | yydp_kudu | | | | all | false | Sat, Oct 12 2019 15:45:19.073 |
+----------+-----------+-------+--------+-----+-----------+--------------+-------------------------------+
Fetched 1 row(s) in 0.02s
[bigdata5:21000] yydp_kudu>

Cannot create kudu table:
[bigdata5:21000] yydp_kudu> CREATE TABLE test_kd4 (
> id INT,
> bk_date STRING,
> PRIMARY KEY (id)
> ) STORED AS kudu TBLPROPERTIES (
> 'kudu.master_addresses' = 'bigdata1,bigdata2'
> );
Query: CREATE TABLE test_kd4 (
id INT,
bk_date STRING,
PRIMARY KEY (id)
) STORED AS kudu TBLPROPERTIES (
'kudu.master_addresses' = 'bigdata1,bigdata2'
)
ERROR: AuthorizationException: User 'yydp/bigdata5@TEST.COM' does not have privileges to access: server1


Ability to create non-kudu tables properly

[bigdata5:21000] yydp_kudu> CREATE TABLE test_kd5 (
> id INT,
> bk_date STRING);
Query: CREATE TABLE test_kd5 (
id INT,
bk_date STRING)
+-------------------------+
| summary |
+-------------------------+
| Table has been created. |
+-------------------------+
Fetched 1 row(s) in 0.11s

1 REPLY 1

avatar
Rising Star

As you specified the 'kudu.master_addresse' property in the CREATE TABLE statements, Impala requires ALL privileges on SERVER. That error message also indicated that:

ERROR: AuthorizationException: User 'yydp/bigdata5@TEST.COM' does not have privileges to access: server1. So you may want to either remove that clause (and set the Kudu master address via-kudu_master_hosts flag), or grant ALL on SERVER to that user.