# Add-CVVirtualMachineGroupContent

This commandlet (cmdlet) functions only for VMware, Hyper-V and vCloud.

The `Add-CVVirtualMachineGroupContent` cmdlet allows you to preview the content of a VM group and creates clients from the result set.

Before you can use this cmdlet, you must log on to your CommCell environment using the `Connect-CVServer` cmdlet. For more information, see Connecting to a CommCell Environment with PowerShell.

## Syntax

    Add-CVVirtualMachineGroupContent -SubclientObject $[Object] -EntityType $[Host | Datastore | VMName | VMNamePattern | GuestOS | GuestDNSHostname | PoweredState | Notes | TemplateState | Tag | TagCategory] [-PoweredState $[Off | On | Other]] [-TemplateState $[Boolean]] [-MatchingPattern $[Contains | Equals | StartsWith | EndsWith]] [-DisplayName $[String]] [-VMName $[String]] [-CreateClientsForDiscoveredVms] [-Force] [-WhatIf] [-Confirm] [$[CommonParameters]]

## Required Parameters

Parameter | Description | Data type | Values | Accepts pipeline input? | Accepts wildcard characters? | Type of parameter
--- | --- | --- | --- | --- | --- | ---
`-SubclientObject` | An object that represents a VM group that you want to preview the content for. | Object |  | Yes, by: Value Property name | No | Named
`-EntityType` | The entity type of the virtual server. |  | Valid values are: Host Datastore VMName VMNamePattern GuestOS GuestDNSHostname PoweredState Notes TemplateState Tag TagCategory | No | No | Named

## Optional Parameters

### Commvault Parameters

Parameter | Description | Data type | Values | Accepts pipeline input? | Accepts wildcard characters? | Type of parameter
--- | --- | --- | --- | --- | --- | ---
`–PoweredState` | The state of the entity type. |  | Valid values are: On Off Other | No | No | Named
`–TemplateState` | The template state of the entity type. | Boolean | Valid values are: True (default) False | No | No | Named
`–MatchingPattern` | The matching pattern to perform a search on the Display Name parameter. |  | Valid values are: Contains Equals (default) StartsWith EndsWith | Yes, by: Value Property name | No | Named
`–DisplayName` | The term used to perform a search. | String |  | No | No | Named
`-VMName` | The GUID of the VM. | String |  | No | No | Named
`-CreateClientsForDiscoveredVms` | The toggle key that indicates whether to create clients for discovered VMs. Before you create clients, preview discovery results. | Switch Parameter | The default value is False. | No | No | Named

### Microsoft PowerShell Parameters

You can use the following Microsoft PowerShell parameters:

- Debug

- ErrorAction

- ErrorVariable

- OutBuffer

- OutVariable

- PipelineVariable

- Verbose

- WarningAction

- WarningVariable

- Force

- Confirm

- WhatIf

Note

Only a few cmdlets support Force, Confirm, and WhatIf parameters.

For more information, see "About Common Parameters" in the Microsoft PowerShell documentation.

## Input

This cmdlet does not support input.

## Output

A PSCustomObject that contains VM discovery results.

## Example

This example previews the content of the GRS-VMGroup VM with Datastore entity type.

    Get-CVSubclient -Name $[GRS-VMGroup1] -ClientName $[accounting.mycompany.com] | Add-CVVirtualMachineGroupContent -EntityType $[Datastore] -MatchingPattern $[EndsWith] -DisplayName $[DS1]

×

Loading...