-
Notifications
You must be signed in to change notification settings - Fork 41
DatastoreClusterAddDatastore
SimeonGerginov edited this page May 13, 2020
·
1 revision
Parameter | Attribute | DataType | Description | Allowed Values |
---|---|---|---|---|
Server | Key | string | The name of the Server we are trying to connect to. The Server can only be a vCenter Server. | |
Credential | Mandatory | PSCredential | The credentials needed for connection to the specified Server. | |
DatacenterName | Key | string | The name of the Datacenter where the specified Datastore Cluster and Datastores are located. | |
DatacenterLocation | Key | string | The location of the Datacenter where the specified Datastore Cluster and Datastores are located. The Root Folder of the Inventory is not part of the location. Empty location means that the Datacenter is in the Root Folder of the Inventory. The Folder names in the location are separated by '/'. Example Datacenter location: MyDatacentersFolderOne/MyDatacentersFolderTwo. | |
DatastoreClusterName | Key | string | The name of the Datastore Cluster located in the Datacenter specified in DatacenterName key property. | |
DatastoreClusterLocation | Key | string | The location of the Datastore Cluster with name specified in DatastoreClusterName key property in the Datacenter specified in DatacenterName key property. Location consists of 0 or more Folders. Empty location means that the Datastore Cluster is located in the Datastore Folder of the Datacenter. The Root Folders of the Datacenter are not part of the location. Folder names in the location are separated by '/'. Example location for a Datastore Cluster: MyDatastoreClusterFolderOne/MyDatastoreClusterFolderTwo. | |
DatastoreNames | Mandatory | string[] | The names of the Datastores that should be located in the specified Datastore Cluster. |
The resource is used to add Datastores to the specified Datastore Cluster.
Adds Datastores DscDatastoreOne and DscDatastoreTwo to Datastore Cluster DscDatastoreCluster located in Datacenter Datacenter.
Configuration DatastoreClusterAddDatastore_AddDatastoresToDatastoreCluster_Config {
Param(
[Parameter(Mandatory = $true)]
[ValidateNotNullOrEmpty()]
[string]
$Server,
[Parameter(Mandatory = $true)]
[ValidateNotNullOrEmpty()]
[System.Management.Automation.PSCredential]
$Credential
)
Import-DscResource -ModuleName VMware.vSphereDSC
Node localhost {
DatastoreClusterAddDatastore DatastoreClusterAddDatastore {
Server = $Server
Credential = $Credential
DatacenterName = 'Datacenter'
DatacenterLocation = ''
DatastoreClusterName = 'DscDatastoreCluster'
DatastoreClusterLocation = ''
DatastoreNames = @('DscDatastoreOne', 'DscDatastoreTwo')
}
}
}
- Home
- Tips & Tricks
- Cluster
- DRSRule
- Datacenter
- DatacenterFolder
- DatastoreCluster
- DatastoreClusterAddDatastore
- DrsCluster
- Folder
- HACluster
- NfsDatastore
- NfsUser
- PowerCLISettings
- StandardPortGroup
- StandardSwitch
- VDPortGroup
- VDSwitch
- VDSwitchVMHost
- VMHostAcceptanceLevel
- VMHostAccount
- VMHostAdvancedSettings
- VMHostAgentVM
- VMHostAuthentication
- VMHostCache
- VMHostConfiguration
- VMHostDCUIKeyboard
- VMHostDnsSettings
- VMHostFirewallRuleset
- VMHostGraphics
- VMHostGraphicsDevice
- VMHostIPRoute
- VMHostIScsiHba
- VMHostIScsiHbaTarget
- VMHostIScsiHbaVMKernelNic
- VMHostNetworkCoreDump
- VMHostNtpSettings
- VMHostPciPassthrough
- VMHostPermission
- VMHostPhysicalNic
- VMHostPowerPolicy
- VMHostRole
- VMHostSNMPAgent
- VMHostSatpClaimRule
- VMHostScsiLun
- VMHostScsiLunPath
- VMHostService
- VMHostSettings
- VMHostSharedSwapSpace
- VMHostSoftwareDevice
- VMHostStorage
- VMHostSyslog
- VMHostTpsSettings
- VMHostVDSwitchMigration
- VMHostVMKernelActiveDumpFile
- VMHostVMKernelActiveDumpPartition
- VMHostVMKernelDumpFile
- VMHostVMKernelModule
- VMHostVdsNic
- VMHostVss
- VMHostVssBridge
- VMHostVssMigration
- VMHostVssNic
- VMHostVssPortGroup
- VMHostVssPortGroupSecurity
- VMHostVssPortGroupShaping
- VMHostVssPortGroupTeaming
- VMHostVssSecurity
- VMHostVssShaping
- VMHostVssTeaming
- VMHostvSANNetworkConfiguration
- VmfsDatastore
- vCenterSettings
- vCenterStatistics
- vCenterVMHost