Book Image

PowerCLI Essentials

By : Chris Halverson
Book Image

PowerCLI Essentials

By: Chris Halverson

Overview of this book

Have you ever wished you could automatically get a report with all the relevant information about your VMware environments in exactly the format you want? Or that you could automate a crucial task that needs to be performed on a regular basis? Powerful Command Line Interface (PowerCLI) scripts do all these things and much more for VMware environments. PowerCLI is a command-line interface tool used to automate VMware vSphere environments. It is used to handle complicated administration tasks through use of various cmdlets and scripts, which are designed to handle certain aspects of VSphere servers and to help you manage them. This book will show you the intricacies of PowerCLI through real-life examples so that you can discover the art of PowerCLI scripting. At the start, you will be taught to download and install PowerCLI and will learn about the different versions of it. Moving further, you will be introduced to the GUI of PowerCLI and will find out how to develop single line scripts to duplicate running tasks, produce simple reports, and simplify administration. Next, you will learn about the methods available to get information remotely. Towards the end, you will be taught to set up orchestrator and build workflows in PowerShell with update manager and SRM scripts.
Table of Contents (13 chapters)
PowerCLI Essentials
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Orchestrating the integration of Site Recovery Manager


Site Recovery Manager (SRM) is a completely different type of tool from the NSX network platform. SRM is an orchestration tool that controls a storage array (SAN or NAS) or the vSphere Replication failover process. So, because it is an orchestration engine, if the failover process doesn't work manually, a SRM failover will not work either.

An SRM installation consists of a Windows installation where the SRM component is installed too, a database where the configuration is stored, and the vCenter registered extension or plug-in. In SRM 5.5 or older, it is integrated into the VIClient whereas SRM 5.8 and newer are integrated into the WebClient. Once the install is complete and the SRM install is connected to the vCenter, there are a number of things that PowerShell and PowerCLI can do.

PowerCLI and SRM

First, run the Connect-viServer <vCenter> command to connect the vCenter server.

Then, use Connect-SrmServer to connect to the SRM server...