It appears that neither "hive" nor "root" are in the admin group by default. Here is what I tried:
su - hive
beeline> !connect jdbc:...
Enter username for jdbc:...: hive
> set role admin;
Error: Error while processing statement: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. hive doesn't belong to role admin (state=08S01,code=1)
I have tried the same as user "root", but also got "root doesn't belong to role admin".
It looks like I was missing Configuring SQL Standard-Based Authorization.
View solution in original post