PowerCLI Reference

Get-VsanFileShare

Synopsis

This cmdlet retrieves vSAN file shares based on the name or ID filter.

Syntax

Get-VsanFileShare [[-Name] <String[]>] [-Cluster <Cluster[]>] [-FileServiceDomain <VsanFileServiceDomain[]>] [-Server <VIServer[]>] [<CommonParameters>]

Get-VsanFileShare -Id <String[]> [-Server <VIServer[]>] [<CommonParameters>]

Related Commands

Online Version
New-VsanFileShare
Remove-VsanFileShare
Set-VsanFileShare

Detailed Description

This cmdlet retrieves vSAN file shares based on the name or ID filter.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
NameString[]Filters the retrieved vSAN file share by name.falseFalse
ClusterCluster[]Specifies the vSAN cluster to which the file share belongs.falseTrue (ByValue)
FileServiceDomainVsanFileServiceDomain[]Specifies the vSAN file service domain to which the vSAN file share belongs. If not specified, the vSAN file shares under all vSAN file service domains will be queried.falseTrue (ByValue)
IdString[]Filters the retrieved vSAN file share by ID.trueFalse
ServerVIServer[]Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is given to this parameter, the command runs on the default servers. For more information about default servers, see the description of the Connect-VIServer cmdlet.falseFalse

Return Type

Zero or more vSAN file share objects.

Notes

Examples

-------------------------- Example 1 --------------------------

Get-VsanFileShare -FileServiceDomain $fileServiceDomain

Retrieves the vSAN file share which belongs to the $fileServiceDomain file service domain.

-------------------------- Example 2 --------------------------

Get-VsanFileShare -Cluster $cluster -Name "FileShare1"

Retrieves the vSAN file share named "FileShare1" from the $cluster vSAN cluster.


Copyright © VMware, Inc. All rights reserved.