powershellscripts.com

Tutorials  PowerShell Cmdlet Help for Get-VMHostStorage



NAME
Get-VMHostStorage

SYNOPSIS
Retrieves the host storages on a vSphere server.

SYNTAX
Get-VMHostStorage [-VMHost] [-Refresh] [-RescanAllHba] [-RescanVmfs] [-Server ] [ meters>]


DESCRIPTION
Retrieves the host storages on a vSphere server. The cmdlet returns a list of the storages on the hosts specified b
y the VMHost parameter. To specify a server different from the default one, use the -Server parameter.


PARAMETERS
-VMHost
Specify the hosts for which you want to retrieve storage information.

Required? true
Position? 1
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? true

-Refresh
Indicate whether the cmdlet refreshes the storage system information before retrieving the specified host stora
ges.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-RescanAllHba
Indicate whether to issue a request to rescan all virtual machine hosts bus adapters for new storage devices pr
ior to retrieving the storage information.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-RescanVmfs
Indicate whether to perform a re-scan for new virtual machine file systems that might have been added, prior to
retrieving the storage information.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Server
Specify the vSphere servers on which you want to run the cmdlet. If no value is given to this parameter, the co
mmand runs on the default servers. For more information about default servers, see the description of Connect-V
IServer.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? true


This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer and OutVariable. For more information, type,
"get-help about_commonparameters".

INPUTS



OUTPUTS
VMHostStorageInfo


NOTES


The ScsiLun property of the VMHostStorageInfo object is deprecated and scheduled for removal.

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

C:\PS>Get-VmHostStorage -VMHost 10.23.112.234 -Refresh


Retrieves storage information from the virtual machine host with IP address 10.23.112.234.





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

C:\PS>Get-VMHostStorage | select -expandproperty scsilun | fl *


Retrieves information about the vendor, model, and serial number of the virtual machine host storage SCSI adapter.

Note that for devices, that are not SCSI-3 compliant, the SerialNumber property is not defined. And not all SCSI-3
compliant devices provide the serial number information.






RELATED LINKS
Online version: http://www.vmware.com/support/developer/PowerCLI/PowerCLI501/html/Get-VMHostStorage.html
Set-VMHostStorage