<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ? in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193446#M155510</link>
    <description>&lt;P&gt;The property you want to change is "hive.metastore.warehouse.dir".&lt;/P&gt;</description>
    <pubDate>Wed, 27 Sep 2017 00:30:08 GMT</pubDate>
    <dc:creator>deepesh1</dc:creator>
    <dc:date>2017-09-27T00:30:08Z</dc:date>
    <item>
      <title>How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193445#M155509</link>
      <description>&lt;P&gt;I added spark.sql.warehouse.dir in the configuration but still spark is not using it. it still points to /apps/hive/warehouse. I even changed the settings in hive-site.xml but I am still having the same issue. I keep getting this exception &lt;/P&gt;&lt;P&gt;org.apache.hadoop.ipc.RemoteException: Permission denied: user=user, access=WRITE, inode="/apps/hive/warehouse/position_parquet_test/_temporary/0":hive:hdfs:drwxr-xr-x&lt;/P&gt;&lt;P&gt;update: &lt;/P&gt;&lt;P&gt;once i start spark shell it shows in the info that the warehouse was set to the right path &lt;/P&gt;&lt;P&gt;17/09/27 13:16:46 INFO HiveClientImpl: Warehouse location for Hive client (version 1.2.1) is /uat/06295/app/XTA0/hivedb&lt;/P&gt;&lt;P&gt;how ever when I try to create a table i get the exception mentioned above &lt;/P&gt;</description>
      <pubDate>Tue, 26 Sep 2017 20:46:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193445#M155509</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-09-26T20:46:46Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193446#M155510</link>
      <description>&lt;P&gt;The property you want to change is "hive.metastore.warehouse.dir".&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 00:30:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193446#M155510</guid>
      <dc:creator>deepesh1</dc:creator>
      <dc:date>2017-09-27T00:30:08Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193447#M155511</link>
      <description>&lt;P&gt;I am using spark 2.1.1 and hive.metastore.warehouse.dir is deprecated on version 2.1.1&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 00:35:01 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193447#M155511</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-09-27T00:35:01Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193448#M155512</link>
      <description>&lt;P&gt;Hi &lt;A rel="user" href="https://community.cloudera.com/users/44256/akremlatiwesh.html" nodeid="44256"&gt;@Akrem Latiwesh&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;Try setting spark.sql.warehouse.dir in spark conf.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aditya&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 01:37:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193448#M155512</guid>
      <dc:creator>asirna</dc:creator>
      <dc:date>2017-09-27T01:37:40Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193449#M155513</link>
      <description>&lt;P&gt;Hi &lt;A rel="user" href="https://community.cloudera.com/users/14200/asirna.html" nodeid="14200"&gt;@Aditya Sirna&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I am including  it in spark conf as the following&lt;/P&gt;&lt;P&gt;spark.sql.warehouse.dir=hdfs:///uat/06295/app/XTA0/hivedb &lt;/P&gt;&lt;P&gt;spark.yarn.security.credentials.hive.enabled=true&lt;/P&gt;&lt;P&gt;But spark it does not use it as hive warehouse &lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Akrem&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 02:00:37 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193449#M155513</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-09-27T02:00:37Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193450#M155514</link>
      <description>&lt;P&gt;Hi &lt;A rel="user" href="https://community.cloudera.com/users/44256/akremlatiwesh.html" nodeid="44256"&gt;@Akrem Latiwesh&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;Can you just try giving "/app/XTA0/hivedb" instead of hdfs:/// . It will pick the defaultFS from hadoop's core-site.xml.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aditya&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 02:14:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193450#M155514</guid>
      <dc:creator>asirna</dc:creator>
      <dc:date>2017-09-27T02:14:14Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193451#M155515</link>
      <description>&lt;P&gt;Thanks &lt;A rel="user" href="https://community.cloudera.com/users/14200/asirna.html" nodeid="14200"&gt;@Aditya Sirna&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I tried that and I am still getting the same exception &lt;/P&gt;&lt;P&gt;Caused by: org.apache.hadoop.ipc.RemoteException: Permission denied: user=USER, access=WRITE, inode="/apps/hive/warehouse/position_parquet_test/_temporary/0":hive:hdfs:drwxr-xr-x&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 03:10:37 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193451#M155515</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-09-27T03:10:37Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193452#M155516</link>
      <description>&lt;P&gt;Have you given that a try, setting hive.metastore.warehouse.dir in hive-site.xml under spark conf.&lt;/P&gt;</description>
      <pubDate>Wed, 27 Sep 2017 04:12:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193452#M155516</guid>
      <dc:creator>deepesh1</dc:creator>
      <dc:date>2017-09-27T04:12:33Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193453#M155517</link>
      <description>&lt;P&gt;yes I did. Please look at the log below&lt;/P&gt;&lt;P&gt;17/09/27 14:30:49 INFO SharedState: spark.sql.warehouse.dir is not set, but hive.metastore.warehouse.dir is set. Setting spark.sql.warehouse.dir to the value of hive.metastore.warehouse.dir ('/uat/06295/app/XTA0/hivedb').
17/09/27 14:30:49 INFO SharedState: Warehouse path is '/uat/06295/app/XTA0/hivedb'.
17/09/27 14:30:49 INFO ContextHandler: Started o.s.j.s.ServletContextHandler@3d3238e4{/SQL,null,AVAILABLE,@Spark}
17/09/27 14:30:49 INFO ContextHandler: Started o.s.j.s.ServletContextHandler@53cfe9e5{/SQL/json,null,AVAILABLE,@Spark}
17/09/27 14:30:49 INFO ContextHandler: Started o.s.j.s.ServletContextHandler@75437b4b{/SQL/execution,null,AVAILABLE,@Spark}
17/09/27 14:30:49 INFO ContextHandler: Started o.s.j.s.ServletContextHandler@7e94c1d5{/SQL/execution/json,null,AVAILABLE,@Spark}
17/09/27 14:30:49 INFO ContextHandler: Started o.s.j.s.ServletContextHandler@51b0451f{/static/sql,null,AVAILABLE,@Spark}
17/09/27 14:30:49 INFO HiveUtils: Initializing HiveMetastoreConnection version 1.2.1 using Spark classes.
17/09/27 14:30:49 INFO HiveClientImpl: Attempting to login to Kerberos using principal: and keytab: 
17/09/27 14:30:49 INFO UserGroupInformation: Login successful for user  using keytab file 
17/09/27 14:30:50 INFO metastore: Trying to connect to metastore with URI 
17/09/27 14:30:50 INFO metastore: Connected to metastore.
17/09/27 14:30:53 WARN DomainSocketFactory: The short-circuit local reads feature cannot be used because libhadoop cannot be loaded.
17/09/27 14:30:53 INFO SessionState: Created local directory: /tmp/369e4278-1d5e-46e6-bc5d-b7143e48c525_resources
17/09/27 14:30:53 INFO SessionState: Created HDFS directory: /tmp/hive/
17/09/27 14:30:53 INFO SessionState: Created local directory: /tmp/
17/09/27 14:30:53 INFO SessionState: Created HDFS directory: /tmp/hive/
17/09/27 14:30:53 INFO HiveClientImpl: Warehouse location for Hive client (version 1.2.1) is /uat/06295/app/XTA0/hivedb
17/09/27 14:30:53 INFO Main: Created Spark session with Hive support&lt;/P&gt;</description>
      <pubDate>Thu, 28 Sep 2017 01:34:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193453#M155517</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-09-28T01:34:40Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193454#M155518</link>
      <description>&lt;P&gt;The issue has been resolved, I was creating a table without specifying in which database i want to create it. So, hive was trying to create the table in the default database to which i do not have permissions to write.  &lt;/P&gt;&lt;P&gt;All what I needed to do is to create a new database and use the command " USE database_name" before i actually create my table. &lt;/P&gt;&lt;P&gt;thanks for the help guys, wasted too much time on configurations while the solution was done by a simple query. &lt;/P&gt;</description>
      <pubDate>Thu, 05 Oct 2017 02:08:01 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/193454#M155518</guid>
      <dc:creator>akrem_latiwesh</dc:creator>
      <dc:date>2017-10-05T02:08:01Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/287699#M213195</link>
      <description>&lt;P&gt;Although this thread is quite old, I post my solution, as it may still be helpful to some people.&lt;BR /&gt;I encountered the problem in spark2-shell, as the hive metastore.uri was not set in client mode,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After adding the following to spark-defaults.conf (via cloudera manger's&lt;/P&gt;&lt;DIV class="display-name"&gt;Spark 2 Client Advanced Configuration Snippet (Safety Valve) for spark2-conf/spark-defaults.conf)&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;spark.sql.warehouse.dir=hdfs://nameservice1/user/hive/warehouse&lt;BR /&gt;spark.executor.extraJavaOptions=-Dhive.metastore.uris=thrift://hive.metastore.net:9083&lt;BR /&gt;spark.driver.extraJavaOptions=-Dhive.metastore.uris=thrift://hive.metastore.net:9083&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;I could list and access all tables from the hive metastore from within spark-shell.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Jan 2020 15:39:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/287699#M213195</guid>
      <dc:creator>mwol</dc:creator>
      <dc:date>2020-01-15T15:39:00Z</dc:date>
    </item>
    <item>
      <title>Re: How can I change  hive warehouse directory from /apps/hive/warehouse/ to another warehouse that i have permission to write to ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/287700#M213196</link>
      <description>&lt;P&gt;... you have to adapt the configuration to your needs, of course, by changing metastore host and warehouse dir, accordingly&lt;/P&gt;</description>
      <pubDate>Wed, 15 Jan 2020 15:40:30 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-can-I-change-hive-warehouse-directory-from-apps-hive/m-p/287700#M213196</guid>
      <dc:creator>mwol</dc:creator>
      <dc:date>2020-01-15T15:40:30Z</dc:date>
    </item>
  </channel>
</rss>

