You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/storage/blobs/data-lake-storage-directory-file-acl-powershell.md
+40-6Lines changed: 40 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ author: normesta
6
6
ms.service: storage
7
7
ms.subservice: data-lake-storage-gen2
8
8
ms.topic: conceptual
9
-
ms.date: 04/02/2020
9
+
ms.date: 04/10/2020
10
10
ms.author: normesta
11
11
ms.reviewer: prishet
12
12
---
@@ -265,16 +265,15 @@ You can use the `-Force` parameter to remove the file without a prompt.
265
265
266
266
## Manage access permissions
267
267
268
-
You can get, set, and update access permissions of file systems, directories and files.
268
+
You can get, set, and update access permissions of file systems, directories and files. These permissions are captured in access control lists (ACLs).
269
269
270
270
> [!NOTE]
271
271
> If you're using Azure Active Directory (Azure AD) to authorize commands, then make sure that your security principal has been assigned the [Storage Blob Data Owner role](https://docs.microsoft.com/azure/role-based-access-control/built-in-roles#storage-blob-data-owner). To learn more about how ACL permissions are applied and the effects of changing them, see [Access control in Azure Data Lake Storage Gen2](https://docs.microsoft.com/azure/storage/blobs/data-lake-storage-access-control).
272
272
273
-
### Get permissions
273
+
### Get an ACL
274
274
275
275
Get the ACL of a directory or file by using the `Get-AzDataLakeGen2Item`cmdlet.
276
276
277
-
278
277
This example gets the ACL of a **file system** and then prints the ACL to the console.
279
278
280
279
```powershell
@@ -306,7 +305,7 @@ The following image shows the output after getting the ACL of a directory.
306
305
307
306
In this example, the owning user has read, write, and execute permissions. The owning group has only read and execute permissions. For more information about access control lists, see [Access control in Azure Data Lake Storage Gen2](data-lake-storage-access-control.md).
308
307
309
-
### Set or update permissions
308
+
### Set an ACL
310
309
311
310
Use the `set-AzDataLakeGen2ItemAclObject` cmdlet to create an ACL for the owning user, owning group, or other users. Then, use the `Update-AzDataLakeGen2Item` cmdlet to commit the ACL.
312
311
@@ -354,7 +353,7 @@ The following image shows the output after setting the ACL of a file.
354
353
In this example, the owning user and owning group have only read and write permissions. All other users have write and execute permissions. For more information about access control lists, see [Access control in Azure Data Lake Storage Gen2](data-lake-storage-access-control.md).
355
354
356
355
357
-
### Set permissions on all items in a file system
356
+
### Set ACLs on all items in a file system
358
357
359
358
You can use the `Get-AzDataLakeGen2Item` and the `-Recurse` parameter together with the `Update-AzDataLakeGen2Item` cmdlet to recursively to set the ACL of all directories and files in a file system.
First, get the ACL. Then, use the `set-AzDataLakeGen2ItemAclObject` cmdlet to add or update an ACL entry. Use the `Update-AzDataLakeGen2Item` cmdlet to commit the ACL.
370
+
371
+
This example creates or updates the ACL on a **directory** for a user.
0 commit comments