Prepstellar

DP-750 · Compute and Catalog Foundations

24 cards

Unity Catalog Hierarchy and Volumes

Swipe, scroll or use ← →
  1. Three levels, three jobs

    Every data asset in Unity Catalog lives inside a three-level namespace: catalog.schema.object. Only three levels exist, so each one has to earn its place, and putting a boundary at the wrong level is the mistake that is expensive to undo.

    A catalog is the top-level container and the primary unit of data isolation and organization. Catalogs usually represent a business domain, a security boundary, or a lifecycle environment such as development, testing, or production.

    What makes the catalog the strongest boundary is what it can own:

    A catalog can have Effect
    Its own managed storage location Its data files sit physically apart from other catalogs
    Its own access policies Permissions are granted at the widest sensible level
    Its own workspace bindings Only the chosen workspaces can reach it
    1 / 24
  2. Three levels, three jobs

    Creating a catalog requires metastore administrator authority or the CREATE CATALOG privilege, which keeps the top of the hierarchy under deliberate control.

    A new catalog is never empty. It arrives with two schemas created automatically: default, for general use, and information_schema, which holds metadata about the objects inside.

    Workspace bindings deserve attention on production catalogs. By default a new catalog is reachable from every workspace attached to the metastore; restricting the bindings to production workspaces is what stops a development environment from querying or modifying production data by accident.

    2 / 24
  3. Quick check

    Which object is the top-level container of the Unity Catalog namespace and its primary unit of isolation?

    1. AA schema, which groups related objects

      A schema is the second level and organizes objects inside a container that already exists.

    2. BA volume, which holds governed files

      A volume is a third-level object for files; it sits below both of the other levels.

    3. CA catalog, which can own storage, access policies and workspace bindings

      Right. The catalog is the highest level, and those three properties are what make it the strongest isolation boundary.

    3 / 24

  4. Schemas organize the interior

    A schema is the second level of the namespace, inside a catalog. It groups related tables, views, volumes, and functions so that hundreds of objects do not sit in one undifferentiated space.

    Schemas are usually organized in one of three ways:

    Organization Example schemas Fits
    By department marketing_analytics, financial_data Business units that own their own data
    By project customer_churn_model, pricing_optimization Initiatives that start, finish, and can be retired
    By processing stage raw_data, cleansed_data, reporting_views Pipelines where each stage is a distinct group

    One vocabulary note: in Databricks SQL, CREATE DATABASE is an alias for CREATE SCHEMA, so "database" and "schema" refer to the same second-level container.

    4 / 24
  5. Quick check

    Which object is the second level of the namespace, grouping related tables, views, volumes and functions?

    1. AA schema

      Right. It sits inside a catalog and gives related objects a shared namespace.

    2. BA workspace binding

      A binding controls which workspaces can reach a catalog; it holds no objects.

    3. CA metastore region

      A region is where a metastore exists; it is not a level of the namespace.

    5 / 24

  6. Privileges that build the hierarchy

    Creating something inside Unity Catalog always needs two kinds of privilege: permission to use the container you are working in, and permission to create that kind of object there.

    To do this You need
    Create a catalog Metastore administrator authority, or CREATE CATALOG
    Create a schema USE CATALOG and CREATE SCHEMA on the parent catalog
    See a schema and query its contents USE SCHEMA, plus the privilege the object itself requires
    Configure managed storage at either level CREATE MANAGED STORAGE on a governed external location

    Read the schema row carefully, because it is the shape of every other row: a schema is created inside a catalog, so the creator must be able to use that catalog and to create schemas in it. Privileges over files, over compute, or over a different level of the hierarchy do not substitute for either half.

    6 / 24
  7. Quick check

    Which pair of privileges on the parent catalog is required to create a schema in it?

    1. ACREATE CATALOG together with the ability to restart the compute resource

      Creating a catalog is a different operation, and compute permissions have no role in the namespace.

    2. BUSE SCHEMA and CREATE VOLUME

      Those privileges concern an existing schema and the files within it, not the creation of the schema itself.

    3. CUSE CATALOG and CREATE SCHEMA

      Right. The creator must be able to use the parent catalog and to create schemas inside it.

    7 / 24

  8. Keep your progress in the app

    That’s 3 of 10 quick checks. In the app they stay answered, and every lesson remembers where you left off.

  9. Where managed data actually lands

    Managed storage defines where Unity Catalog puts the data files of managed tables and volumes. It can be configured at the catalog level, at the schema level, or neither, and the resolution order is what matters in practice.

    Situation Managed objects are stored
    The schema has its own managed location At the schema location, which overrides the catalog's
    The schema has none, the catalog has one At the catalog location
    Neither has one At the metastore's default storage

    Configuring managed storage at either level requires an external location already governed by Unity Catalog and the CREATE MANAGED STORAGE privilege on it.

    8 / 24
  10. Where managed data actually lands

    The override exists for a reason: it lets one schema keep its files in a separate storage account while the rest of the catalog stays where it is. Financial data that must live in a particular account, inside a catalog whose other schemas do not, is exactly the case it answers.

    Without a schema-level location nothing breaks; the schema simply inherits, which keeps administration simpler when physical separation is not required.

    The same reasoning scales up to the catalog. A production catalog that needs dedicated storage and access from production workspaces only is created with a managed storage location and restricted workspace bindings — the schemas inside then inherit that storage unless one of them overrides it. A single volume, a file-name prefix, or a schema without a parent catalog cannot express any of that: only the catalog carries storage, policy, and bindings at the top level.

    9 / 24
  11. Quick check

    A schema has its own managed storage location while its parent catalog also has one. Where are the schema's managed objects stored?

    1. AAt the catalog's location, since the catalog always takes precedence

      The catalog's location is the fallback used only when the schema has none of its own.

    2. BAt the schema's managed location, which overrides the catalog's

      Right. A schema-level location overrides the catalog's for the managed objects in that schema.

    3. CIn the workspace file system, outside Unity Catalog governance

      Managed objects always land in governed storage; the workspace file system is not part of this resolution.

    10 / 24

  12. Design a catalog for production isolation

    Put the previous pieces together on one requirement: production needs dedicated storage, only production workspaces should reach it, and managed objects in its schemas should inherit that storage unless a schema overrides it.

    The design that satisfies all three is a catalog created with a managed storage location and with its workspace bindings restricted. Storage, access policy, and workspace reach are all catalog-level properties, and schema-level overrides remain available for the exceptions.

    The alternatives fail on structure rather than on detail:

    • A single volume with a read grant governs files, not a storage boundary for tables and schemas.
    • A schema cannot exist without a parent catalog, and it has no workspace bindings of its own.
    • A file-name prefix inside a catalog open to every workspace communicates a boundary while enforcing nothing.
    11 / 24
  13. Quick check

    A production catalog needs dedicated storage, must be reachable only from production workspaces, and its schemas should inherit that storage unless one overrides it. What fits?

    1. ACreate the catalog with managed storage and restrict its workspace bindings

      Right. Managed storage, access policy and workspace bindings are catalog-level properties, and schema overrides still work underneath.

    2. BCreate one volume and treat its read grant as the boundary

      A volume governs files inside a schema; it cannot define where managed tables are stored or which workspaces may connect.

    3. CAdopt a file-name prefix and leave the catalog open to all workspaces

      A prefix is a label, and an unrestricted catalog remains reachable from development workspaces.

    12 / 24

  14. Volumes govern files

    Tables govern structured data. Volumes govern everything else: a volume is the Unity Catalog object for files in cloud object storage, of any format — CSV, JSON, Parquet, images, audio, machine learning artifacts.

    A volume sits at the third level of the namespace, catalog.schema.volume, which means files receive the same governance model as tables instead of a parallel one built out of storage credentials.

    That is worth contrasting with the machinery that only looks similar. A SQL warehouse, an instance pool, or a compute policy configures or supplies compute; none of them governs a file. The volume is the object that gives a file an identity inside the catalog hierarchy.

    13 / 24
  15. Quick check

    Which Unity Catalog object governs nontabular files and takes an identity of the form `catalog.schema.object`?

    1. AA compute policy applied to the cluster that reads the files

      A policy constrains how compute is configured; it governs no data at all.

    2. BA volume

      Right. A volume is the third-level object for governed files in cloud object storage.

    3. CAn instance pool that holds the machines processing those files

      A pool supplies virtual machines to clusters and has no place in the namespace.

    14 / 24

  16. The path follows the namespace

    Files in a volume are reached through one path format, and it mirrors the namespace exactly:

    /Volumes/<catalog>/<schema>/<volume>/<path>/<filename>
    

    So a file called orders.csv, in a volume named landing, inside the schema bronze of the catalog sales, is /Volumes/sales/bronze/landing/orders.csv. The order never changes: catalog, then schema, then volume, then the path inside it.

    This works across Spark, pandas, SQL, and file utilities without cloud storage credentials or connection strings in the code. Nothing else is a valid prefix — paths do not start with the words for schemas or catalogs — and reordering the three names points at a volume that does not exist.

    15 / 24
  17. Quick check

    Which path correctly addresses `orders.csv` in the volume `landing`, in schema `bronze` of catalog `sales`?

    1. A`/Catalogs/sales/landing/bronze/orders.csv`, using a catalogs prefix

      Volume paths begin with the volumes prefix, and this one also scrambles the order of the names.

    2. B`/Volumes/landing/sales/bronze/orders.csv`, naming the volume first

      The prefix is right but the names are out of order: the volume cannot come before its own catalog and schema.

    3. C`/Volumes/sales/bronze/landing/orders.csv`

      Right. Catalog, then schema, then volume, then the file path inside the volume.

    16 / 24

  18. Managed or external volume

    Both kinds of volume are accessed the same way and permitted the same way. What differs is who owns the storage lifecycle, and it shows up when the volume is dropped.

    Managed volume External volume
    Storage location The managed storage associated with its schema An existing cloud path you specify
    Lifecycle Managed by Unity Catalog Managed outside Unity Catalog
    When dropped Files are marked for deletion after a seven-day retention period The registration is removed and the files remain in cloud storage

    Choose a managed volume when the work happens inside Azure Databricks and simple, platform-controlled storage is what you want.

    17 / 24
  19. Managed or external volume

    Choose an external volume when another system must keep using the same location: a legacy application writing files, or models consumed by an external service. The volume adds Unity Catalog governance on top of storage that already exists, without taking over its lifecycle.

    That combination answers a specific and common requirement — a legacy application and Azure Databricks share model files at an existing path, governance must be added, and dropping the Unity Catalog object must not delete the files. An external volume over that path satisfies every part of it.

    A managed volume would move the files into schema storage and put their deletion under Unity Catalog's control, which is precisely what the requirement forbids.

    18 / 24
  20. Quick check

    A legacy application and Azure Databricks must keep using the same model files at an existing cloud path. Governance is required, and dropping the Unity Catalog object must not delete the files. What should be created?

    1. AA managed volume created in the schema's managed storage location

      Dropping a managed volume marks its files for deletion after the retention period, which the requirement rules out.

    2. BAn external volume over the existing cloud storage path

      Right. It registers the existing location under Unity Catalog governance, and dropping it removes only that registration.

    3. CA catalog with managed storage and no volume at all

      A catalog is a container for schemas and their objects; by itself it governs no files at an existing path.

    19 / 24

  21. Volume privileges apply to the whole volume

    Working with a volume needs privileges at every level above it, plus the right privilege on the volume itself.

    Privilege Allows
    CREATE VOLUME Creating a volume in a schema (with USE on the parent schema and catalog)
    CREATE EXTERNAL VOLUME Creating an external volume on a governed external location
    READ VOLUME Listing and reading the files in the volume
    WRITE VOLUME Creating, updating, and deleting files

    Grants also cascade: read access given at the catalog level reaches the volumes inside it, which makes broad policies easy and specific restrictions deliberate.

    20 / 24
  22. Volume privileges apply to the whole volume

    One limitation shapes the whole design: volumes do not support folder-level or subdirectory-level access control. A grant applies to the entire volume, so there is no way to open one directory to a group and close the next one.

    The consequence is a rule worth internalizing: when two sets of files need different readers, create two volumes. Each volume becomes its own security boundary while both keep the standard governed path.

    Attempts to work around it do not hold. Granting read on selected folders is not supported; using file names or their capitalization as a boundary enforces nothing; and a write privilege is not a substitute for read access, nor is an external location a place to attach per-group reader permissions for volume files.

    21 / 24
  23. Quick check

    Two file groups share a schema but need different readers, and both need governed `/Volumes` paths. What meets the requirement?

    1. AOne volume, with read access granted on the folders each group needs

      Folder-level access control does not exist for volumes: a grant covers the whole volume.

    2. BTwo volumes, each with its own read grant

      Right. Separate volumes create the two security boundaries while keeping the standard governed paths.

    3. COne volume, using file-name conventions to separate the groups

      File names describe content and enforce nothing; the whole volume would still be readable by both groups.

    22 / 24

  24. Key takeaways

    • The namespace is catalog.schema.object: the catalog is the top-level isolation boundary with its own storage, access policies, and workspace bindings, and it arrives with default and information_schema.
    • A schema is the second level and groups tables, views, volumes, and functions; creating one requires USE CATALOG and CREATE SCHEMA, and CREATE DATABASE is an alias for CREATE SCHEMA.
    • Managed storage can sit at catalog or schema level: the schema location overrides the catalog's, and without either, managed objects fall back to the metastore default.
    • A volume governs files at catalog.schema.volume, reached through /Volumes/<catalog>/<schema>/<volume>/<path>/<filename>; managed volumes hand their lifecycle to Unity Catalog, while dropping an external volume leaves the files in place.
    • READ VOLUME reads and lists, WRITE VOLUME modifies, and because permissions cover the whole volume, different access requirements mean separate volumes.
    23 / 24
  25. Quick check

    Which statement matches each level with what it actually decides?

    1. AA schema owns the workspace bindings, a catalog groups the tables, and a volume supplies compute for file work

      Bindings belong to the catalog, the schema is what groups tables, and no namespace object supplies compute.

    2. BA volume defines the catalog's managed storage, a schema is the top-level boundary, and folder grants refine volume access

      A volume holds files rather than defining catalog storage, the catalog is the top level, and folder-level grants do not exist.

    3. CA catalog is the top-level isolation boundary, a schema groups related objects inside it, and a volume governs files in cloud object storage

      Right. Each level does one job: isolate, organize, and govern files.

    24 / 24

  26. 10 quick checks · then the test

    In the app, finishing the quick checks opens this lesson’s 10-question test, and the ones you miss come back exactly when you’re about to forget them.

The whole course, on your phone

Lessons you can read, audio you can listen to on the way to work, and practice that remembers what you got wrong.