Managing SRM advanced configurations

In this section, we will discuss how to manage SRM through APIs. To manage a SRM server, we first need to connect to vCenter Server. Once we are connected to vCenter Server, we can connect to the SRM server using the following cmdlet:

PS C:\ $SrmServer = Connect-SrmServer

To access the SRM APIs, we can use the following command:

PS C:\ $SrmApi = $SrmServer.ExtensionData
PS C:\ > $SrmApi |FL

Content    : VMware.VimAutomation.Srm.Views.SrmServiceInstanceContent
Recovery   : VMware.VimAutomation.Srm.Views.SrmRecovery
Protection : VMware.VimAutomation.Srm.Views.SrmProtection
MoRef      : SrmServiceInstance-SrmServiceInstance

As you can see from the preceding example, the SRM APIs are divided into three groups: Content, ...

Get Mastering PowerCLI now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.