Workspace object access control

Note

Access control is available only in the Premium plan (or, for customers who subscribed to Databricks before March 3, 2020, the Operational Security package).

By default, all users can create and modify workspace objects—including folders, notebooks, experiments, and models—unless an administrator enables workspace access control. With workspace object access control, individual permissions determine a user’s abilities. This article describes the individual permissions and how to configure workspace object access control.

Before you can use workspace object access access control, a Databricks admin must enable it for the workspace. See Enable workspace object access control.

Folder permissions

You can assign five permission levels to folders: No Permissions, Read, Run, Edit, and Manage. The table lists the abilities for each permission.

Ability No Permissions Read Run Edit Manage
List items in folder x x x x x
View items in folder   x x x x
Clone and export items   x x x x
Create, import, and delete items         x
Move and rename items         x
Change permissions         x

Notebooks and experiments in a folder inherit all permissions settings of that folder. For example, a user that has Run permission on a folder has Run permission on the notebooks in that folder.

Default folder permissions

  • Independent of workspace object access control, the following permissions exist:
    • All users have Manage permission for items in the Workspace > Shared Icon Shared folder. You can grant Manage permission to notebooks and folders by moving them to the Shared Icon Shared folder.
    • All users have Manage permission for objects the user creates.
  • With workspace object access control disabled, the following permissions exist:
    • All users have Edit permission for items in the Workspace folder.
  • With workspace object access control enabled, the following permissions exist:
    • Workspace folder
      • Only administrators can create new items in the Workspace folder.
      • Existing items in the Workspace folder - Manage. For example, if the Workspace folder contained the Folder Documents and Folder Temp folders, all users continue to have the Manage permission for these folders.
      • New items in the Workspace folder - No Permissions.
    • A user has the same permission for all items in a folder, including items created or moved into the folder after you set the permissions, as the permission the user has on the folder.
    • User home directory - The user has Manage permission. All other users have No Permissions permission.

Notebook permissions

You can assign five permission levels to notebooks: No Permissions, Read, Run, Edit, and Manage. The table lists the abilities for each permission.

Ability No Permissions Read Run Edit Manage
View cells   x x x x
Comment   x x x x
Run via %run or notebook workflows   x x x x
Attach and detach notebooks     x x x
Run commands     x x x
Edit cells       x x
Change permissions         x

Configure notebook and folder permissions

Note

This section describes how to manage permissions using the UI. You can also use the Permissions API.

  1. Open the permissions dialog:

    • Notebook - click Permissions in the notebook context bar.
    • Folder - select Permissions in the folder’s drop-down menu:
    Permissions Drop Down
  2. To grant permissions to a user or group, select from the Add Users and Groups drop-down, select the permission, and click Add:

    Add Users

    To change the permissions of a user or group, select the new permission from the permission drop-down:

    Change Permissions
  3. Click Save Changes to save your changes or click Cancel to discard your changes.

MLflow Experiment permissions

You can assign four permission levels to MLflow Experiments: No Permissions, Read, Edit, and Manage. The table lists the abilities for each permission.

Ability No Permissions Read Edit Manage
View run info, search, compare runs   x x x
View, list, and download run artifacts   x x x
Create, delete, and restore runs     x x
Log run params, metrics, tags     x x
Log run artifacts     x x
Edit experiment tags     x x
Purge runs and experiments       x
Grant permissions       x

Note

  • Experiment permissions are only enforced on artifacts stored in DBFS locations managed by MLflow. For more information, see MLflow Artifact permissions.
  • Create, delete, and restore experiment requires Edit or Manage access to the folder containing the experiment.
  • You can specify the Run permission for experiments. It is enforced the same way as Edit.

Configure MLflow experiment permissions

  1. Open the permissions dialog. Click Permissions in the notebook context bar.

    Permissions Drop Down
  2. Grant permissions. All users in your account belong to the group all users. Administrators belong to the group admins, which has Manage permissions on all items.

    To grant permissions to a user or group, select from the Add Users and Groups drop-down, select the permission, and click Add:

    Add Users

    To change the permissions of a user or group, select the new permission from the permission drop-down:

    Change Permissions
  3. Click Save Changes to save your changes or click Cancel to discard your changes.

MLflow Artifact permissions

Each MLflow Experiment has an Artifact Location that is used to store artifacts logged to MLflow runs. Starting in MLflow 1.11, artifacts are stored in an MLflow-managed subdirectory of the Databricks File System (DBFS) by default. MLflow experiment permissions apply to artifacts stored in these managed locations, which have the prefix dbfs:/databricks/mlflow-tracking. To download or log an artifact, you must have the appropriate level of access to its associated MLflow experiment.

Note

  • Artifacts stored in MLflow-managed locations can only be accessed using the MLflow Client (version 1.9.1 or later), which is available for Python, Java, and R. Other access mechanisms, such as dbutils and the DBFS API, are not supported for MLflow-managed locations.
  • You can also specify your own artifact location when creating an MLflow experiment. Experiment access controls are not enforced on artifacts stored outside of the default MLflow-managed DBFS directory.

MLflow Model permissions

You can assign six permission levels to MLflow Models registered in the MLflow Model Registry: No Permissions, Read, Edit, Manage Staging Versions, Manage Production Versions, and Manage. The table lists the abilities for each permission.

Note

A model version inherits permissions from its parent model; you cannot set permissions for model versions.

Ability No Permissions Read Edit Manage Staging Versions Manage Production Versions Manage
Create a model x x x x x x
View model details, versions, stage transition requests, activities, and artifact download URIs   x x x x x
Request a model version stage transition   x x x x x
Add a version to a model     x x x x
Update model and version description     x x x x
Transition model version between stages       x (between None, Archived, and Staging) x x
Approve or reject a model version stage transition request       x (between None, Archived, and Staging) x x
Cancel a model version stage transition request (see Note)           x
Modify permissions           x
Rename model           x
Delete model and model versions           x

Note

The creator of a stage transition request can also cancel the request.

Default MLflow Model permissions

  • Independent of workspace object access control, the following permissions exist:
    • All users have permission to create a new registered model.
    • All administrators have Manage permission for all models.
  • With workspace object access control disabled, the following permissions exist:
    • All users have Manage permission for all models.
  • With workspace object access control enabled, the following default permissions exist:
    • All users have Manage permission for models the user creates.
    • Non-administrator users have No Permissions on models they did not create.

Configure MLflow Model permissions

All users in your account belong to the group all users. Administrators belong to the group admins, which has Manage permissions on all objects.

Note

This section describes how to manage permissions using the UI. You can also use the Permissions API.

  1. Click the Models Icon icon in the sidebar.

  2. Click a model name.

  3. Click Button Down at the right of the model name and select Permissions.

    Permissions Drop Down
  4. Click the Select User or Group drop-down and delect a user or group.

    Add Users
  5. Select a permission. To change the permissions of a user or group, select the new permission from the permission drop-down:

    Change Permissions
  6. Click Add.

  7. Click Save to save your changes or Cancel to discard your changes.

MLflow Model Artifact permissions

The model files for each MLflow model version are stored in an MLflow-managed location, with the prefix dbfs:/databricks/model-registry/.

To get the exact location of the files for a model version, you must have Read access to the model. Use the REST API endpoint /api/2.0/mlflow/model-versions/get-download-uri. After obtaining the URI, you can use the DBFS API to download the files.

The MLflow Client (for Python, Java, and R) provides several convenience methods that wrap this workflow to download and load the model, such as mlflow.<flavor>.load_model().

Note

Other access mechanisms, such as dbutils and %fs are not supported for MLflow-managed file locations.

Library and jobs access control

Library All users can view libraries. To control who can attach libraries to clusters, see Cluster access control.

Jobs To control who can run jobs and see the results of job runs, see Jobs access control.