<?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>topic Hive Metastore permission on DBX 10.4 in Get Started Discussions</title>
    <link>https://community.databricks.com/t5/get-started-discussions/hive-metastore-permission-on-dbx-10-4/m-p/44680#M5811</link>
    <description>&lt;P&gt;I've been working on creating a schema in the Hive Metastore using the following command:&lt;/P&gt;&lt;PRE&gt;spark.sql(f'CREATE DATABASE IF NOT EXISTS {database}')&lt;/PRE&gt;&lt;P&gt;The schema or database is successfully created, but I encountered an issue where it's only accessible for me and not for other users. To address this, I attempted to grant select permissions on the schema using the command:&lt;/P&gt;&lt;PRE&gt;spark.sql(f'GRANT SELECT ON SCHEMA hive_metastore.{database} TO `{user}`')&lt;/PRE&gt;&lt;P&gt;However, I received the following error:&lt;/P&gt;&lt;PRE&gt;org.apache.spark.SparkException: Trying to perform a permission action on Hive Metastore /CATALOG/`hive_metastore`/DATABASE/`testing_permissions_acls`, &lt;BR /&gt;but Table Access Control is not enabled on this cluster.&lt;/PRE&gt;&lt;P&gt;To resolve this, I added the following configuration setting to SparkConf:&lt;/P&gt;&lt;PRE&gt;spark.databricks.acl.sqlOnly true&lt;/PRE&gt;&lt;P&gt;After making this change, I was able to see the schema's permissions tab through the GUI. However, I encountered a new error:&lt;/P&gt;&lt;PRE&gt;Your administrator has only allowed SQL commands on this cluster. &lt;BR /&gt;This execution contained at least one disallowed language.&lt;/PRE&gt;&lt;P&gt;Here is an overview of my cluster configuration:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Cluster Configuration:&lt;/STRONG&gt;&lt;BR /&gt;-&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Databricks Runtime:&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;10.4 LTS ML (includes Apache Spark 3.2.1, Scala 2.12)&lt;BR /&gt;-&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Access Mode:&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Custom&lt;BR /&gt;-&amp;nbsp;&lt;SPAN class=""&gt;&lt;STRONG&gt;IAM role passthrough&lt;/STRONG&gt;: Disabled (Cant tick the box)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Unity Catalog:&amp;nbsp;&lt;/STRONG&gt;Not Enabled&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Spark Configuration:&lt;/STRONG&gt;&lt;BR /&gt;- `spark.driver.extraJavaOptions`: "-Dlog4j2.formatMsgNoLookups=true"&lt;BR /&gt;- `spark.databricks.io.cache.maxMetaDataCache`: 1g&lt;BR /&gt;- `spark.databricks.io.cache.compression.enabled`: false&lt;BR /&gt;- `spark.hadoop.fs.s3a.acl.default`: BucketOwnerFullControl&lt;BR /&gt;- `spark.databricks.libraryIsolation.enabled`: true&lt;BR /&gt;- `spark.databricks.unityCatalog.userIsolation.python.preview`: true&lt;BR /&gt;- `spark.hadoop.fs.s3a.canned.acl`: BucketOwnerFullControl&lt;BR /&gt;- `spark.databricks.io.cache.maxDiskUsage`: 50g&lt;BR /&gt;- `spark.databricks.acl.sqlOnly`: true&lt;BR /&gt;- `spark.sql.execution.arrow.enabled`: true&lt;BR /&gt;- `spark.executor.extraJavaOptions`: "-Dlog4j2.formatMsgNoLookups=true"&lt;/P&gt;&lt;P&gt;Has anyone encountered a similar issue before or have suggestions on how to resolve it?&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;BR /&gt;Adriana Cavalcanti&lt;/P&gt;</description>
    <pubDate>Wed, 13 Sep 2023 23:39:21 GMT</pubDate>
    <dc:creator>drii_cavalcanti</dc:creator>
    <dc:date>2023-09-13T23:39:21Z</dc:date>
    <item>
      <title>Hive Metastore permission on DBX 10.4</title>
      <link>https://community.databricks.com/t5/get-started-discussions/hive-metastore-permission-on-dbx-10-4/m-p/44680#M5811</link>
      <description>&lt;P&gt;I've been working on creating a schema in the Hive Metastore using the following command:&lt;/P&gt;&lt;PRE&gt;spark.sql(f'CREATE DATABASE IF NOT EXISTS {database}')&lt;/PRE&gt;&lt;P&gt;The schema or database is successfully created, but I encountered an issue where it's only accessible for me and not for other users. To address this, I attempted to grant select permissions on the schema using the command:&lt;/P&gt;&lt;PRE&gt;spark.sql(f'GRANT SELECT ON SCHEMA hive_metastore.{database} TO `{user}`')&lt;/PRE&gt;&lt;P&gt;However, I received the following error:&lt;/P&gt;&lt;PRE&gt;org.apache.spark.SparkException: Trying to perform a permission action on Hive Metastore /CATALOG/`hive_metastore`/DATABASE/`testing_permissions_acls`, &lt;BR /&gt;but Table Access Control is not enabled on this cluster.&lt;/PRE&gt;&lt;P&gt;To resolve this, I added the following configuration setting to SparkConf:&lt;/P&gt;&lt;PRE&gt;spark.databricks.acl.sqlOnly true&lt;/PRE&gt;&lt;P&gt;After making this change, I was able to see the schema's permissions tab through the GUI. However, I encountered a new error:&lt;/P&gt;&lt;PRE&gt;Your administrator has only allowed SQL commands on this cluster. &lt;BR /&gt;This execution contained at least one disallowed language.&lt;/PRE&gt;&lt;P&gt;Here is an overview of my cluster configuration:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Cluster Configuration:&lt;/STRONG&gt;&lt;BR /&gt;-&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Databricks Runtime:&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;10.4 LTS ML (includes Apache Spark 3.2.1, Scala 2.12)&lt;BR /&gt;-&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Access Mode:&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Custom&lt;BR /&gt;-&amp;nbsp;&lt;SPAN class=""&gt;&lt;STRONG&gt;IAM role passthrough&lt;/STRONG&gt;: Disabled (Cant tick the box)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Unity Catalog:&amp;nbsp;&lt;/STRONG&gt;Not Enabled&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Spark Configuration:&lt;/STRONG&gt;&lt;BR /&gt;- `spark.driver.extraJavaOptions`: "-Dlog4j2.formatMsgNoLookups=true"&lt;BR /&gt;- `spark.databricks.io.cache.maxMetaDataCache`: 1g&lt;BR /&gt;- `spark.databricks.io.cache.compression.enabled`: false&lt;BR /&gt;- `spark.hadoop.fs.s3a.acl.default`: BucketOwnerFullControl&lt;BR /&gt;- `spark.databricks.libraryIsolation.enabled`: true&lt;BR /&gt;- `spark.databricks.unityCatalog.userIsolation.python.preview`: true&lt;BR /&gt;- `spark.hadoop.fs.s3a.canned.acl`: BucketOwnerFullControl&lt;BR /&gt;- `spark.databricks.io.cache.maxDiskUsage`: 50g&lt;BR /&gt;- `spark.databricks.acl.sqlOnly`: true&lt;BR /&gt;- `spark.sql.execution.arrow.enabled`: true&lt;BR /&gt;- `spark.executor.extraJavaOptions`: "-Dlog4j2.formatMsgNoLookups=true"&lt;/P&gt;&lt;P&gt;Has anyone encountered a similar issue before or have suggestions on how to resolve it?&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;BR /&gt;Adriana Cavalcanti&lt;/P&gt;</description>
      <pubDate>Wed, 13 Sep 2023 23:39:21 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/hive-metastore-permission-on-dbx-10-4/m-p/44680#M5811</guid>
      <dc:creator>drii_cavalcanti</dc:creator>
      <dc:date>2023-09-13T23:39:21Z</dc:date>
    </item>
  </channel>
</rss>

