Access modes & compute policies

Databricks · Compute

Theory

Access mode decides who can use a cluster and how Unity Catalog security is enforced. Standard access mode (formerly Shared) lets many users share one cluster with full user isolation; it supports Python, SQL and Scala and is the recommended mode for most work. Dedicated access mode (formerly Single user) assigns the cluster to one user or one group, which you need for things like R, RDD APIs, GPUs or some ML libraries. The default Auto setting picks a mode for you; Legacy modes such as No isolation shared are not recommended and do not support Unity Catalog.

Compute policies are admin-defined rule sets that limit what users can create: allowed runtimes and node types, maximum workers, required tags, forced auto-termination. Users pick a policy in the Policy drop-down and the form only shows allowed values. For example, the sales team's policy forces team=sales, Max 4 workers and 60-minute auto-termination.

Why we use it

Without access modes, users on a shared cluster could see each other's data; without policies, anyone could start a huge cluster and forget it. Together they give secure sharing and cost control.

When to use it

Use Standard access mode for shared team clusters and most notebooks. Use Dedicated when a single user or group needs features Standard does not allow. Use policies whenever non-admins create compute; serverless needs neither setting.

How it works

  1. User creates compute
  2. Picks a compute policy in the Policy drop-down
  3. Form shows only values the policy allows
  4. Does one user or group need R, RDDs, GPUs or ML-only features? Yes: Access mode: Dedicated. No: Access mode: Standard.
  5. Cluster enforces Unity Catalog permissions per user

Syntax

Create compute → Advanced → Access mode: Auto | Manual → Standard | Dedicated
Compute → Policies → Create policy
Policy JSON: {"autotermination_minutes": {"type": "fixed", "value": 60}}

Example

{
  "autotermination_minutes": {"type": "fixed", "value": 60, "hidden": true},
  "autoscale.max_workers":   {"type": "range", "maxValue": 4},
  "custom_tags.team":        {"type": "fixed", "value": "sales"},
  "data_security_mode":      {"type": "fixed", "value": "USER_ISOLATION"},
  "spark_version":           {"type": "unlimited", "defaultValue": "auto:latest-lts"}
}

Key points

Databricks topics

Databricks Fundamentals

Compute

Notebooks & Development

Apache Spark on Databricks

Delta Lake

Unity Catalog & Governance

Data Ingestion

Declarative Pipelines (Lakeflow)

Lakeflow Jobs

Databricks SQL & BI

Architecture, Performance & Cost

Machine Learning & AI

Certification & Interview

T
Tech Town
Log InSign Up Free
Home SQL Python DSA Power BI Snowflake Databricks Spark Gen AI Practice Problems Contest Blog

Master Databricks

The lakehouse platform from the ground up: Apache Spark, Delta Lake, Unity Catalog, Lakeflow pipelines and jobs, Databricks SQL and MLflow. Click any topic in the sidebar to open it right here.

{{ sectionCount }}
Sections
{{ topicCount }}
Topics
Free
Forever
Hands-on practice Practice SQL / Spark SQL Sharpen the SQL you use in Databricks SQL and Spark SQL: 150 query problems in a live editor with instant checking. Start practising →
Section {{ sec.num }}

{{ sec.label }}

Databricks  /  {{ current.sectionLabel }}  /  {{ current.name }}

{{ current.name }}

Theory

{{ current.def }}

Why we use it

{{ rich.why }}

When to use it

{{ rich.when }}

{{ sec.h }}

{{ sec.body }}

{{ sec.body }}

Diagram

{{ rich.dg.caption }}

{{ tb.title }}
{{ c.v }}
{{ rich.dg.op }}
➜
{{ rich.dg.output.title }}
{{ c.v }}
{{ nd.label }}
{{ nd.sub }}
{{ nd.label }}
{{ nd.sub }}
{{ rich.dg.left.title }}
{{ it }}
{{ rich.dg.right.title }}
{{ it }}
On screen — where to click

{{ rich.ui.title }}

{{ u.text }}
  1. {{ st.n }}{{ st.text }}
{{ rich.ui.title }}
{{ u.text }}
Flowchart — how it works
{{ nd.text }}
{{ nd.text }}
◇ {{ nd.text }}
Yes → {{ nd.yes }}
No → {{ nd.no }}
Syntax
{{ current.syntax }}
Example
{{ current.example }}
Want to run this yourself? Databricks needs a real workspace — there's no in-browser engine for it. Click Copy above, then paste it into a notebook or the SQL editor in Databricks Free Edition (free, no credit card) and run it on serverless compute.
Key Points — click to check off as you learn
  • {{ pt.mark }} {{ pt.text }}

Share this topic