Clone Virtual Machine: Service details

Ops Center Automator User Guide

Version
11.0.x
Audience
anonymous
Part Number
MK-99AUT001-22

This service template creates a clone of a virtual server in the VMware vSphere environment.

The general steps for using this service template to clone a virtual machine are as follows:

  1. Obtain the power status of the virtual server to clone.
  2. Make sure the power status of the virtual server is OFF.
    1. If the power status is not OFF, you can use the User-Response Wait Plug-in to confirm whether to turn the power OFF.
    2. Users with Modify permission can set the e-mail destination/message text, timeout, and display contents through the User-Response Wait Plug-in.
    3. You can use "Shutdown" for the wait-for-user response, to shut the virtual server down. Before shutting down the virtual server, the system waits the number of seconds specified in the power status confirmation frequency property vmware.checkPowerStateInterval to confirm that the power has been turned OFF and repeats that until it is confirmed or repeats according to the number of times specified in the power status confirmation retries property vmware.checkPowerStateCount. Adjust the value of each property according to the environment.
    4. If the user selects "Cancel" or if a timeout occurs while waiting for a user response, the server ends abnormally without operating the virtual server.
  3. The virtual server to clone is used to create a clone.
    1. When creating a clone, a set of parameters (ESX server, resource pool, data store, and virtual disk format) can be specified.
    2. If no resource pool is specified, the clone is created directly under the destination ESX server where the clone is created.
    3. The maximum length of the virtual server name property vmware.vmName and clone name property (vmware.cloneName) is 60 characters.

Service Definition Properties

The following table lists the properties shown in the Service Definition window for the Clone Virtual Machine service template.

Property Key Property Name Description Required or optional
vmware.targetHost Host name of VMware vCenter control server Specify the host name or IP address of the server (a server with vSphere PowerCLI installed) that will be used to control VMware vCenter. You cannot specify an IPv6 address. R
vmware.vCenterServerName VMware vCenter server name Specify the host name or IP address of the VMware vCenter server. You cannot specify an IPv6 address. R
vmware.userName User name for VMware vCenter Server connection Specify the user name to use when connecting to the VMware vCenter server. R
vmware.password Password for VMware vCenter Server connection Specify the password to use when connecting to the VMware vCenter server. R
vmware.portNumber Port number for VMware vCenter Server connection Specify the port number to use when connecting to the VMware vCenter server (specifically, the port number of the VMware vCenter server's Web service). If you omit this property, the default value of the VMware vCenter server applies. O
vmware.protocol Protocol for VMware vCenter Server connection Specify the protocol to use when connecting to the VMware vCenter server. R
UserResponsePlugin.toAddress TO addresses Specify the email addresses to enter in the TO field of notification emails sent when the service is waiting for a user response. Separate multiple addresses with commas. Example: mailA,mailB O
UserResponsePlugin.ccAddress CC addresses Specify the email addresses to enter in the CC field of notification emails sent when the service is waiting for a user response. Separate multiple addresses with commas. Example: mailA,mailB O
UserResponsePlugin.bccAddress BCC addresses Specify the email addresses to enter in the BCC field of notification emails sent when the service is waiting for a user response. Separate multiple addresses with commas. Example: mailA,mailB O
UserResponsePlugin.mailSubject Subject line Specify the subject line of notification emails sent when the service is waiting for a user response. O
UserResponsePlugin.mailBody Email text Specify the body text of notification emails sent when the service is waiting for a user response. O
UserResponsePlugin.encodeType Encoding Specify the encoding of notification emails sent when the service is waiting for a user response. The encodings you can specify are us-ascii, iso-2022-jp, shift_jis, euc-jp, and utf-8. If you omit this property, utf-8 is set. O
UserResponsePlugin.dialogText Additional dialog box text Enter additional text to appear in the response input dialog box, in text or HTML format. Supported HTML tags are anchor tags, bold tags, break tags, font tags, italics tags, and underline tags. O
UserResponsePlugin.responseTimeOut Response timeout time (minutes) Specify how long (in minutes) the service waits for a user response before timing out. In the event of a response timeout, the service will end abnormally. R
vmware.checkPowerStateCount Number of power status confirmation retries Specify the number of times the service tries to verify the power status to confirm that the virtual server has started. The maximum wait time is determined by this property and the property that defines the power status verification interval. R
vmware.checkPowerStateInterval Frequency of power status confirmation retries Specify the interval at which the service tries to acquire the power status to confirm that the virtual server has started. R

Service Definition and Submit Service Properties

The following table lists the properties visible in the Service Definition and Submit Service windows for the Clone Virtual Machine service template.

Property Key Property Name Description Required or optional
vmware.cloneName Clone name Specifies the name of a clone. (This is the display name of a clone under VMware vCenter Server. It is not a host name under the OS.) R
vmware.vmName Virtual server name Specify the name of a virtual server as the cloning source. (This is the display name of a virtual server under VMware vCenter Server. It is not a host name under the OS.) R
vmware.vmHostName ESX server name Specify the ESX server name visible in the Hosts and Clusters inventory view managed by VMware vCenter Server, which serves as the cloning destination. R
vmware.dataStoreName Datastore name Specify the name of a data store as the cloning destination. R
vmware.resourcePoolName Resource pool name Specify a resource pool or cluster as the cloning destination. O
vmware.diskFormat Virtual disk format Specifies format of the virtual disk of the clone to be created. Specify "Default" when the format is the same as the virtual disk of the virtual server of the clone source, "Thin" when committing it on demand, or "Thick" when committing it in full size. R
Note: Although some of the properties in the tables indicate that they can be omitted, they might be required when used in conjunction with some other property setting as indicated in the descriptions.

Prerequisites

The following conditions must be met:

  • VMware vSphere ESXi (or VMware ESX Server) is managed by VMware vCenter Server.
  • No duplicate clone names can be under the same vCenter. No duplicate clone name is the same as an existing virtual server name.
  • No duplicate data store name can be under the same vCenter.
  • VMware Tools is installed in the virtual server to be cloned.
  • The version of VMware vSphere ESXi (or VMware ESX Server) managing the virtual server to be cloned matches that of VMware vSphere ESXi (or VMware ESX Server) managing the cloning destination.

Server requirements

To use this service template, the following servers are needed:

  • vCenter server: This is a server on which VMware vCenter Server is installed.
  • vCenter control server: This is a server on which VMware vSphere PowerCLI is installed.
  • Virtual server to be cloned: Virtual server managed by vCenter server or VMware vSphere ESXi (or VMware ESX Server).
  • Clone: Clone of the virtual server to be cloned. The clone name is the name of the virtual server clone.

Software requirements

One of the following is required:

  • VMware vSphere PowerCLI 6.3 Release1, 6.0 Release3, 6.0 Release1
  • VMware PowerCLI 6.5 Release1
  • VMware PowerCLI 6.5.1, 6.5.4
  • VMware PowerCLI 10.1.0, 10.1.1

Usage guidelines

  • Do not run multiple instances of this service on the same virtual server at the same time.
  • Do not use a different service to operate the virtual server source or destination of cloning during cloning. Also, do not operate the virtual servers directly from the vCenter server. The service can fail.
  • HTML tags can be specified in the additional information property UserResponseplugin.dialogText in the window for entering a response. The property accepts the same tags and attributes as those available in the User-Response Wait Plug-in. For details, see "User-Response Wait Plug-in" in the Hitachi Ops Center Automator Service Builder User Guide.
  • vAPP cannot be specified as the destination of cloning.
  • Do not start the new clone. To start a created clone, you must delete or restore the cloned virtual server.