PowerShell Logo Small

Set-IscsiServerTarget



This is the built-in help made by Microsoft for the command 'Set-IscsiServerTarget', in PowerShell version 5 - as retrieved from Windows version 'Microsoft Windows Server 2012 R2 Standard' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.

SYNOPSIS

Modifies settings for the specified iSCSI target.

SYNTAX


Set-IscsiServerTarget [-TargetName] <String> [-Chap <PSCredential>] [-ComputerName <String>] [-Credential <PSCredential>] [-Description <String>] [-Enable <Boolean>]
[-EnableChap <Boolean>] [-EnableReverseChap <Boolean>] [-EnforceIdleTimeoutDetection <Boolean>] [-FirstBurstLength <Int32>] [-InitiatorIds <InitiatorId[]>] [-MaxBurstLength
<Int32>] [-MaxReceiveDataSegmentLength <Int32>] [-PassThru] [-ReceiveBufferCount <Int32>] [-ReverseChap <PSCredential>] [-TargetIqn <Iqn>] [<CommonParameters>]
Set-IscsiServerTarget [-Chap <PSCredential>] [-ComputerName <String>] [-Credential <PSCredential>] [-Description <String>] [-Enable <Boolean>] [-EnableChap <Boolean>]
[-EnableReverseChap <Boolean>] [-EnforceIdleTimeoutDetection <Boolean>] [-FirstBurstLength <Int32>] [-InitiatorIds <InitiatorId[]>] [-MaxBurstLength <Int32>]
[-MaxReceiveDataSegmentLength <Int32>] [-PassThru] [-ReceiveBufferCount <Int32>] [-ReverseChap <PSCredential>] [-TargetIqn <Iqn>] -InputObject <IscsiServerTarget>
[<CommonParameters>]



Search powershellhelp.space

DESCRIPTION


The Set-IscsiServerTarget cmdlet modifies settings for the iSCSi target and returns the corresponding iSCSI Target object if the PassThru parameter is specified.



<

RELATED LINKS

Online Version: http://go.microsoft.com/fwlink/?LinkID=294086
ConvertTo-SecureString
New-Object
Get-IscsiServerTarget
New-IscsiServerTarget
Remove-IscsiServerTarget

REMARKS

<

Examples


EXAMPLE 1

PS C:\>Set-IscsiServerTarget -TargetName Test -InitiatorId @()



This example removes all of the initiators that are associated with the target named Test.




EXAMPLE 2

PS C:\>Set-IscsiServerTarget –TargetName "TargetOne" -Description "Target for initiator Appsvr"



This example sets the description for a target named TargetOne to Target for initiator Appsvr.




EXAMPLE 3

PS C:\>$password = ConvertTo-SecureString -String "passwordpass" -AsPlainText -Force



PS C:\>$chap = New-Object -ComObject System.Management.Automation.PSCredential("user", $password)



PS C:\>Set-IscsiServerTarget –TargetName "T1" -EnableChap $true -Chap $chap



This example enables and sets the forward CHAP on a target named T1 with the credentials user and password.




EXAMPLE 4

PS C:\>Set-IscsiServerTarget -TargetName Test -InitiatorId @("IPAddress:10.10.1.10","IPAddress:10.10.1.11")



This example assigns more IDs to the same target.




EXAMPLE 5

PS C:\>Set-IscsiServerTarget -TargetName Test -InitiatorId "IQN:*"



This example assigns the target to all initiators that attempt to connect to it. Because no validation is performed the iSCSI target when an initiator makes a connection, be
very cautious when using this configuration. It is most useful when troubleshooting connection issues ─ removing the possibility of Target-Initiator assignment errors.