Get-AzDataLakeGen2Item

파일 시스템의 파일 또는 디렉터리에 대한 세부 정보를 가져옵니다.

Syntax

Get-AzDataLakeGen2Item
   [-FileSystem] <String>
   [-Path <String>]
   [-Context <IStorageContext>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

Get-AzDataLakeGen2Item cmdlet은 Azure Storage 계정의 Filesystem에 있는 파일 또는 디렉터리의 세부 정보를 가져옵니다. 이 cmdlet은 스토리지 계정에 대해 계층 구조 네임스페이스를 사용하는 경우에만 작동합니다. 이러한 종류의 계정은 "-EnableHierarchicalNamespace $true"가 있는 "New-AzStorageAccount" cmdlet을 실행하여 만들 수 있습니다.

예제

예제 1: 파일 시스템으로부터 디렉터리 가져오기 및 세부 정보 표시

$dir1 = Get-AzDataLakeGen2Item -FileSystem "filesystem1" -Path "dir1/"
$dir1

   FileSystem Name: filesystem1

Path                 IsDirectory  Length          LastModified         Permissions  Owner                Group               
----                 -----------  ------          ------------         -----------  -----                -----               
dir1                 True                         2020-03-23 09:15:56Z rwx---rwx    $superuser           $superuser     
 
PS C:\WINDOWS\system32> $dir1.ACL

DefaultScope AccessControlType EntityId Permissions
------------ ----------------- -------- -----------
False        User                       rwx        
False        Group                      ---        
False        Other                      rwx      

PS C:\WINDOWS\system32> $dir1.Permissions

Owner        : Execute, Write, Read
Group        : None
Other        : Execute, Write, Read
StickyBit    : False
ExtendedAcls : False

PS C:\WINDOWS\system32> $dir1.Properties.Metadata

Key          Value 
---          ----- 
hdi_isfolder true  
tag1         value1
tag2         value2

PS C:\WINDOWS\system32> $dir1.Properties

LastModified          : 3/23/2020 9:15:56 AM +00:00
CreatedOn             : 3/23/2020 9:15:56 AM +00:00
Metadata              : {[hdi_isfolder, true], [tag1, value1], [tag2, value2]}
CopyCompletedOn       : 1/1/0001 12:00:00 AM +00:00
CopyStatusDescription : 
CopyId                : 
CopyProgress          : 
CopySource            : 
CopyStatus            : Pending
IsIncrementalCopy     : False
LeaseDuration         : Infinite
LeaseState            : Available
LeaseStatus           : Unlocked
ContentLength         : 0
ContentType           : application/octet-stream
ETag                  : "0x8D7CF0ACBA35FA8"
ContentHash           : 
ContentEncoding       : UDF12
ContentDisposition    : 
ContentLanguage       : 
CacheControl          : READ
AcceptRanges          : bytes
IsServerEncrypted     : True
EncryptionKeySha256   : 
AccessTier            : Cool
ArchiveStatus         : 
AccessTierChangedOn   : 1/1/0001 12:00:00 AM +00:00

이 명령은 Filesystem에서 디렉터리를 가져오고 세부 정보를 표시합니다.

예제 2: 파일 시스템으로부터 파일 가져오기

Get-AzDataLakeGen2Item -FileSystem "filesystem1" -Path "dir1/file1"

FileSystem Name: filesystem1

Path                 IsDirectory  Length          LastModified         Permissions  Owner                Group               
----                 -----------  ------          ------------         -----------  -----                -----               
dir1/file1           False        1024            2020-03-23 09:20:37Z rwx---rwx    $superuser           $superuser

이 명령은 파일 시스템으로부터 파일의 세부 정보를 가져옵니다.

매개 변수

-Context

Azure Storage 컨텍스트 개체

Type:IStorageContext
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-DefaultProfile

Azure와의 통신에 사용되는 자격 증명, 계정, 테넌트 및 구독입니다.

Type:IAzureContextContainer
Aliases:AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-FileSystem

FileSystem 이름

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Path

검색해야 하는 지정된 파일 시스템의 경로입니다. 'directory/file.txt' 또는 'directory1/directory2/' 형식의 파일 또는 디렉터리일 수 있습니다. Filesystem의 루트 디렉터리를 가져오기 위해 이 매개 변수를 지정하지 마세요.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

입력

String

IStorageContext

출력

AzureDataLakeGen2Item