## PowerCLI Reference

# Get-VsanIscsiTarget

## Synopsis

This cmdlet retrieves vSAN iSCSI targets from clusters.

Syntax

Get-VsanIscsiTarget [-Cluster <Cluster[]>] [[-Name] <String[]>] [-IscsiQualifiedName <String[]>] [-Server <VIServer[]>] [<CommonParameters>]
Get-VsanIscsiTarget -Id <String[]> [-Server <VIServer[]>] [<CommonParameters>]

Related Commands

Online version
New-VsanIscsiLun
Remove-VsanIscsiLun
Set-VsanIscsiLun

Detailed Description

This cmdlet retrieves vSAN iSCSI targets from clusters. The cmdlet can filter targets by IQN and aliases.

Parameters

Name | Type | Description | Required? | Pipeline Input | Default Value
--- | --- | --- | --- | --- | ---
Name | String[] | Filters the retrieved vSAN iSCSI targets by name. | false | false
Cluster | Cluster[] | Specifies the clusters from which to retrieve vSAN iSCSI targets. | false | true (ByValue)
Id | String[] | Filters the retrieved vSAN iSCSI targets by ID. | true | false
IscsiQualifiedName | String[] | Filters the retrieved vSAN iSCSI targets by IQN. | false | false
Server | VIServer[] | 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 Connect-VIServer. | false | false

Return Type

Zero or more VsanIscsiTarget objects

Notes

Examples

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

    Get-VsanIscsiTarget -Cluster "vsan-cluster"

Retrieves all vSAN iSCSI targets from the "vsan-cluster" cluster.

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

    Get-VsanIscsiTarget -Cluster $cluster -Name "Target1"

Retrieves the vSAN iSCSI target named "Target1" from the $cluster vSAN cluster.

Copyright © VMware, Inc. All rights reserved.