Hive, Sentry: Problem while granting roles to a group

0 votes

Hi. I am trying to grant a role to a group using the below command:

GRANT ROLE student TO GROUP student-group;

But this is giving an error. It says it cannot grant role because of some syntax error. I have checked the syntax and it is right. I don't understand what the problem is. 

May 31 in Big Data Hadoop by Karan
29 views

1 answer to this question.

0 votes

The group name you are trying to assign the role to is 'student-group'. Sentry allows granting roles to groups whose name is alphanumeric and the only special character allowed is an underscore (_). Because you have a hyphen (-). If there are any special characters apart from an underscore then you have to use backticks (`) as follows:

GRANT ROLE student TO GROUP `student-group`;

P.S.: It would have been better if you had shared the error log. It would have been easy to analyze.

answered May 31 by Jimmy

Related Questions In Big Data Hadoop

0 votes
3 answers

How to connect Spark to a remote Hive server?

JDBC is not required here. Create a hive ...READ MORE

answered Mar 8 in Big Data Hadoop by Vijay Dixon
• 180 points
1,168 views
0 votes
1 answer

Hadoop Hive: How to skip the first line of csv while loading in hive table?

You can try this: CREATE TABLE temp ...READ MORE

answered Nov 8, 2018 in Big Data Hadoop by Omkar
• 67,290 points
708 views
0 votes
1 answer

Hadoop Hive: How to split a single row into multiple rows?

Try this SELECT ID1, Sub FROM tableName lateral view ...READ MORE

answered Nov 14, 2018 in Big Data Hadoop by Omkar
• 67,290 points
807 views
0 votes
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,510 points
2,400 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,510 points
245 views
0 votes
10 answers

hadoop fs -put command?

put syntax: put <localSrc> <dest> copy syntax: copyFr ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Aditya
12,221 views
0 votes
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,240 points
896 views
0 votes
1 answer

Hive: Granting roles to groups

You can use the GRANT ROLE statement ...READ MORE

answered May 31 in Big Data Hadoop by Roshni
22 views
0 votes
1 answer

How to convert a string to timestamp with milliseconds in Hive?

 concatenation of substrings using the following code: select ...READ MORE

answered Oct 31, 2018 in Big Data Hadoop by Neha
• 6,280 points
1,647 views