insert into limifang_oracle_store002(id,name) values(1,'lisi');
exception: Error: Error while compiling statement: FAILED: SemanticException org.apache.hadoop.hive.ql.metadata.InvalidTableException: Table not found limifang_oracle_store002 (state=42000,code=40000) 0: jdbc:hive2://192.168.2.16:2181,192.168.2.1> insert into liminfang_oracle_store002(id,name) values(1,'lisi'); WARNING: Hive-on-MR is deprecated in Hive 2 and may not be available in the future versions. Consider using a different execution engine (i.e. spark, tez) or using Hive 1.X releases. Error: org.apache.hive.service.cli.HiveSQLException: Error while processing statement: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.mr.MapRedTask. Permission denied: user=kaif1, access=EXECUTE, inode="/tmp/hadoop-yarn/staging/kaif1/.staging":root:supergroup:drwx------
Permission information is as follows: show grant role kaif1;
|database| table | partition | column | principal_name | principal_type | privilege | grant_option | grant_time | grantor |
| ziy_db_109 | liminfang_oracle_store002 | kaif1 | ROLE | DELETE | false | 1022296989000
| ziy_db_109 |liminfang_oracle_store002 | kaif1 | ROLE | INSERT | false | 1022295356000 |
Check the Hadoop cluster HDFS in those groups, if there are hadoop, hdfs, supergroup and other groups.
2 add test users to the supergroup group (or Hadoop, HDFS group).
3 Connect hive with hive user (administrator) beeline, create role: test_role, execute command: create role test_role;
4 grant permission to test_role and execute the command: grant all on testdb. testtable to role test_role; (there must be a library testdb, table testtable in his)
5 assign the test_role role to the test user to execute the command :grant test_role to group test;