VMware vRealize Orchestrator Cookbook - Second Edition - Daniel Langenhan - E-Book

VMware vRealize Orchestrator Cookbook - Second Edition E-Book

Daniel Langenhan

0,0
50,39 €

-100%
Sammeln Sie Punkte in unserem Gutscheinprogramm und kaufen Sie E-Books und Hörbücher mit bis zu 100% Rabatt.

Mehr erfahren.
Beschreibung

Over 90 recipes to satisfy all your automation needs and leverage vRealize Orchestrator 7.1 for your projects

About This Book

  • Unleash the power of VMware vRealize Orchestrator 7 and automate your VMware infrastructure
  • Customize and tune your orchestrator by programming and working with plugins
  • Work through enticing recipes that can be implemented in your organization
  • Explore the new and upcoming plugins of Puppet, Docker, Chef, and VMware Replication for VMware vRealize Orchestrator

Who This Book Is For

This book is for system administrators who are into VMware administration and are looking to automate their infrastructure. Basic knowledge about programming is needed. No previous knowledge of Orchestrator is required.

This book will also be good for you if you have just a basic knowledge with vRealize Orchestrator, as you can pick up any recipe and implement it for your enterprise.

What You Will Learn

  • Install, configure, and optimize Orchestrator installations (Windows, Appliance, and vRA integrated)
  • Explore all the visual programming elements without needing additional infrastructure
  • Work with plugins such as SSH, mail, SQL, PowerShell, AD, SOAP, SNMP, AMQP, and REST
  • Discover how to create VMware automation
  • Get to know about user management, import/export, and synchronization as well as the packaging application
  • Understand policies, resources, and web views
  • Troubleshoot vRO Appliance

In Detail

VMware vRealize Orchestrator is a powerful automation tool designed for system administrators and IT operations staff who are planning to streamline their tasks and are waiting to integrate the functions with third-party operations software. This book is an update to VMware vRealize Orchestrator Cookbook and is blend of numerous recipes on vRealize Orchestrator 7.

This book starts with installing and configuring vRealize Orchestrator. We will demonstrate how to upgrade from previous versions to vRealize Orchestrator 7. You will be taught all about orchestrator plugins and how to use and develop various plugins that have been enhanced in Orchestrator 7. Throughout this book, you will explore the new features of Orchestrator 7, such as the introduction of the control center, along with its uses.

You will also come to understand visual programming, how to integrate base plugins into workflows, and how to automate VMware. You will also get to know how to troubleshoot vRealize Orchestrator.

By the end of this book, you will be able to get the most out of your Orchestrator installation, and will be able to develop complex workflows and create your own highly integrated automations of vRealize environments.

Style and approach

This practical guide provides exciting and practical recipes on VMware vRealize Orchestrator 7 for those who are waiting to automate their infrastructure.

Sie lesen das E-Book in den Legimi-Apps auf:

Android
iOS
von Legimi
zertifizierten E-Readern

Seitenzahl: 504

Veröffentlichungsjahr: 2016

Bewertungen
0,0
0
0
0
0
0
Mehr Informationen
Mehr Informationen
Legimi prüft nicht, ob Rezensionen von Nutzern stammen, die den betreffenden Titel tatsächlich gekauft oder gelesen/gehört haben. Wir entfernen aber gefälschte Rezensionen.



Table of Contents

VMware vRealize Orchestrator Cookbook Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Why subscribe?
Preface
Changes in this edition
A short history of Orchestrator
Best approaches to reading this book
What this book covers
What you need for this book
Who this book is for
Example workflows
Conventions
Reader feedback
Customer support
Downloading the example code 
Downloading the color images of this book 
Errata
Piracy
Questions
1. Installing and Configuring Orchestrator
Introduction
Licensing
vRealize Orchestrator 7 changes
Orchestrator appliance basics
Orchestrator and vRealize Automation (vRA)
Deploying the Orchestrator appliance
Getting ready
How to do it...
Download
Deploy
Log in to the Orchestrator Client
Log into Control Center
How it works...
There's more...
See also
Important Orchestrator settings
Getting ready
How to do it...
Starting, stopping, and restarting the Orchestrator service
Licensing
Package Signing Certificate
Trusted SSL certificates
Force plugins reinstall
How it works...
See also
Configuring an external database
Getting ready
How to do it...
How it works...
Sizing
Database roles
Exporting and importing a database
Purging the Database
There's more...
Microsoft SQL
Oracle
Internal PostgreSQL
See also
Configuring external authentication
Getting ready
How to do it...
vSphere (PSC) and vRealize Automation (vRA)
SSO (legacy)
LDAP
How it works...
vRealize Automation and vSphere Authentication
Test login
Internal LDAP
There's more...
See also
Connecting to vCenter
Getting ready
How to do it...
Well, there is that...
How it works...
Access, rights, and logging
Technical user
vRA, Orchestrator, and vCenter
See also
Installing plugins
Getting ready
How to do it...
How it works...
Plugin log level
Updating plugins
Disabling and uninstalling plugins
See also
Updating Orchestrator
Getting ready
How to do it...
Using an ISO file
Using the VMware repository
Applying the update
How it works...
There's more...
See also
Moving from Windows to appliance
Getting ready
How to do it...
Migration tool
External database
Package transfer
How it works...
There's more...
Orchestrator Client and 4K display scaling
Getting ready
How to do it...
How it works...
There's more...
2. Optimizing Orchestrator Configuration
Introduction
Tuning the appliance
Getting ready
How to do it...
Virtual Hardware
Changing the IP and hostname
Setting the time (NTP)
Turning SSH access to Orchestrator on and off
Switching off unneeded services
Root account expires
How it works...
See also
Tuning Java
Getting ready
How to do it...
How it works...
JVM metrics in Control Center
See also
Configuring the Kerberos authentication
Getting ready
How to do it...
How it works...
See also
Configuring access to the local filesystem
Getting ready
How to do it...
Fast and easy
Configuring access
How it works...
There's more...
See also
Configuring the Orchestrator service SSL certificate
Getting ready
How to do it...
Self-signed certificates
Using VMCA generated certificates
CA-signed certificate
How it works...
Default, self-signed, or CA-signed?
VMCA
PEM encoded files
There's more...
Getting the SSL store password
Backing up the default certificates
Creating certificates and requests
Generating certificates with alternative names (SAN certificate)
Signing and importing certificates
See also
Orchestrator log files
Getting ready
How to do it...
Server log in Control Center
Configuring the server log with the Control Center
Accessing the log files via SSH
Changing log file behavior
How it works...
See also
Redirecting Orchestrator logs to an external server
Getting ready
vRealize Log Insight
How to do it...
Syslog with Log4J
Log Insight Agent
How it works...
Configuring the Orchestrator Log Insight Agent to forward to Syslog
There's more...
See also
Backup and recovery
Getting ready
How to do it...
Backing up Orchestrator configuration
Backing up an internal database
Restore
How it works...
External database
There's more...
Cron job
vRO policy
vRO Control Center API
See also
Control Center titbits
Getting ready
How to do it...
Inspecting workflows
System properties
Changing the Control Center user name
File System Browser
How it works...
Control Center API
System properties
There's more...
See also
3. Distributed Design
Introduction
Cluster design
Distributed design
Geographically Distributed
Logically Distributed
Scaling out
Central management
Building an Orchestrator cluster
Getting ready
How to do it...
Preparation work
Configuring the first node of the cluster
Configure cluster settings
Join a node to the cluster
Configuring an Orchestrator cluster in vSphere
Playing with the cluster
Push configuration
How it works...
SSL Certificates in vRO7.1.0
Cluster and Orchestrator Client
Changing cluster content
Changing cluster settings
Removing a node from the cluster
There's more...
Logs
Another method of load-balancing
Example workflow - cluster test
See also
Load-balancing Orchestrator
Getting ready
How to do it...
Creating a new NSX Edge
Configuring the load-balancer
Dealing with SSL certificates
Monitors - health checks
Configure pools
Virtual server
Done
How it works...
SSL certificates and load-balancing
SSL passthrough
SSL SAN (SSL passthrough)
SSL offload
Load-balanced Orchestrator cluster with vSphere Web Client
See also
Upgrading a cluster
Getting ready
How to do it...
Minor upgrades
Major upgrades
How it works...
See also
Managing remote Orchestrators
Getting ready
How to do it...
Adding an Orchestrator server
Creating proxy workflows
Managing packets on the remote Orchestrator
How it works...
See also
Synchronizing Orchestrator elements between Orchestrator servers
Getting ready
How to do it...
How it works...
See also
4. Programming Skills
Introduction
The Orchestrator icons
Gotcha
Auto-setup of parameters
Version control
Getting ready
How to do it...
Showing differences between versions
Reverting to an older version
How it works...
See also
Changing elements in a workflow
Getting ready
How to do it...
Changing the parameters of workflows and actions
Renaming and moving actions
Finding related elements
How it works...
See also
Importing and exporting Orchestrator elements
Getting ready
How to do it...
Exporting an object
Importing an element
How it works...
See also
Working with packages
Getting ready
How to do it...
Create a new package
Export a package
Import a package
Deleting a package
Import from remote
How it works...
Export and import options
There's more...
See also
Workflow auto documentation
Getting ready
How to do it...
How it works...
Resuming failed workflows
Getting ready
How to do it...
How it works...
There's more...
See also
Using the workflow debugging function
Getting ready
How to do it...
How it works...
There's more...
See also
Undelete workflows and actions
Getting ready
How to do it...
How it works...
Scheduling workflows
Getting ready
How to do it...
How it works...
There's more...
See also
Sync presentation settings
Getting ready
How to do it...
How it works...
Locking elements
Getting ready
How to do it...
Locking workflows
Unlocking workflows
How it works...
See also
5. Visual Programming
Introduction
Variables (general, inputs, and outputs)
Variables in the general section
Variables in the input section
Variables in the output section
Variable types
Working with a schema
Presentation
Scripting with logs
Getting ready
How to do it...
Creating logs
Checking log files
How it works...
Log file location
Altering log elements
See also
Scripting with decisions
Getting ready
How to do it...
Basic decision
Custom decisions
Decision activity
The Switch element
How it works...
JavaScript - if and else
JavaScript - Switch
See also
Error handling in workflows
Getting ready
How to do it...
Default error handler
How it works...
Ignoring errors
The handle error element
See also
Scripting with loops
Getting ready
How to do it...
The decision loop
The Foreach loop
How it works...
Types of decision loops
Foreach and arrays
JavaScript
There's more...
See also
Workflow presentations
Getting ready
How to do it...
Preparation
Description
In-parameter properties
Steps and groups
Hiding input values
Basic linking
How it works...
General properties
Plugin-specific properties
select value as
show in inventory
Specify a root object to be shown in the chooser
Authorized only
There's more...
See also
Linking actions in presentations
Getting ready
How to do it...
How it works...
See also
Changing credentials during runtime
Getting ready
How to do it...
How it works...
See also
6. Advanced Programming
Introduction
Cool stuff in the scripting tasks
A - show all objects
B - find stuff
C - line and character
JavaScript (the very basics)
JavaScript tricks and tips
Is a string part of another string? (indexOf)
Case sensitivity (toUpperCase)
Getting rid of extra space (trim)
String replacement with regular expressions (replace)
Check a variable for type (instanceof)
Working with dates
Add minutes to a date
JavaScript complex variables
Getting ready
How to do it...
Arrays
Properties
Objects
How it works...
Array methods
Properties within properties
Array of properties
See also
Working with JSON
Getting ready
How to do it...
Parsing JSON REST returns
Creating a JSON object
Change JSON object
How it works...
See also
JavaScript special statements
Getting ready
How to do it...
The try, catch, and finally statement
The function statement
How it works...
See also
Turning strings into objects
Getting ready
How to do it...
How it works...
There's more...
See also
Working with the API
Getting ready
How to do it...
Searching for items in the API
Programming help from the API
How it works...
See also
Creating actions
Getting ready
How to do it...
Creating a new action
Implementing an action into a workflow
How it works...
See also
Waiting tasks
Getting ready
How to do it...
Creating a help task
Using the Sleep task
Waiting for a date
How it works...
There's more...
See also
Sending and waiting for custom events
Getting ready
How to do it...
Receiving a custom event
Sending a custom event
Trying it out
How it works...
External events
See also
Using asynchronous workflows
Getting ready
How to do it...
The first example
The second example
How it works...
See also
Scripting with workflow tokens
Getting ready
How to do it...
How it works...
See also
Working with user interactions
Getting ready
How to do it...
Creating the workflow
Answering the user interaction
How it works...
There's more...
Answering using vRealize Automation
See also
7. Interacting with Orchestrator
Introduction
User management
Getting ready
How to do it...
Giving non-administrative users access to Orchestrator
Configuring access to Orchestrator elements
How it works...
Same user - two groups
Edit user rights
Right inheritance
Rights for sub-elements
Visibility
Access right
There's more...
The login format
Typical error messages
Disabling non-administrative access to Orchestrator
User preferences
Getting ready
How to do it...
How it works...
General
Workflow
Inventory
Script editor
Using Orchestrator though the vSphere Web Client
Getting ready
How to do it...
Configure workflows for the vSphere Web Client
Run workflows
Writing workflows for web integration
Passing information along
How it works...
Orchestrator presentation properties in vSphere Web Client
There's more...
See also
Accessing Orchestrator REST API
Getting ready
How to do it...
Accessing the API documentation and enable "play mode"
Try it out!
Interactive REST request
How it works...
There's more...
See also
Accessing the Control Center via the REST plugin
Getting ready
How to do it…
Explore the Control Center API
Adding start and stop calls
Usage
How it works...
See also
Running Orchestrator workflows using PowerShell
Getting ready
How to do it...
Run a workflow
Run a script with input
Getting the output of a workflow
How it works...
Variables
JSON return
There's more...
See also
Using PHP to access the REST API
Getting ready
How to do it...
How it works...
There's more...
See also
8. Better Workflows and Optimized Working
Introduction
Working with resources
Getting ready
How to do it...
Adding resources manually
Using resources in workflows
Creating a new resource element
Create a resource by uploading a file
Updating a resource
How it works...
There's more...
Accessing resources directly
Deleting a resource
See also
Working with configurations
Getting ready
How to do it...
Creating a configuration
Using a configuration in a workflow
How it works...
There's more...
See also
Working with Orchestrator tags
Getting ready
How to do it...
Tagging an element (manual)
Tagging a workflow (workflow)
Viewing all tags in a workflow
Finding workflows by tag
How it works...
There's more...
See also
Using the Locking System
Getting ready
How to do it...
Create a lock
Check for lock
Unlock
How it works...
See also
Language packs (localization)
Getting ready
How to do it...
How it works...
Working with policies
Getting ready
How to do it...
How it works...
Policy templates
Triggers
The event variable
See also
9. Essential Plugins
Introduction
Working with e-mail
Getting ready
How to do it...
Configuring the e-mail connection
Sending e-mails
Receiving e-mails
How it works...
Working with attachments
There's more...
See also
File operations
Getting ready
How to do it...
Writing a file
Reading a file
Getting information on files
Creating, renaming, and deleting a file or directory
How it works...
Executing scripts
Shared directories
There's more...
CSV files
Doing things as root
See also
Working with SSH
Getting ready
How to do it...
Using SSH
Using SSL key authentication
Using SCP
How it works...
See also
Working with REST
Getting ready
How to do it...
Connecting to a REST host
Using GET
Using POST
Creating a workflow from a REST operation
Phrasing the return value
Using the Swagger spec URL
How it works...
Authentications
Working with the results of a REST request
Default content type
See also
10. Built-in Plugins
Introduction
Dealing with return values
Shared or Per User Session
Working with XML
Getting ready
How to do it...
Creating an XML document
Parsing XML structures
How it works...
There's more...
See also
Working with SQL (JDBC)
Getting ready
How to do it...
Creating a JDBC connection URL
Connecting to and disconnecting from a database using JDBC
Executing an SQL statement using JDBC
SQL queries using JDBC
How it works...
The difference between the prepare and create statements
Creating a new database in the appliance's PostgreSQL
See also
Working with SQL (SQL plugin)
Getting ready
How to do it...
Add an SQL DB to Orchestrator
Run SQL statement
Run an SQL query
How it works...
See also
Working with PowerShell
Getting ready
How to do it...
Preparing the Windows host with WinRM
Adding a PowerShell host
Using Kerberos authentication
Executing a script
Calling a script that is stored on the PowerShell host
Sending a script to be executed to the PowerShell host
Generating an action and workflow from a script
How it works...
Workflow TLC
Basic versus Kerberos authentication
PowerShell output to XML
See also
Working with SOAP
Getting ready
How to do it...
Adding a new SOAP client
Invoking a SOAP request
Generating a new SOAP workflow
How it works...
See also
Working with Active Directory
Getting ready
How to do it...
Preparing AD for SSL
Registering AD with Orchestrator
Working with AD
How it works...
See also
Working with SNMP
Getting ready
How to do it...
Configuring SNMP devices
Sending a GET query to an ESXi host
Configuring a vCenter alarm to send an SNMP message
Receiving an SNMP message from vCenter
Using policies to trap SNMP messages
How it works...
OID and MIB
Working with SNMP return data
SNMP - port 162 versus port 4000
There's more...
Configuring SNMP for vCenter
Configuring ESXi servers for SNMP
See also
Working with AMQP
Getting ready
How to do it...
Adding an AMQP host
Defining exchanges, queues, and binds
Sending messages
Receiving messages
Subscribing to a queue
Using a policy as trigger
How it works...
There's more...
Installing RabbitMQ
See also
11. Additional Plugins
Introduction
Installing plugins
Obtaining plugins
VMware core plugins
vRO/vCO Team
VMware Solution Exchange
NSX integration
Getting ready
How to do it...
Configuring an endpoint
Creating a new logical switch
How it works...
vRealize Automation integration

VMware vRealize Orchestrator Cookbook Second Edition

VMware vRealize Orchestrator Cookbook Second Edition

Copyright © 2016 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

First published: January 2015

Second edition: October 2016

Production reference: 1241016

Published by Packt Publishing Ltd.

Livery Place

35 Livery Street

Birmingham 

B3 2PB, UK.

ISBN 978-1-78646-278-7

www.packtpub.com

Credits

Author

Daniel Langenhan

Copy Editor

Safis Editing

Reviewers

Burke Azbill

Christophe Decanini

Spas Kaloferov

Project Coordinator

Sheejal Shah

Commissioning Editor

Pratik Shah

Proofreader

Safis Editing

Acquisition Editor

Divya Poojari

Indexer

Tejal Daruwale Soni

Content Development Editor

Parshva Sheth

Production Coordinator

Aparna Bhagat

Technical Editor

Murtaza Tinwala

Cover Work

Aparna Bhagat

About the Author

Daniel Langenhan is a Virtualisation expert with formidable skills in Architecture, Design and Implementation for large multi-tier systems. His experience and knowledge of process management, enterprise-level storage, Linux and Windows operation systems has made him and his business a highly sought after international consultancy in the Asia-Pacific and European regions for multinational clientele in the areas of Finance, Communication, Education and Government. Daniel has been working with VMware products since 2002 and is directly associated with VMWare since 2008. His proven track record of successful integrations of Virtualisation into different business areas while minimizing cost and maximizing reliability and effectiveness of the solution for his clients.

Currently, Daniel is operating in the Europe and Asia-Pacific region with his company vLeet GmbH and Melbourne Business Boosters Pty Ltd.

Daniel's expertise and practical approach to VMWare has resulted in the publication of the following books:

Instant VMware vCloud Starter, Packt PublishingVMware View Security Essentials, Packt PublishingVMware vCloud Director Cookbook, Packt PublishingVMware vRealize Orchestrator Cookbook, Packt PublishingVMware vRealize Orchestrator Essentials, Packt Publishing

He has also lent his expertise to many other publishing projects as a Technical Editor.

This book would not have been possible without my understanding and loving wife. She not only endured a “tunnel-vision” writer but actively contributed as Editor number 1.

I would also acknowledge Pooja Nair, who helped me out with valuable editing and checking.

About the Reviewers

Burke Azbill has been a technology professional since 1996 and has held certifications from Cisco, Citrix, ITIL, Linux Professional Institute, Microsoft, Novell, and VMware. He joined VMware in 2007 as part of the acquisition of Dunes Technologies from Lausanne, Switzerland where he began his work with Orchestrator. Burke is a founder and contributor of the blog http://www.vcoteam.info as well as a leading contributor to the VMTN Communities for Orchestrator. During his tenure at VMware, Burke has trained hundreds of employees on Orchestrator, built many integrations for customers and partners, and has worked various roles in the VMworld Hands On Labs. Publications include contributing author for VMware vCloud Architecture Toolkit (vCAT), VMware Press 2013 and technical resource for Automating vSphere with VMware vCenter Orchestrator, VMware Press 2012) and VMware vSphere for Dummies, For Dummies 2011.

Christophe Decanini is a Consulting Architect at VMware, Inc., where he started in 2007; currently, he is the technical lead for Orchestration. Based in Gland, Switzerland, Christophe is a global resource supporting customers in their orchestration and automation needs. He has presented orchestration solutions at conferences such as VMworld and is the main contributor of the www.vcoteam.info blog and in the official VMware Orchestrator community. Christophe has reviewed and contributed to books covering vCenter Orchestrator including VMware vCloud Architecture Toolkit. Christophe was awarded the vExpert designation for several years given to the top VMware evangelists in the industry. He has 19 years of experience in IT automation and holds a bachelor’s degree in computer science.

Spas Kaloferov has been a technology professional since 2004 and holds over 30 industry certifications. He studied in Germany and is now living back in Sofia, Bulgaria, where he joined the VMWare family in 2014. While working with many VMware products, his work remains mainly focused on Orchestrator. He has been an Orchestrator contributor not only internally, but also via the VMTN communities and his personal blog: http://kaloferov.com/blog.

www.PacktPub.com

For support files and downloads related to your book, please visit www.PacktPub.com.

Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at [email protected] for more details.

At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.

https://www.packtpub.com/mapt

Get the most in-demand software skills with Mapt. Mapt gives you full access to all Packt books and video courses, as well as industry-leading tools to help you plan your personal development and advance your career.

Why subscribe?

Fully searchable across every book published by PacktCopy and paste, print, and bookmark contentOn demand and accessible via a web browser

Preface

Several things have happened since the first edition of this book. The most important thing is that vRealize Orchestrator 7.1 (vRO) was released and changed a lot with the Control Center; I can see that the next thing would be Orchestrator being used more, last but not least, I released the vRealize Orchestrator Essentials book. It allowed me to remove a lot of beginner stuff from this book and have a greater focus on the more interesting stuff.

The release of vRealize Automation 7.1 (vRA) bought about a lot of changes too, as Orchestrator is now even more integrated into vRA than before.

Tip

If you're completely new to Orchestrator I would suggest that you start your journey with the vRealize Orchestrator Essentials book.

To do so go to http://bit.ly/1KVVara.

Changes in this edition

The following are the changes from the First edition:

We have restructured all chapters and recipesWe have focused on the new Control CenterWe now have complete chapter on Clusters, distributed design, and loadbalancingWe have reworked on all recipes to fit vRO7.1 and vRA7.1We focus on REST and JSONWe have included an chapter on how to use PowerShell, REST, PHP and other methods to interact with Orchestrator workflowsWe have included the NSX, Horizon, Replication, SRM, and VROPS pluginsWe will introduce you to the new vAPIWe have a complete chapter on vRA7.1 integration including Event Broker

A short history of Orchestrator

Orchestrator is VMware's central effort in Automation and Orchestrator.

Orchestrator started its life as Virtual Service Orchestrator (VS-O) with a small company named Dunes in Lausanne, Switzerland. In 2007, VMware bought Dunes, renaming the product as VMware Orchestrator (VMO), and then introduced Orchestrator into vSphere 4.0 as vCenter Orchestrator (vCO). Orchestrator's first stage debut was with VMware Lifecycle Manager, which used Orchestrator to automate the virtual infrastructure life cycle. Orchestrator itself never really received the spotlight until the recent launch of VMware vCloud Automation Center (vCAC). In the beginning, vCAC used Orchestrator only as an extension, but with version 6.1, it became the central tool for automation.

Version 7 replaced the old configuration elements and came up with a fresh and wonderful way to configure things the Control Center. Also, lots of features were reworked on and new ones were made more accessible. The most important step was to reduce the number of Orchestrator installations to two: the Orchestrator appliance and the vRA integrated Orchestrator version.

Note

In October 2014, VMware renamed vCenter Orchestrator (vCO) to vRealize Orchestrator (vRO) to align with their new strategies. vRO is not a new product; it's is just the new name of vCO.

With version 6.2 of vCAC, the product has been renamed to vRealize Automation. We will just refer to it as Orchestrator.

Best approaches to reading this book

As I already said, if you’re a total beginner with Orchestrator, work through the vRealize Orchestrator Essentials book first, which is more like a classroom that starts and develops your starting skills. Also refer to the upgrade link of the vRealize Orchestrator Essentials book (http://langenhan.info/vRO-Essential_update.pdf) for vRO7.

If you plan to use vRealize Automation, it's is best to start with Chapter 13, Working with vRealize Automation , before diving deeper. vRealize Automation just leverages Orchestrator workflows and plugins. Check out Chapter 1, Installing and Configuring Orchestrator .

If you plan to automate your vSphere infrastructure, you can dive straight into Chapter 13, Installing and Configuring Orchestrator , and then check out Chapter 12, Working with vSphere . Then I would start looking at the different plugins.

If you would like to improve your existing skills, check out Chapter 4, Programming Skills , to Chapter 8, Better Workflows and optimized working . 

What this book covers

Chapter 1, Installing and Configuring Orchestrator , shows you how to install, configure, and access Orchestrator.

Chapter 2, Optimizing Orchestrator Configuration , dives into more specialized tasks such as tuning the Orchestrator appliance, changing certificates and dealing with logs.

Chapter 3, Distributed Design,  focuses on Clusters, distributed Orchestrator setups and loadbalancing.

Chapter 4, Programming Skills , contains all the little secrets that you need to know to make Orchestrator programming easier.

Chapter 5, Visual Programming , introduces and dives into the visual programming of Orchestrator.

Chapter 6, Advanced Programming , dives into more advanced operations such complex Java objects, JSON and other items that will add value to your workflows.

Chapter 7, Interacting with Orchestrator , focuses on how to interact with Orchestrator. We will use PowerShell, REST, and PHP to interact with workflows.

Chapter 8, Better Workflows and Optimized Working , dives into resources, configurations, packages, and more for optimizing your workflows.

Chapter 9, Essential Plugins , deals with the most plugins used, such as e-mail, files, SSH and REST.

Chapter 10, Built-in Plugins , dives into all the other plugins that are preinstalled in Orchestrator.

Chapter 11, Additional Plugins , takes a look at NSX, Horizon, Replication, SRM and vROPS plugins.

Chapter 12, Working with vSphere , is a full chapter dedicated to all things vSphere (vCenter).

Chapter 13, Working with vRealize Automation , dives into how to use Orchestrator in vRealize Automation.

What you need for this book

This book covers a lot of ground and discusses the interactions with a lot of other infrastructure services such as Active Directory (AD), e-mail, the vSphere infrastructure, and vRealize Automation.

You can use this book with Orchestrator versions 5.0, 5.1, and 5.5 and with the renamed version, vRealize Orchestrator (5.5.2.x, 6.x, 7.x, and newer).

The requirements differ from chapter to chapter. For Chapter 1, Installing and Configuring Orchestrator , and Chapter 2, Optimizing Orchestrator Configuration , you just require some space on your virtual infrastructure to deploy Orchestrator and maybe a working vCenter. Chapter 3, Distributed Design , requires more space and a loadbalancer or NSX. For Chapter 7, Interacting with Orchestrator , you may need a web server. Chapter 9, Essential Plugins , requires SSH, e-mail and a REST host; however, in the examples we will use easily accessible methods. Chapter 10, Build-in Plugins , is about SQL, PowerShell (Windows host), Active Directory SNMP, and AMQP, so there is some requirement for these services; again, I will provide some easy ways to handle this. Chapter 11, Additional Plugins , deals with NSX, Horizon, Replication, SRM, and vROPS. I will provide links that will help you set them up, but you will need to provide the infrastructure. Chapter 12, Working with vSphere , is about vCenter, and you should have that already. The last Chapter 13, Working with vRealize Automation , is about vRealize Automation. You will need to install and configure it in order to use it. This is much easier and straightforward in vRA7 than in all the other versions.

Some readers might not have all the resources or infrastructure to rebuild or play with some of the recipes; however, I sometimes have been in the same boat. I used the following little mini lab.

My mini lab is a Shuttle XPC-SZ170R8 with an i7 4 GHz and 64 GB using 1 TB SSD and 3 TB HHD.

My base VMs in my domain Mylab.local look like this:

Name

Content

Virtual hardware

Central

AD, DNS, DHCP, MS-SQL 2k14R2, HMail, NFS, SMB, CA, NTP, RabbitMQ

Windows 2 K12R2, 2 vCPU, 8 GB, 40 GB

vCenter

vCenter Appliance

Appliance, 2 vCPU, 8 GB, ~15 GB

vRO

vRealize Orchestrator Appliance

Appliance, 2 vCPU, 6 GB, 12 GB

vRA

vRA Appliance

Appliance, 4 vCPU, 18 GB, 65 GB

IaaS

IaaS server for vRA

Windows 2 K12R2, 2 vCPU, 8GB, 40 GB

NSX

NSX Manager

Appliance, 2 vCPU,16 GB, 60 GB

vROPS

vROPS Appliance

Appliance, 4 vCPU, 16 GB, 270 GB

vLI

vRealize Loginsight

Appliance, 4 vCPU, 8 GB, 530 GB

For the vSphere Replication, SRM, and Horizon recipes I used extra setups.

Tip

The trick is to choose the minimum number of VMs to power on at the same time.

Who this book is for

This book addresses intermediate and advanced VMware enthusiast. You should have some know-how about Orchestrator. An absolute beginner should take a look at the vRealize Orchestrator Essentials book.

Example workflows

All workflows, actions, and so on that you can find in this book are also available for download. The example package that contains more than 140 workflows and actions is available for download. Simply follow these instructions:

Navigate to https://www.packtpub.com/virtualization-and-cloud/vmware-vrealize-orchestrator-cookbook-second-edition. 

Click on Code Files and download the example package.

Follow the recipe, Working with packages, in Chapter 4, Programming Skills , to upload the example package into your Orchestrator.

All example workflows can be found in the Orchestrator Cookbook 2ndEdition folder and the actions can be found in the com.packtpub.Orchestrator-Cookbook2ndEditor modules.

Tip

I have also packed some extras in. Check out the workflow folder Daniels Toolsbox.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or disliked. Reader feedback is important for us as it helps us develop titles that you will really get the most out of.

To send us general feedback, simply e-mail [email protected], and mention the book's title in the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide at www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code 

You can download the example code files for this book from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

You can download the code files by following these steps:

Log in or register to our website using your e-mail address and password.Hover the mouse pointer on the SUPPORT tab at the top.Click on Code Downloads & Errata.Enter the name of the book in the Search box.Select the book for which you're looking to download the code files.Choose from the drop-down menu where you purchased this book from.Click on Code Download.

You can also download the code files by clicking on the Code Files button on the book's webpage at the Packt Publishing website. This page can be accessed by entering the book's name in the Search box. Please note that you need to be logged in to your Packt account.

Once the file is downloaded, please make sure that you unzip or extract the folder using the latest version of:

WinRAR / 7-Zip for WindowsZipeg / iZip / UnRarX for Mac7-Zip / PeaZip for Linux

The code bundle for the book is also hosted on GitHub at https://github.com/PacktPublishing/VMware-vRealize-Orchestrator-Cookbook-Second-Edition. We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!

Downloading the color images of this book 

We also provide you with a PDF file that has color images of the screenshots/diagrams used in this book. The color images will help you better understand the changes in the output. You can download this file from https://www.packtpub.com/sites/default/files/downloads/VMwarevRealizeOrchestratorCookbookSecondEdition_ColorImages.pdf.

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you could report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your book, clicking on the Errata Submission Form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website or added to any list of existing errata under the Errata section of that title.

To view the previously submitted errata, go to https://www.packtpub.com/books/content/support and enter the name of the book in the search field. The required information will appear under the Errata section.

Piracy

Piracy of copyrighted material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works in any form on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at [email protected] with a link to the suspected pirated material.

We appreciate your help in protecting our authors and our ability to bring you valuable content.

Questions

If you have a problem with any aspect of this book, you can contact us at [email protected], and we will do our best to address the problem.

Chapter 1. Installing and Configuring Orchestrator

In this chapter, we explore how to install and configure Orchestrator. We will be looking at the following recipes:

Deploying the Orchestrator applianceImportant Orchestrator settingsConfiguring an external databaseConfiguring external authenticationConnecting to vCenterInstalling pluginsUpdating OrchestratorMoving from Windows to applianceOrchestrator Client and 4K display scaling

Introduction

This chapter is dedicated to the configuration of Orchestrator and discusses how to set the tone for your Orchestrator deployment.

Until vRO 7, there were three different Orchestrator versions that one could use. The Windows-based installation (that was also automatically installed along with vCenter), the appliance, and the vRealize Automation integrated one. In vRO7, only the appliance and the vRealize Automation (vRA) integrated Orchestrator versions are left. All other versions have been discontinued.

If you still have a Windows version, you need to think about moving it to the appliance. Check out the recipe Moving from Windows to appliance in this chapter. You can currently still download and use the vRO 6.0.4 appliance or Windows version, however, you should consider updating.

Before the vRO appliance came along, the configuration of Orchestrator wasn't easy; therefore, not many people really used it. Now, the initial configuration is already done out of the box and people can start using Orchestrator directly without too much fuss. However, if one plans to use Orchestrator in a production environment, it is important to know how to configure it properly.

Licensing

One of the questions that I constantly hear from customers is about licensing of Orchestrator.

Orchestrator is licensed with vCenter or with vRealize Automation, if you own one of them, you own Orchestrator.

With vSphere, you need at least a vSphere Standard license to use Orchestrator. For vRO7, this means you either need vSphere 6 or vRA 7 license numbers. Although Orchestrator is available with the Essentials or Essentials Plus licensing, it operates in Player mode only. This limits your usage to executing existing workflows and prevents you from editing or creating them.

If you want to test Orchestrator you just need to get a vSphere trial license, which you can acquire over the VMware webpage.

vRealize Orchestrator 7 changes

There are huge differences between vRO versions 5.x, 6.x, and 7.x. The first and foremost is that in vRO7 the Configurator has been fully replaced by the new Control Center. The Control Center is an easy tool to use that does all the work of the Configurator and more. Trust me you are going to love it.

The other important thing is that LDAP as an authentication source for Orchestrator is now scheduled to be removed. It's still working with vRO7, but if you are currently using LDAP you need to start thinking about a change.

Speaking of authentication, vRO7 fully supports the vSphere Platform Services Controller architecture and the new vIDM that has been introduced with vSphere 6 and vRealize Automation 7.

The other important changes are in the network section:

HTTP 8280 now forwards to HTTPS 8281HTTPS 8283 is now used for the Orchestrator Control Center

Orchestrator appliance basics

The vRO 7.1 appliance requires the following virtual resources:

CPU

2 vCPU with at least 2.0 GHz

Memory

6 GB

Disk Space

17 GB (1.5 GB thin)

Network

1 x NIC

1 x IP (DHCP possible)

vHardware

Version 7

The only change from the previous Orchestrator versions is that the memory has increased from 3 GB to 4 GB. Please note that this is the base appliance configuration, we will see how to change and improve the performance in the recipe Tuning the appliance that is in Chapter 2, Optimizing Orchestrator Configuration.

The same is true for the following table of Orchestrator limits. These limits are not hard limits and can be changed, we will discuss this in the recipe Control Center titbits in Chapter 2, Optimizing Orchestrator Configuration.

Maximal concurrent connected vCenters

20

Maximal concurrent connected ESXi hosts

1280

Maximal concurrent connected VM

35,000

Maximal concurrent running workflows

300

Last but not least, we have to discuss network security in detail and all the ports that need to be opened for Orchestrator to function. We will expand the list of ports when we start working with plugins, but these are the ones most commonly used:

Orchestrator and vRealize Automation (vRA)

The vRealize Automation (formerly vCloud Automation Center or vCAC) appliance is shipped with a preinstalled and preconfigured vRO. Orchestrator installed on vRA is already configured and works the way the normal Orchestrator appliance does.

The vRA integrated vRO is normally only used for small environments or test environments. If you are deploying vRA for a production, large, or even worldwide role, you should consider using a vRO cluster and/or a distributed Orchestrator design. We will discuss distributed design in more detail in Chapter 3, Distributed Design. We also discuss the vRA integrated appliance in more detail in Working with the vRA integrated Orchestrator in Chapter 13, Working with vRealize Automation.

Deploying the Orchestrator appliance

We will now deploy the Orchestrator appliance based on Linux. If you are using the vRA integrated Orchestrator, see the introduction to Chapter 13, Working with vRealize Automation.

Getting ready

We can deploy the Orchestrator appliance on either a vSphere environment or on a VMware workstation (or Fusion if you are a MAC user).

Have a quick look at the requirements in the introduction of this chapter.

How to do it...

In this recipe, we will learn how to download and deploy Orchestrator. We will configure it in a later recipe.

Download

Navigate to http://vmware.com and select Downloads.Click on Download Product next to VMware vSphere or vRealize Automation.Look for VMware vRealize Orchestrator Appliance 7.1 and click on Go to Downloads.Look for the OVA file and click on Download Now.

Deploy

Log into vCenter using the vSphere Web Client.Right-click on the cluster or ESXi server and select Deploy OVF Template....The Deploy OVF Template wizard starts. Select the OVA file you have downloaded and click Next.Accept the EULA and click Next.Select a name (or accept the default) as well as the vCenter folder for the Orchestrator appliance and click Next.Select the cluster or ESXi server or a resource pool for the Orchestrator appliance and click Next.Select the datastore you would like to deploy the Orchestrator appliance on and click Next.Select a network for the Orchestrator appliance and click Next.In the Customize template section, set a password for the root user.Enable SSH if you wish. This can be done later too. See the recipe Tuning the appliance in the next chapter.If you like, tick to join the Customer Experience Improvement program.Set a Hostname for the Orchestrator appliance.If you want to use a fixed IP, expand the Network Properties section, enter all IP related entries, and then click Next. If you want to use DHCP, just click on Next.Select to power on the VM after deployment and click on Finish.Wait until the VM has finished deploying and is powered on.Open the console of the Orchestrator appliance and wait until the install process has completed and the VM console shows the following screenshot:

Log in to the Orchestrator Client

Open a browser and browse to the IP of the Orchestrator appliance (for example, http://192.168.220.12).Depending on your environment, you might need to accept the SSL certificate. You are now on the Orchestrator home page with several useful links to all important Orchestrator topics:To open up the Orchestrator Client, click on Start Orchestrator Client.Enter vcoadmin as user and vcoadmin as the password.

You are now logged into the Orchestrator Client.

Log into Control Center

Some of the next recipes need us to log into Control Center, here is how to do that:

On the Orchestrator Home page click on Orchestrator Control Center.Enter the user root and the password you assigned during deployment.

How it works...

The Orchestrator appliance is a preconfigured Orchestrator installation that uses the following software:

SUSE Linux Enterprise Server (SLES) 11 Patch level 3VMware-Postgres 9.4.5.0ApacheDS LDAP 2.4.42

Everything is ready to run; however, no integration with vCenter or any external service is configured. The Orchestrator appliance comes with a 90-day evaluation license installed.

There's more...

If you want to deploy the Orchestrator appliance on VMware Workstation, the process of deploying the Orchestrator appliance differs from the one described in this recipe. Follow these steps instead:

Use Windows Explorer to navigate to the downloaded .ova file.Double-click on the OVA file. VMware workstation opens up.Select a name and a path for the new VM and click on Import.Accept the EULA and wait until the VM is deployed.You might need to select a different network (for example, Host-Only) depending on your lab environment.Power on the VM and wait until the install pauses at the line indicated in this screenshot:Enter and confirm a new password for the root account.The installation will now continue. Wait until it has finished.

The appliance will start with a DHCP address from the workstation. To set a static IP, you will have to access the admin interface of the appliance.

See also

Important Orchestrator settings

The following is a small collection of things that one should do or at least know how to do. It includes licensing, certificates, and virtual hardware.

Getting ready

We just need a working Orchestrator as well as access to the Control Center.

How to do it...

There are several things you should do or at least know how to do.

Starting, stopping, and restarting the Orchestrator service

These are operations that have to be done quite often, so it's best to know how to do them:

Open Control Center and click on Startup Options.You can see the current status of the Orchestrator service.Click on one of the action buttons.After choosing an action, wait until the status has changed.

Licensing

You can either enter a license key manually or connect to the vCenter Server or vRealize Automation to acquire the license.

Tip

If you are planning to use vSphere or vRealize Automation as an external authentication, you can skip this step as the licensing will be configured automatically.

If you change the database, you will need to redo the licensing:

Open Control Center and click on Licensing.If you have an authentication provider configured (vSphere or VRA) then you can select vSphere License.If you used SSO or LDAP, you need to use Manual License. With vRO7 you will need to enter a vSphere 6 vCenter or vRealize Automation 7 License number.Click on Save.

Package Signing Certificate

The Packaging Signing Certificate signs all packages or exports. One is automatically generated with the Orchestrator's VMs Hostname. We will now show how to create a custom one: