Disconnects host systems.





-Id <String>

Attributes: Optional, Position: 1

Specifies the host name, IP address, or global ID. Wildcards are permitted. It is a positional parameter (position = 1).


-Force <SwitchParameter>

Attributes: Optional, Position: named

Allows the cmdlet to continue without asking for user confirmation.


-Silent <SwitchParameter>

Attributes: Optional, Position: named

Turns off all the informational and verbose messages. However, it still displays errors.


-WhatIf <SwitchParameter>

Attributes: Optional, Position: named

Shows what would happen if the cmdlet runs. The cmdlet is not run.


-Confirm <SwitchParameter>

Attributes: Optional, Position: named

Prompts you for confirmation before executing the command.


-System <IHostSystem>

Attributes: Optional, Position: named

Specifies the ESI host system object, which can be added by using the Get-EmcHostSystemCredential and Connect-EmcSystem cmdlets. You can obtain a host system object by using the Get-EmcHostSystem cmdlet. It can be a stand-alone host system or virtual machine or hypervisor.



This cmdlet supports these common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, and OutVariable. Type get-help about_commonparameters for more details.



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

C:\PS>$hBlob = Get-EmcHostSystemCredential

C:\PS>$h = $hBlob | Connect-EmcSystem




C:\PS>Get-EmcHostSystem | Disconnect-EmcHostSystem

This example disconnects connected host systems with user confirmation.


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

C:\PS>$hBlob = Get-EmcHostSystemCredential

C:\PS>$h = $hBlob | Connect-EmcSystem


C:\PS>Disconnect-EmcHostSystem -System $h -Confirm


C:\PS>Disconnect-EmcHostSystem -System $h


C:\PS>Disconnect-EmcHostSystem -System $h -Force


C:\PS>$h | Disconnect-EmcHostSystem

This example disconnects a specified host system.


---------- Example 3 ----------

C:\PS>Disconnect-EmcHostSystem -Id myhost*

C:\PS>Disconnect-EmcHostSystem -Id 10.x.y.*

C:\PS>Disconnect-EmcHostSystem 2cc75087-8ddf*

This example disconnects a host system based on the specified host name or IP address or global ID (accepts wild card). Because the ID parameter is positional, you can omit the name.