Thanks. But if I assign a group of the users to /apps/hive/warehouse then they can still create internal tables, which is what I am trying to prevent.
I am on version 0.12.0.2.0.6.0. On Thu, Jan 30, 2014 at 11:55 AM, Peyman Mohajerian <mohaj...@gmail.com>wrote: > This is a known issue, it still will write something at > '/apps/hive/warehouse', > it's best to assign a common group to your hive and hdfs users and assign > that group to both of these directories. I heard this issue is fixed in .12 > or .13, others can confirm. > > > On Thu, Jan 30, 2014 at 8:27 AM, Alex Nastetsky <anastet...@spryinc.com>wrote: > >> Hi, >> >> I am trying to enforce all Hive tables to be created with EXTERNAL. The >> way I am doing this is by making the location of the warehouse >> (/apps/hive/warehouse in my case) to have permissions 000 (completely >> inaccessible). >> >> But then when I try to create an external table, I see that it still >> tries to write to /apps/hive/warehouse and, of course, fails: >> >> hive> CREATE EXTERNAL TABLE mytable(id INT, name STRING) ROW FORMAT >> DELIMITED FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n' STORED AS >> TEXTFILE LOCATION '/user/anastetsky/warehouse'; >> Authorization failed:java.security.AccessControlException: action WRITE >> not permitted on path hdfs://<hostname>:8020/apps/hive/warehouse for user >> anastetsky. Use show grant to get more details. >> >> What am I missing? Or is there a better way to enforce tables to be >> EXTERNAL? >> >> Thanks in advance, >> Alex. >> > >