## PowerCLI Reference

# Get-CIDatastore

## Synopsis

This cmdlet retrieves the datastores available on a cloud server.

Syntax

Get-CIDatastore [-Server <CIServer[]>] [[-Name] <String[]>] [-ProviderVdc <ProviderVdc[]>] [-InformationAction <ActionPreference>] [-InformationVariable <String>] [-PipelineVariable <String>] [<CommonParameters>]
Get-CIDatastore -Id <String[]> [-Server <CIServer[]>] [-InformationAction <ActionPreference>] [-InformationVariable <String>] [-PipelineVariable <String>] [<CommonParameters>]

Related Commands

Add-CIDatastore
Online version

Detailed Description

This cmdlet retrieves the datastores available on a cloud server. To specify a server different from the default one, use the Server parameter. Note: This cmdlet is only available to Provider Administrators.

Parameters

Name | Type | Description | Required? | Pipeline Input | Default Value
--- | --- | --- | --- | --- | ---
Name | String[] | Specifies the names for the datastores that you want to retrieve. | false | false
Id | String[] | Specifies the IDs of the datastores that you want to retrieve. Note: When a list of values is specified for the Id parameter, the returned objects would have an ID that matches exactly one of the string values in that list. | true | false
InformationAction | ActionPreference |  | false | false
InformationVariable | String |  | false | false
PipelineVariable | String |  | false | false
ProviderVdc | ProviderVdc[] | Specifies the provider vDC for which you want to retrieve datastores. | false | true (ByValue)
Server | CIServer[] | Specifies the cloud servers 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-CIServer. | false | false

Return Type

Zero or more CIDatastore objects

Notes

Examples

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

    Get-CIDatastore -Name "MyDatastore*"

Retrieves all datastores with names that start with "MyDatastore" from all available provider vDCs.

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

    Get-CIDatastore -Name *datastore* -ProviderVDC "MyProviderVDC1", "MyProviderVDC2"

Retrieves all datastores with names that contain "datastore" from multiple provider vDCs.

Copyright © VMware, Inc. All rights reserved.