com.vmware.vcenter package¶
Subpackages¶
- com.vmware.vcenter.compute package
- com.vmware.vcenter.deployment package
- com.vmware.vcenter.hvc package
- com.vmware.vcenter.storage package
- com.vmware.vcenter.vcha package
- com.vmware.vcenter.vm package
Submodules¶
com.vmware.vcenter.compute_client module¶
The com.vmware.vcenter.compute_client module provides classes for managing
compute policies.
-
class
com.vmware.vcenter.compute_client.Policies(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Policiesclass provides methods to manage compute policies. A compute policy defines the intended behavior for a collection of vSphere objects identified by a tag. A compute policy is an instance of a capability. It is created by providing a value for the creation type specified by the capability. Seecom.vmware.vcenter.compute.policies_client.Capabilities.Info.create_spec_type. Warning: This class is available as technical preview. It may be changed in a future release.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
RESOURCE_TYPE= 'com.vmware.vcenter.compute.Policy'¶ The resource type for the compute policy. Warning: This class attribute is available as technical preview. It may be changed in a future release.
-
class
Summary(policy=None, name=None, description=None, capability=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Policies.Summaryclass contains commonly used information about a compute policy. Warning: This class is available as technical preview. It may be changed in a future release.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - policy (
str) – Identifier of the policy. Warning: This attribute is available as technical preview. It may be changed in a future release. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.compute.Policy. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.compute.Policy. - name (
str) – Name of the policy. Warning: This attribute is available as technical preview. It may be changed in a future release. - description (
str) – Description of the policy. Warning: This attribute is available as technical preview. It may be changed in a future release. - capability (
str) – Identifier of the capability this policy is based on. Warning: This attribute is available as technical preview. It may be changed in a future release. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.compute.policies.Capability. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.compute.policies.Capability.
- policy (
-
create(spec)¶ Creates a new compute policy. Warning: This method is available as technical preview. It may be changed in a future release.
Parameters: spec (
vmware.vapi.struct.VapiStruct) – Specification for the new policy to be created. The new policy will be an instance of the capability that has the creation type (seecom.vmware.vcenter.compute.policies_client.Capabilities.Info.create_spec_type) equal to the type of the specified value (seespec). The parameter must contain all the attributes defined incom.vmware.vcenter.compute.policies_client.CreateSpec.Return type: strReturns: The identifier of the newly created policy. Use this identifier to get or destroy the policy. The return value will be an identifier for the resource type:
com.vmware.vcenter.compute.Policy.Raise: com.vmware.vapi.std.errors_client.AlreadyExistsif a policy with the same name is already present on this vCenter server.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif a parameter passed in the spec is invalid.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif more than 100 policies are created.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
ComputePolicy.Manage.
- Method execution requires
-
delete(policy)¶ Deletes a specific compute policy. Warning: This method is available as technical preview. It may be changed in a future release.
Parameters: policy (
str) – Identifier of the policy to be deleted. The parameter must be an identifier for the resource type:com.vmware.vcenter.compute.Policy.Raise: com.vmware.vapi.std.errors_client.NotFoundif a policy with this identifier does not exist.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
ComputePolicy.Manage.
- Method execution requires
-
get(policy)¶ Returns information about a specific compute policy. Warning: This method is available as technical preview. It may be changed in a future release.
Parameters: policy (
str) – Identifier of the policy for which information should be retrieved. The parameter must be an identifier for the resource type:com.vmware.vcenter.compute.Policy.Return type: vmware.vapi.struct.VapiStructReturns: Detailed information about the specified compute policy. The returned value can be converted to the information type of the capability that this policy is based on. See
com.vmware.vcenter.compute.policies_client.Capabilities.Info.info_type. The return value will contain all the attributes defined incom.vmware.vcenter.compute.policies_client.Info.Raise: com.vmware.vapi.std.errors_client.NotFoundif a policy with this identifier does not exist.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read.
- Method execution requires
-
list()¶ Returns information about the compute policies available in this vCenter server. Warning: This method is available as technical preview. It may be changed in a future release.
Return type: Returns: The list of compute policies available on this vCenter server.
Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read.
- Method execution requires
-
-
class
com.vmware.vcenter.compute_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.datastore_client module¶
-
class
com.vmware.vcenter.datastore_client.DefaultPolicy(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
DefaultPolicyclass provides methods related to storage policies associated with datastore object. TheDefaultPolicy.get()method provides information about the default storage policy associated with the specific datastore. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
get(datastore)¶ Returns the identifier of the current default storage policy associated with the specified datastore. This method was added in vSphere API 6.7.
Parameters: datastore ( str) – Identifier of the datastore for which the default policy is requested. The parameter must be an identifier for the resource type:Datastore.Return type: strorNoneReturns: Identifier of the default storage policy associated with the specified datastore. The return value will be an identifier for the resource type: com.vmware.vcenter.StoragePolicy. this field is None if there is no default storage policy associated with the datastore.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the specified datastore does not exist.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user does not have the required priveleges.
-
-
class
com.vmware.vcenter.datastore_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.deployment_client module¶
-
class
com.vmware.vcenter.deployment_client.ApplianceState(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
ApplianceStateclass defines the various states the vCenter Appliance can be in. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theApplianceStateinstance.-
CONFIGURED= ApplianceState(string='CONFIGURED')¶ The appliance has been configured. This class attribute was added in vSphere API 6.7.
-
CONFIG_IN_PROGRESS= ApplianceState(string='CONFIG_IN_PROGRESS')¶ The appliance is in the process of being configured. This class attribute was added in vSphere API 6.7.
-
FAILED= ApplianceState(string='FAILED')¶ The appliance configuration has failed. This class attribute was added in vSphere API 6.7.
-
INITIALIZED= ApplianceState(string='INITIALIZED')¶ The appliance is initialized and ready to be configured. This class attribute was added in vSphere API 6.7.
-
NOT_INITIALIZED= ApplianceState(string='NOT_INITIALIZED')¶ The appliance is in the process of being initialized and not ready for configuration. This class attribute was added in vSphere API 6.7.
-
QUESTION_RAISED= ApplianceState(string='QUESTION_RAISED')¶ The deployment script has raised a question and is waiting for an answer to continue with the appliance configuration. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.deployment_client.ApplianceType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
ApplianceTypeclass defines the vCenter appliance types. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theApplianceTypeinstance.-
PSC_EXTERNAL= ApplianceType(string='PSC_EXTERNAL')¶ An external Platform Services Controller. This class attribute was added in vSphere API 6.7.
-
VCSA_EMBEDDED= ApplianceType(string='VCSA_EMBEDDED')¶ vCenter Server Appliance with an embedded Platform Services Controller. This class attribute was added in vSphere API 6.7.
-
VCSA_EXTERNAL= ApplianceType(string='VCSA_EXTERNAL')¶ vCenter Server Appliance with an external Platform Services Controller. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.deployment_client.CheckInfo(status=None, result=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CheckInfoclass describes the result of the appliance deployment check. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - status (
CheckStatus) – Status of the check. This attribute was added in vSphere API 6.7. - result (
NotificationsorNone) – Result of the check. This attribute was added in vSphere API 6.7. This attribute will be None if result is not available at the current step of the task.
- status (
-
class
com.vmware.vcenter.deployment_client.CheckStatus(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
CheckStatusclass defines the status of the checks. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theCheckStatusinstance.-
FAILED= CheckStatus(string='FAILED')¶ A fatal error was encountered when running the sanity checks. This class attribute was added in vSphere API 6.7.
-
SUCCESS= CheckStatus(string='SUCCESS')¶ All checks have completed successfully. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.deployment_client.HistoryMigrationOption(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
HistoryMigrationOptionclass defines the vCenter history migration option choices. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theHistoryMigrationOptioninstance.-
ALL= HistoryMigrationOption(string='ALL')¶ All history data will be migrated along with the core data. This class attribute was added in vSphere API 6.7.
-
EVENTS_TASKS= HistoryMigrationOption(string='EVENTS_TASKS')¶ Only event data and task data will be migrated along with the core data. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.deployment_client.HistoryMigrationSpec(data_set=None, defer_import=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
HistoryMigrationSpecclass defines how vCenter history data will be migrated. vCenter History data includes- Statistics
- Events
- Tasks
. This class was added in vSphere API 6.7.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - data_set (
HistoryMigrationOption) – Defines what part of vCenter historical data will be migrated along with core data. This attribute was added in vSphere API 6.7. - defer_import (
boolorNone) – Defines how vCenter history will be migrated. If set to true, vCenter history will be migrated separately after successful upgrade or migration, otherwise it will be migrated along with core data during the upgrade or migration process. This attribute was added in vSphere API 6.7. If None, vCenter historical data won’t be deferred and will be migrated along with core data.
-
class
com.vmware.vcenter.deployment_client.ImportHistory(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
ImportHistoryclass provides methods for managing the import of vCenter historical data, e.g. Tasks, Events and Statistics, when is is imported separately from the upgrade or migration process. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
CreateSpec(name=None, description=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ImportHistory.CreateSpecclass contains information to create and start vCenter historical data lazy-import. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
str) – Name of the vCenter history import task. This attribute was added in vSphere API 6.7. - description (
str) – Description of the vCenter history import task. This attribute was added in vSphere API 6.7.
- name (
-
class
Info(progress=None, result=None, description=None, service=None, operation=None, parent=None, target=None, status=None, cancelable=None, error=None, start_time=None, end_time=None, user=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ImportHistory.Infoclass contains attributes to describe the state of vCenter history import task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - progress (
com.vmware.cis.task_client.Progress) – The progress info of this task. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value of#statusis one ofcom.vmware.cis.task_client.Status.RUNNING,com.vmware.cis.task_client.Status.FAILED,com.vmware.cis.task_client.Status.BLOCKED, orcom.vmware.cis.task_client.Status.SUCCEEDED. - result (
NotificationsorNone) – Result of the operation. If an operation reports partial results before it completes, this attribute could besetbefore the null has the value null. The value could change as the operation progresses. This attribute was added in vSphere API 6.7. This attribute will be None if result is not available at the current step of the operation. - description (
com.vmware.vapi.std_client.LocalizableMessage) – Description of the operation associated with the task. - service (
str) – Identifier of the service containing the operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.service. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.service. - operation (
str) – Identifier of the operation associated with the task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.operation. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.operation. - parent (
strorNone) – Parent of the current task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.cis.task. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.cis.task. This attribute will be None if the task has no parent. - target (
com.vmware.vapi.std_client.DynamicIDorNone) – Identifier of the target created by the operation or an existing one the operation performed on. This attribute will be None if the operation has no target or multiple targets. - status (
com.vmware.cis.task_client.Status) – Status of the operation associated with the task. - cancelable (
bool) – Flag to indicate whether or not the operation can be cancelled. The value may change as the operation progresses. - error (
ExceptionorNone) – Description of the error if the operation status is “FAILED”. If None the description of why the operation failed will be included in the result of the operation (seecom.vmware.cis.task_client.Info.result). - start_time (
datetime.datetime) – Time when the operation is started. This attribute is optional and it is only relevant when the value ofstatusis one ofcom.vmware.cis.task_client.Status.RUNNING,com.vmware.cis.task_client.Status.BLOCKED,com.vmware.cis.task_client.Status.SUCCEEDED, orcom.vmware.cis.task_client.Status.FAILED. - end_time (
datetime.datetime) – Time when the operation is completed. This attribute is optional and it is only relevant when the value ofstatusis one ofcom.vmware.cis.task_client.Status.SUCCEEDEDorcom.vmware.cis.task_client.Status.FAILED. - user (
strorNone) – Name of the user who performed the operation. This attribute will be None if the operation is performed by the system.
- progress (
-
cancel()¶ Cancels the task for importing vCenter historical data. This method was added in vSphere API 6.7.
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the caller is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif vCenter historical data import task cannot be canceled at this state. This can happen in the following cases:- If historical data import has not been started yet because a not running task cannot be canceled
- If historical data import has already been completed because a completed task cannot be canceled
Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif vCenter historical data import task is already canceled.Raise: com.vmware.vapi.std.errors_client.ErrorGeneric error.
-
get()¶ Get the current status of the vCenter historical data import. This method was added in vSphere API 6.7.
Return type: ImportHistory.InfoReturns: Info structure containing the status information about the historical data import status. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the caller is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.ErrorGeneric error
-
pause()¶ Pauses the task for importing vCenter historical data. This method was added in vSphere API 6.7.
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the caller is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif vCenter historical data import task cannot be paused at this time. Pause can be accepted only in null stateRaise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif vCenter historical data import task is already pausedRaise: com.vmware.vapi.std.errors_client.ErrorGeneric error
-
resume()¶ Resumes the task for importing vCenter historical data. This method was added in vSphere API 6.7.
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the caller is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif vCenter historical data import task cannot be resumed at this state. Resume can be accepted only in null stateRaise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif vCenter historical data import task is already resumed.Raise: com.vmware.vapi.std.errors_client.ErrorGeneric error.
-
start(spec=None)¶ Creates and starts task for importing vCenter historical data. This method was added in vSphere API 6.7.
Parameters: spec (
ImportHistory.CreateSpecorNone) –An optional
ImportHistory.CreateSpecinfo that can be passed for creating a new historical data import task and starts it. If None, default value will be:- name : vcenter.deployment.history.import
- description : vCenter Server history import
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the caller is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif vCenter historical data import task cannot be started at this time. This can happen in the following cases:- If historical data import has already been canceled because a canceled task cannot be re-started
- If historical data import has already been completed because a completed task cannot be re-started
- If historical data import has already been paused because a paused task can only be resumed or canceled
Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif vCenter historical data import task has already being started.Raise: com.vmware.vapi.std.errors_client.ErrorGeneric error
-
class
-
class
com.vmware.vcenter.deployment_client.Install(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Installclass provides methods to configure the installation of the appliance. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
InstallSpec(vcsa_embedded=None, psc=None, vcsa_external=None, auto_answer=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Install.InstallSpecclass contains information used to configure the appliance installation. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - vcsa_embedded (
Install.VcsaEmbeddedSpecorNone) – Spec used to configure an embedded vCenter Server. This field describes how the embedded vCenter Server appliance should be configured. This attribute was added in vSphere API 6.7. If None, will not configure this appliance as Embedded vCenter Server. If None, eithervcsaExternalorpscmust be provided. - psc (
Install.PscSpecorNone) – Spec used to configure a Platform Services Controller. This field describes how the Platform Services Controller appliance should be configured. This attribute was added in vSphere API 6.7. If None, will not configure this appliance as Platform Services Controller. If None, eithervcsaEmbeddedorvcsaExternalmust be provided. - vcsa_external (
RemotePscSpecorNone) – Spec used to configure a vCenter Server registered with an external PSC. This fields represent the remote external PSC that the configuring vCenter Server will be registering with. This attribute was added in vSphere API 6.7. If None, will not configure this appliance as external vCenter Server. If None, eithervcsaEmbeddedorpscmust be provided. - auto_answer (
boolorNone) – Use the default option for any questions that may come up during appliance configuration. This attribute was added in vSphere API 6.7. If None, will default to false.
- vcsa_embedded (
-
class
PscSpec(standalone=None, replicated=None, ceip_enabled=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Install.PscSpecclass contains information used to configure a standalone or replicated PSC. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - standalone (
StandalonePscSpecorNone) – Spec used to configure a standalone Platform Services Controller. This field describes how the standalone PSC should be configured. This attribute was added in vSphere API 6.7. If None, will default to None. - replicated (
ReplicatedPscSpecorNone) – Spec used to configure a replicated Platform Services Controller. This field describes how the replicated PSC should be configured. This attribute was added in vSphere API 6.7. If None, will default to None. - ceip_enabled (
bool) – Customer experience improvement program should be enabled or disabled. This attribute was added in vSphere API 6.7.
- standalone (
-
class
VcsaEmbeddedSpec(standalone=None, replicated=None, ceip_enabled=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Install.VcsaEmbeddedSpecclass contains information used to configure an embedded standalone or replicated vCenter Server. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - standalone (
StandaloneSpecorNone) – Spec used to configure a standalone embedded vCenter Server. This field describes how the standalone vCenter Server appliance should be configured. This attribute was added in vSphere API 6.7. If None, will default to None. - replicated (
ReplicatedSpecorNone) – Spec used to configure a replicated embedded vCenter Server. This field describes how the replicated vCenter Server appliance should be configured. This attribute was added in vSphere API 6.7. If None, will default to None. - ceip_enabled (
bool) – Whether CEIP should be enabled or disabled. This attribute was added in vSphere API 6.7.
- standalone (
-
cancel()¶ Cancel the appliance installation that is in progress. This method was added in vSphere API 6.7.
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in CONFIG_IN_PROGRESS state and if the operation is not INSTALL.
-
check(spec)¶ Run sanity checks using the InstallSpec parameters passed. This method was added in vSphere API 6.7.
Parameters: spec ( Install.InstallSpec) – InstallSpec parameters to run sanity check with.Return type: CheckInfoReturns: CheckInfo containing the check results. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif external PSC credentials are not valid when configuring PSC to replicate with an external existing PSC.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif external PSC credentials are not valid when configuring a VCSA_EXTERNAL appliance.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in INITIALIZED state.
-
get()¶ Get the parameters used to configure the ongoing appliance installation. This method was added in vSphere API 6.7.
Return type: Install.InstallSpecReturns: InstallSpec parameters being used to configure appliance install. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif appliance is not in INSTALL_PROGRESS state.
-
start(spec)¶ Start the appliance installation. This method was added in vSphere API 6.7.
Parameters: spec ( Install.InstallSpec) – InstallSpec parameters to configure the appliance install.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the partner PSC credentials are not valid when configuring PSC to replicate with partner PSC.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif external PSC credentials are not valid when configuring a VCSA_EXTERNAL appliance.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in INITIALIZED state.
-
class
-
class
com.vmware.vcenter.deployment_client.LocationSpec(hostname=None, https_port=None, ssl_thumbprint=None, ssl_verify=None, username=None, password=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LocationSpecclass is used to pass the container ESXi or vCenter server of the VM to patch the size of this appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - hostname (
str) – The IP address or DNS resolvable name of the container. This attribute was added in vSphere API 6.7. - https_port (
longorNone) – The HTTPS port of the container. This attribute was added in vSphere API 6.7. If None, port 443 will be used. - ssl_thumbprint (
strorNone) – SHA1 thumbprint of the server SSL certificate will be used for verification. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsslVerifyis None or has the value true. - ssl_verify (
boolorNone) – SSL verification should be enabled or disabled. IfsslVerifyis true and andsslThumbprintis None, the CA certificate will be used for verification. IfsslVerifyis true andsslThumbprintis set then the thumbprint will be used for verification. No verification will be performed ifsslVerifyvalue is set to false. This attribute was added in vSphere API 6.7. If None, ssl_verify true will be used. - username (
str) – The administrator account on the host. This attribute was added in vSphere API 6.7. - password (
str) – The administrator account password. This attribute was added in vSphere API 6.7.
- hostname (
-
class
com.vmware.vcenter.deployment_client.Notification(id=None, time=None, message=None, resolution=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Notificationclass contains attributes to describe any info/warning/error messages that Tasks can raise. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - id (
str) – The notification id. This attribute was added in vSphere API 6.7. - time (
datetime.datetimeorNone) – The time the notification was raised/found. This attribute was added in vSphere API 6.7. Onlysetif the time information is available. - message (
com.vmware.vapi.std_client.LocalizableMessage) – The notification message. This attribute was added in vSphere API 6.7. - resolution (
com.vmware.vapi.std_client.LocalizableMessageorNone) – The resolution message, if any. This attribute was added in vSphere API 6.7. Onlysetfor warnings and errors.
- id (
-
class
com.vmware.vcenter.deployment_client.Notifications(info=None, warnings=None, errors=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Notificationsclass contains info/warning/error messages that can be reported be the task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - info (
listofNotificationorNone) – Info notification messages reported. This attribute was added in vSphere API 6.7. Onlysetif an info was reported by the task. - warnings (
listofNotificationorNone) – Warning notification messages reported. This attribute was added in vSphere API 6.7. Onlysetif an warning was reported by the task. - errors (
listofNotificationorNone) – Error notification messages reported. This attribute was added in vSphere API 6.7. Onlysetif an error was reported by the task.
- info (
-
class
com.vmware.vcenter.deployment_client.Operation(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Operationclass defines the supported vCenter appliance deployment operations. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theOperationinstance.-
INSTALL= Operation(string='INSTALL')¶ The appliance installation is in progress. This class attribute was added in vSphere API 6.7.
-
MIGRATE= Operation(string='MIGRATE')¶ The appliance migration is in progress. This class attribute was added in vSphere API 6.7.
-
RESTORE= Operation(string='RESTORE')¶ The appliance restoration is in progress. This class attribute was added in vSphere API 6.7.
-
ROLLBACK= Operation(string='ROLLBACK')¶ The appliance is being rolled back to an unconfigured state. This class attribute was added in vSphere API 6.7.
-
UPGRADE= Operation(string='UPGRADE')¶ The appliance upgrade is in progress. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.deployment_client.Question(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Questionclass provides methods to get the question raised during deployment and to answer them. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
AnswerSpec(question_id=None, answer_val=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Question.AnswerSpecclass contains attributes to describe the answer to a raised question. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - question_id (
str) – Id of the question being answered. This attribute was added in vSphere API 6.7. - answer_val (
str) – The answer value. This attribute was added in vSphere API 6.7.
- question_id (
-
class
Info(questions=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Question.Infoclass contains attributes to describe questions raised during the deployment process. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: questions ( listofQuestion.Question) – One or more questions raised during the deployment. This attribute was added in vSphere API 6.7.
-
class
Question(id=None, question=None, type=None, default_answer=None, possible_answers=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Question.Questionclass contains attributes to describe a deployment question. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - id (
str) – Id of the question raised. This attribute was added in vSphere API 6.7. - question (
com.vmware.vapi.std_client.LocalizableMessage) – Message describing the question. This attribute was added in vSphere API 6.7. - type (
Question.QuestionType) – Type of the question raised. This attribute was added in vSphere API 6.7. - default_answer (
str) – Default answer value. This attribute was added in vSphere API 6.7. - possible_answers (
listofstr) – Possible answers values. This attribute was added in vSphere API 6.7.
- id (
-
class
QuestionType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Question.QuestionTypeclass defines the type of the question raised. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theQuestionTypeinstance.-
ABORT_RETRY_IGNORE= QuestionType(string='ABORT_RETRY_IGNORE')¶ Question with answer values Abort/Retry/Ignore. This class attribute was added in vSphere API 6.7.
-
OK_CANCEL= QuestionType(string='OK_CANCEL')¶ Question with answer values Ok/Cancel. This class attribute was added in vSphere API 6.7.
-
YES_NO= QuestionType(string='YES_NO')¶ Question with answer values Yes/No. This class attribute was added in vSphere API 6.7.
-
-
answer(spec)¶ Supply answer to the raised question. This method was added in vSphere API 6.7.
Parameters: spec ( Question.AnswerSpec) – AnswerSpec with the answer to the raised question.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is NOT in QUESTION_RAISED state.Raise: com.vmware.vapi.std.errors_client.InternalServerErrorif answer file could not be created.
-
get()¶ Get the question that was raised during the configuration. This method was added in vSphere API 6.7.
Return type: Question.InfoReturns: Info structure containing the question. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in QUESTION_RAISED state.Raise: com.vmware.vapi.std.errors_client.InternalServerErrorif questions could not be retrieved although the appliance is in QUESTION_RAISED state.
-
class
-
class
com.vmware.vcenter.deployment_client.RemotePscSpec(psc_hostname=None, https_port=None, sso_admin_password=None, ssl_thumbprint=None, ssl_verify=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
RemotePscSpecclass contains information used to configure an external vCenter Server that registers with a remote PSC. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - psc_hostname (
str) – The IP address or DNS resolvable name of the remote PSC to which this configuring vCenter Server will be registered to. This attribute was added in vSphere API 6.7. - https_port (
longorNone) – The HTTPS port of the external PSC appliance. This attribute was added in vSphere API 6.7. If None, port 443 will be used. - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - ssl_thumbprint (
strorNone) – SHA1 thumbprint of the server SSL certificate will be used for verification when ssl_verify field is set to true. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsslVerifyis None or has the value true. - ssl_verify (
boolorNone) – SSL verification should be enabled or disabled. IfsslVerifyis true and andsslThumbprintis None, the CA certificate will be used for verification. IfsslVerifyis true andsslThumbprintis set then the thumbprint will be used for verification. No verification will be performed ifsslVerifyvalue is set to false. This attribute was added in vSphere API 6.7. If None,sslVerifytrue will be used.
- psc_hostname (
-
class
com.vmware.vcenter.deployment_client.ReplicatedPscSpec(sso_site_name=None, partner_hostname=None, https_port=None, sso_admin_password=None, ssl_thumbprint=None, ssl_verify=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ReplicatedPscSpecclass contains information used to check if the configuring PSC can be replicated to the remote PSC. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - sso_site_name (
strorNone) – The SSO sitename that will be used in PSC replication. This attribute was added in vSphere API 6.7. If None, default-first-site will be used. - partner_hostname (
str) – The IP address or DNS resolvable name of the partner PSC appliance. This attribute was added in vSphere API 6.7. - https_port (
longorNone) – The HTTPS port of the external PSC appliance. This attribute was added in vSphere API 6.7. If None, port 443 will be used. - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - ssl_thumbprint (
strorNone) – SHA1 thumbprint of the server SSL certificate will be used for verification. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsslVerifyis None or has the value true. - ssl_verify (
boolorNone) – SSL verification should be enabled or disabled. This attribute was added in vSphere API 6.7. If None, ssl_verify true will be used.
- sso_site_name (
-
class
com.vmware.vcenter.deployment_client.ReplicatedSpec(partner_hostname=None, https_port=None, sso_admin_password=None, ssl_thumbprint=None, ssl_verify=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ReplicatedSpecclass contains information used to check if the configuring vCenter Server can be replicated to the remote PSC. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - partner_hostname (
str) – The IP address or DNS resolvable name of the partner PSC appliance. This attribute was added in vSphere API 6.7. - https_port (
longorNone) – The HTTPS port of the external PSC appliance. This attribute was added in vSphere API 6.7. If None, port 443 will be used. - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - ssl_thumbprint (
strorNone) – SHA1 thumbprint of the server SSL certificate will be used for verification. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsslVerifyis None or has the value true. - ssl_verify (
boolorNone) – SSL verification should be enabled or disabled. This attribute was added in vSphere API 6.7. If None, ssl_verify true will be used.
- partner_hostname (
-
class
com.vmware.vcenter.deployment_client.StandalonePscSpec(sso_site_name=None, sso_admin_password=None, sso_domain_name=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
StandalonePscSpecclass contains information used to configure a standalone PSC appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - sso_site_name (
strorNone) – The SSO site name used for this PSC. This attribute was added in vSphere API 6.7. If None, default-first-site will be used. - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - sso_domain_name (
strorNone) – The SSO domain name to be used to configure this appliance. This attribute was added in vSphere API 6.7. If None, vsphere.local will be used.
- sso_site_name (
-
class
com.vmware.vcenter.deployment_client.StandaloneSpec(sso_admin_password=None, sso_domain_name=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
StandaloneSpecclass contains information used to configure a standalone embedded vCenter Server appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - sso_domain_name (
strorNone) – The SSO domain name to be used to configure this appliance. This attribute was added in vSphere API 6.7. If None, vsphere.local will be used.
- sso_admin_password (
-
class
com.vmware.vcenter.deployment_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
-
class
com.vmware.vcenter.deployment_client.Upgrade(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Upgradeclass provides methods to configure the upgrade of this appliance from an existing vCenter appliance. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
PscSpec(ceip_enabled=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Upgrade.PscSpecclass contains information used to upgrade a Platform Service Controller appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: ceip_enabled ( bool) – Customer experience improvement program should be enabled or disabled for this Platform Services Controller upgrade. This attribute was added in vSphere API 6.7.
-
class
SourceApplianceSpec(hostname=None, https_port=None, ssl_thumbprint=None, ssl_verify=None, sso_admin_username=None, sso_admin_password=None, root_password=None, ssh_verify=None, ssh_thumbprint=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Upgrade.SourceApplianceSpecclass contains information used to connect to the appliance used as the source for an upgrade. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - hostname (
str) – The IP address or DNS resolvable name of the source appliance. This attribute was added in vSphere API 6.7. - https_port (
longorNone) – The HTTPS port of the source appliance. This attribute was added in vSphere API 6.7. If None, port 443 will be used. - ssl_thumbprint (
strorNone) – SHA1 thumbprint of the server SSL certificate will be used for verification. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsslVerifyis None or has the value true. - ssl_verify (
boolorNone) – SSL verification should be enabled or disabled for the source appliance validations. By default it is enabled and will use SSL certificate for verification. If thumbprint is provided, will use thumbprint for the verification. This attribute was added in vSphere API 6.7. If None, ssl_verify true will be used. - sso_admin_username (
str) – The SSO administrator account on the source appliance. This attribute was added in vSphere API 6.7. - sso_admin_password (
str) – The SSO administrator account password. This attribute was added in vSphere API 6.7. - root_password (
str) – The password of the root user on the source appliance. This attribute was added in vSphere API 6.7. - ssh_verify (
boolorNone) – Appliance SSH verification should be enabled or disabled. By default it is disabled and will not use any verification. If thumbprint is provided, thumbprint verification will be performed. This attribute was added in vSphere API 6.7. If None, ssh_verify true will be used. - ssh_thumbprint (
strorNone) – MD5 thumbprint of the server SSH key will be used for verification. This attribute was added in vSphere API 6.7. This attribute is only relevant ifsshVerifyis None or has the value true.
- hostname (
-
class
UpgradeSpec(source_appliance=None, source_location=None, history=None, vcsa_embedded=None, psc=None, auto_answer=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Upgrade.UpgradeSpecclass contains information used to configure the appliance upgrade. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - source_appliance (
Upgrade.SourceApplianceSpec) – Source appliance spec. This attribute was added in vSphere API 6.7. - source_location (
LocationSpec) – Source location spec. This attribute was added in vSphere API 6.7. - history (
HistoryMigrationSpecorNone) –Determines how vCenter history will be migrated during the upgrade process. vCenter history consists of:
- Statistics
- Events
- Tasks
By default only core data will be migrated. Use this spec to define which part of vCenter history data will be migrated and when. This attribute was added in vSphere API 6.7. If None, only core database content will be migrated.
- vcsa_embedded (
Upgrade.VcsaEmbeddedSpecorNone) – Information that are specific to this embedded vCenter Server. This attribute was added in vSphere API 6.7. If None, ceip_enabled for embedded vcenter server upgrade will default to enabled. - psc (
Upgrade.PscSpecorNone) – Information that are specific to this Platform Services Controller. This attribute was added in vSphere API 6.7. If None, ceip_enabled for psc upgrade will default to enabled. - auto_answer (
boolorNone) – Use the default option for any questions that may come up during appliance configuration. This attribute was added in vSphere API 6.7. If None, will default to false.
- source_appliance (
-
class
VcsaEmbeddedSpec(ceip_enabled=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Upgrade.VcsaEmbeddedSpecclass contains information used to upgrade a Embedded vCenter Server appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: ceip_enabled ( bool) – Customer experience improvement program should be enabled or disabled for this embedded vCenter Server upgrade. This attribute was added in vSphere API 6.7.
-
cancel()¶ Cancel the appliance upgrade that is in progress. This method was added in vSphere API 6.7.
Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in CONFIG_IN_PROGRESS state and if the operation is not INSTALL.
-
check(spec)¶ Run sanity checks using the UpgradeSpec parameters passed. This method was added in vSphere API 6.7.
Parameters: spec ( Upgrade.UpgradeSpec) – UpgradeSpec parameters to run sanity check on.Return type: CheckInfoReturns: CheckInfo containing the check results. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif source credentials are not valid.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif source container credentials are not valid.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in INITIALIZED state.
-
get()¶ Get the UpgradeSpec parameters used to configure the ongoing appliance upgrade. This method was added in vSphere API 6.7.
Return type: Upgrade.UpgradeSpecReturns: UpgradeSpec parameters being used to configure appliance upgrade. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif appliance is not in UPGRADE_PROGRESS state.
-
start(spec)¶ Start the appliance installation. This method was added in vSphere API 6.7.
Parameters: spec ( Upgrade.UpgradeSpec) – UpgradeSpec parameters to configure the appliance upgrade.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif source credentials are not valid.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif source container credentials are not valid.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in INITIALIZED state.
-
class
-
class
com.vmware.vcenter.deployment_client.VerificationMode(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
VerificationModeclass defines the verification modes for SSL certificates or SSH connections. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theVerificationModeinstance.-
NONE= VerificationMode(string='NONE')¶ No verification will be performed. This class attribute was added in vSphere API 6.7.
-
THUMBPRINT= VerificationMode(string='THUMBPRINT')¶ Passed thumbprint will be used for verification. This class attribute was added in vSphere API 6.7.
-
com.vmware.vcenter.guest_client module¶
The com.vmware.vcenter.guest_client module provides classes for managing
guest customization specifications in the vCenter Server.
-
class
com.vmware.vcenter.guest_client.CustomizationSpecs(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
CustomizationSpecsclass provides methods to manage guest customization specifications in the vCenter Server. This class was added in vSphere API 6.7 U1.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
FilterSpec(names=None, os_type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CustomizationSpecs.FilterSpecclass contains attributes used to filter the results when listing guest customization specifications (seeCustomizationSpecs.list()). If multiple attributes are specified, only guest customization specifications matching all of the attributes match the filter. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - names (
setofstrorNone) – Names that guest customization specifications must have to match the filter (seeCustomizationSpecs.Summary.name). This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vcenter.guest.CustomizationSpec. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vcenter.guest.CustomizationSpec. If None or empty, guest customization specifications with any name match the filter. - os_type (
CustomizationSpecs.OsTypeorNone) – Guest operating system type that guest customization specifications must have to match the filter (seeCustomizationSpecs.Summary.os_type). This attribute was added in vSphere API 6.7 U1. If None, guest customization specifications with any guest operating system type match the filter.
- names (
-
class
OsType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
CustomizationSpecs.OsTypeclass defines the types of guest operating systems for which guest customization is supported. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theOsTypeinstance.-
LINUX= OsType(string='LINUX')¶ A customization specification for a Linux guest operating system. This class attribute was added in vSphere API 6.7 U1.
-
WINDOWS= OsType(string='WINDOWS')¶ A customization specification for a Windows guest operating system. This class attribute was added in vSphere API 6.7 U1.
-
-
RESOURCE_TYPE= 'com.vmware.vcenter.guest.CustomizationSpec'¶ The resource type for a vCenter guest customization specification. This class attribute was added in vSphere API 6.7 U1.
-
class
Summary(name=None, description=None, os_type=None, last_modified=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CustomizationSpecs.Summaryclass contains commonly used information about a guest customization specification. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
str) – Name of the guest customization specification. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.guest.CustomizationSpec. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.guest.CustomizationSpec. - description (
str) – Description of the guest customization specification. This attribute was added in vSphere API 6.7 U1. - os_type (
CustomizationSpecs.OsType) – Guest operating system type for which that this guest customization specification applies. This attribute was added in vSphere API 6.7 U1. - last_modified (
datetime.datetime) – Date and tme when this guest customization specification was last modified. This attribute was added in vSphere API 6.7 U1.
- name (
-
list(filter=None)¶ Returns information about at most 1000 visible (subject to permission checks) guest customization specifications in vCenter matching the
CustomizationSpecs.FilterSpec. This method was added in vSphere API 6.7 U1.Parameters: filter ( CustomizationSpecs.FilterSpecorNone) – Specification of matching guest customization specifications for which information should be returned. If None, the behavior is equivalent to aCustomizationSpecs.FilterSpecwith all attributes None which means all guest customization specifications match the filter.Return type: listofCustomizationSpecs.SummaryReturns: Commonly used information about the guest customization specifications matching the CustomizationSpecs.FilterSpec.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif theCustomizationSpecs.FilterSpec.os_typeattribute contains a value that is not supported by the server.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif more than 1000 guest customization specifications match theCustomizationSpecs.FilterSpec.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
class
-
class
com.vmware.vcenter.guest_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.hvc_client module¶
The com.vmware.vcenter.hvc_client module provides classes to manage hybrid
links between a local and remote Platform Service Controller.
-
class
com.vmware.vcenter.hvc_client.Links(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Linksclass provides methods to create, delete, get information, and list hybrid links between the local and foreign Platform Service Controller (PSC). Warning: This class is available as technical preview. It may be changed in a future release.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
CertificateInfo(ssl_thumbprint=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Links.CertificateInfoclass contains information about the SSL certificate for a destination PSC endpoint. Warning: This class is available as technical preview. It may be changed in a future release.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: ssl_thumbprint ( str) – The SHA-256 thumbprint of the SSL certificate for the destination PSC endpoint. Warning: This attribute is available as technical preview. It may be changed in a future release.
-
class
CreateSpec(psc_hostname=None, port=None, domain_name=None, username=None, password=None, ssl_thumbprint=None, admin_groups=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Links.CreateSpecclass is the specification used for the hybrid link creation. Warning: This class is available as technical preview. It may be changed in a future release.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - psc_hostname (
str) – The PSC hostname for the domain to be linked. Warning: This attribute is available as technical preview. It may be changed in a future release. - port (
strorNone) – The HTTPS port of the PSC to be linked. Warning: This attribute is available as technical preview. It may be changed in a future release. If None 443 will be used as default. - domain_name (
str) – The domain to which the PSC belongs. Warning: This attribute is available as technical preview. It may be changed in a future release. - username (
str) – The administrator username of the PSC. Warning: This attribute is available as technical preview. It may be changed in a future release. - password (
str) – The administrator password of the PSC. Warning: This attribute is available as technical preview. It may be changed in a future release. - ssl_thumbprint (
strorNone) – The ssl thumbprint of the server. Warning: This attribute is available as technical preview. It may be changed in a future release. if None no thumbprint is passed. - admin_groups (
setofstrorNone) – List of groups to be added to enable administrator access to. Warning: This attribute is available as technical preview. It may be changed in a future release. if None administrator access will not be set.
- psc_hostname (
-
class
Summary(link=None, display_name=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Links.Summaryclass contains information about the hybrid link. Warning: This class is available as technical preview. It may be changed in a future release.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - link (
str) – Unique identifier for the link. Warning: This attribute is available as technical preview. It may be changed in a future release. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.hvc.Links. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.hvc.Links. - display_name (
str) – The display name is set to the domain name which was set during create. Warning: This attribute is available as technical preview. It may be changed in a future release.
- link (
-
create(spec)¶ Creates a new hybrid link between the local and foreign PSC. Warning: This method is available as technical preview. It may be changed in a future release.
Parameters: spec ( Links.CreateSpec) – Specification for the new link to be created.Return type: strReturns: The identifier of the newly linked domain. The return value will be an identifier for the resource type: com.vmware.vcenter.hvc.Links.Raise: com.vmware.vapi.std.errors_client.AlreadyExistsIf the link already exists.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentIf the values of any of the attributes of thespecparameter are not valid.Raise: com.vmware.vapi.std.errors_client.UnsupportedIf the PSC or the VC version is not supported.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user is not authorized.Raise: com.vmware.vapi.std.errors_client.InvalidRequestIf the SSL certificate of the foreign PSC cannot be validated by comparing with the thumbprint provided inLinks.CreateSpec.ssl_thumbprintor ifLinks.CreateSpec.ssl_thumbprintis None. The value of the {\@link InvalidRequest#data) attribute will be a class that contains all the attributes defined inLinks.CertificateInfo.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.
-
delete(link)¶ Deletes an existing hybrid link. Warning: This method is available as technical preview. It may be changed in a future release.
Parameters: link ( str) – Identifier of the hybrid link. The parameter must be an identifier for the resource type:com.vmware.vcenter.hvc.Links.Raise: com.vmware.vapi.std.errors_client.NotFoundIf the hybrid link associated withlinkdoes not exist.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user is not authorized.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.
-
list()¶ Enumerates the list of registered hybrid links. Warning: This method is available as technical preview. It may be changed in a future release.
Return type: listofLinks.SummaryReturns: The listof hybrid link information.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.
-
class
-
class
com.vmware.vcenter.hvc_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.inventory_client module¶
The com.vmware.vcenter.inventory_client component provides methods and
classes for retrieving vCenter datastore and network information for a given
list of identifiers.
-
class
com.vmware.vcenter.inventory_client.Datastore(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Datastoreclass provides methods to retrieve information about datastores.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Datastore.Infoclass contains information about a datastore.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: type ( str) – Type of the datastore. When clients pass a value of this class as a parameter, the attribute must be one ofDatastoreorStoragePod. When methods return a value of this class as a return value, the attribute will be one ofDatastoreorStoragePod.
-
find(datastores)¶ Returns datastore information for the specified datastores. The key in the return value
dictis the datastore identifier and the value in thedictis the datastore information.Parameters: datastores (
listofstr) – Identifiers of the datastores for which information will be returned. The parameter must contain identifiers for the resource type:Datastore.Return type: dictofstrand (Datastore.InfoorNone)Returns: Datastore information for the specified datastores. The key in the return value
dictis the datastore identifier and the value in thedictis the datastore information. The key in the return valuedictwill be an identifier for the resource type:Datastore.Raise: com.vmware.vapi.std.errors_client.NotFoundif no datastore can be found for one or more of the datastore identifiers indatastoresRaise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
Datastorereferenced by the parameterdatastoresrequiresSystem.Read.
- Method execution requires
-
class
-
class
com.vmware.vcenter.inventory_client.Network(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Networkclass provides methods to retrieve information about vCenter Server networks.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Network.Infoclass contains information about a vCenter Server network.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: type ( str) – Type of the vCenter Server network. When clients pass a value of this class as a parameter, the attribute must be one ofNetwork,DistributedVirtualPortgroup, orOpaqueNetwork. When methods return a value of this class as a return value, the attribute will be one ofNetwork,DistributedVirtualPortgroup, orOpaqueNetwork.
-
find(networks)¶ Returns network information for the specified vCenter Server networks. The key in the return value
dictis the network identifier and the value in thedictis the network information.Parameters: networks (
listofstr) – Identifiers of the vCenter Server networks for which information will be returned. The parameter must contain identifiers for the resource type:Network.Return type: dictofstrand (Network.InfoorNone)Returns: Network information for the specified vCenter Server networks. The key in the return value
dictis the network identifier and the value in thedictis the network information. The key in the return valuedictwill be an identifier for the resource type:Network.Raise: com.vmware.vapi.std.errors_client.NotFoundif no datastore can be found for one or more of the vCenter Server network identifiers innetworksRaise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
Networkreferenced by the parameternetworksrequiresSystem.Read.
- Method execution requires
-
class
-
class
com.vmware.vcenter.inventory_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.iso_client module¶
The com.vmware.vcenter.iso_client module provides classes and classes that
will let its client mount or unmount an ISO image on a virtual machine as a
CD-ROM.
-
class
com.vmware.vcenter.iso_client.Image(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceProvides an interface to mount and unmount an ISO image on a virtual machine.
This is an API that will let its client mount or unmount an ISO image on a virtual machine as a CD-ROM.
Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
mount(library_item, vm)¶ Mounts an ISO image from a content library on a virtual machine.
Parameters: - library_item (
str) – The identifier of the library item having the ISO image to mount on the virtual machine. The parameter must be an identifier for the resource type:com.vmware.content.library.Item. - vm (
str) – The identifier of the virtual machine where the specified ISO image will be mounted. The parameter must be an identifier for the resource type:VirtualMachine.
Return type: strReturns: The identifier of the newly created virtual CD-ROM backed by the specified ISO image. The return value will be an identifier for the resource type:
com.vmware.vcenter.vm.hardware.Cdrom.Raise: com.vmware.vapi.std.errors_client.NotFoundIf eithervmor thelibrary_itemis not found.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentIf no .iso file is present on the library item.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateWhen the operation is not allowed on the virtual machine in its current state.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
VirtualMachinereferenced by the parametervmrequiresVirtualMachine.Config.AddRemoveDevice. - The resource
com.vmware.content.library.Itemreferenced by the parameterlibrary_itemrequiresContentLibrary.DownloadSession.
- library_item (
-
unmount(vm, cdrom)¶ Unmounts a previously mounted CD-ROM using an ISO image as a backing.
Parameters: - vm (
str) – The identifier of the virtual machine from which to unmount the virtual CD-ROM. The parameter must be an identifier for the resource type:VirtualMachine. - cdrom (
str) – The device identifier of the CD-ROM. The parameter must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Cdrom.
Raise: com.vmware.vapi.std.errors_client.NotFoundIf the virtual machine identified byvmis not found or thecdromdoes not identify a virtual CD-ROM in the virtual machine.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateWhen the operation is not allowed on the virtual machine in its current state.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
VirtualMachinereferenced by the parametervmrequiresVirtualMachine.Config.AddRemoveDevice. - The resource
com.vmware.vcenter.vm.hardware.Cdromreferenced by the parametercdromrequiresSystem.Read.
- vm (
-
-
class
com.vmware.vcenter.iso_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.ovf_client module¶
The com.vmware.vcenter.ovf_client module provides services to capture and
deploy Open Virtualization Format (OVF) packages to and from the content
library.
It provides the ability to deploy OVF packages from the content library with support for advanced network topologies, network services, creating virtual appliances and virtual machines in hosts, resource pools or clusters. It also provides the ability to export virtual appliances and virtual machines from hosts, resource pools or clusters as OVF packages to the content library.
-
class
com.vmware.vcenter.ovf_client.CertificateParams(issuer=None, subject=None, is_valid=None, is_self_signed=None, x509=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CertificateParamsclass contains information about the public key certificate used to sign the OVF package. This class will only be returned if the OVF package is signed.SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - issuer (
str) – Certificate issuer. For example: /C=US/ST=California/L=Palo Alto/O=VMware, Inc. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - subject (
str) – Certificate subject. For example: /C=US/ST=Massachusetts/L=Hopkinton/O=EMC Corporation/OU=EMC Avamar/CN=EMC Corporation. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - is_valid (
bool) – Is the certificate chain validated. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - is_self_signed (
bool) – Is the certificate self-signed. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - x509 (
str) – The X509 representation of the certificate. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- issuer (
-
class
com.vmware.vcenter.ovf_client.DeploymentOption(key=None, label=None, description=None, default_choice=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DeploymentOptionclass contains the information about a deployment option as defined in the OVF specification.This corresponds to the ovf:Configuration element of the ovf:DeploymentOptionSection in the specification. The ovf:DeploymentOptionSection specifies a discrete set of intended resource allocation configurations. This class represents one item from that set.
SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - key (
str) – The key of the deployment option, corresponding to the ovf:id attribute in the OVF descriptor. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - label (
str) – A localizable label for the deployment option. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - description (
str) – A localizable description for the deployment option. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - default_choice (
bool) – Aboolflag indicates whether this deployment option is the default choice. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. If None or false, it is not the default.
- key (
-
class
com.vmware.vcenter.ovf_client.DeploymentOptionParams(deployment_options=None, selected_key=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DeploymentOptionParamsclass describes the possible deployment options as well as the choice provided by the user.This information based on the ovf:DeploymentOptionSection.
See
LibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - deployment_options (
listofDeploymentOption) –listof deployment options. This attribute corresponds to the ovf:Configuration elements of the ovf:DeploymentOptionSection in the specification. It is a discrete set of intended resource allocation configurations from which one can be selected. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - selected_key (
str) – The selected deployment option. Identifies theDeploymentOptionin the list in thedeploymentOptionsattribute with a matching value in theDeploymentOption.keyattribute. This attribute is optional in the input parameters when deploying an OVF package. If None the server will use the default deployment configuration, usually it’s the first one inDeploymentOptionParams.deployment_optionslist. This attribute is optional in the result when retrieving information about an OVF package. The value will be set only if it is specified with the optional ovf:default attribute. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- deployment_options (
-
class
com.vmware.vcenter.ovf_client.DiskProvisioningType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
DiskProvisioningTypeclass defines the virtual disk provisioning types that can be set for a disk on the target platform.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theDiskProvisioningTypeinstance.-
eagerZeroedThick= DiskProvisioningType(string='eagerZeroedThick')¶ An eager zeroed thick provisioned virtual disk has all space allocated and wiped clean of any previous contents on the physical media at creation time.
Disks specified as eager zeroed thick may take longer time to create than disks specified with the other disk provisioning types.
-
thick= DiskProvisioningType(string='thick')¶ A thick provisioned virtual disk has all space allocated at creation time and the space is zeroed on demand as the space is used.
-
thin= DiskProvisioningType(string='thin')¶ A thin provisioned virtual disk has space allocated and zeroed on demand as the space is used.
-
-
class
com.vmware.vcenter.ovf_client.ExportFlag(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
ExportFlagclass provides methods for retrieving information about the export flags supported by the server. Export flags can be specified in aLibraryItem.CreateSpecto customize an OVF export.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(option=None, description=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ExportFlag.Infoclass describes an export flag supported by the server.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - option (
str) – The name of the export flag that is supported by the server. - description (
com.vmware.vapi.std_client.LocalizableMessage) – Localizable description of the export flag.
- option (
-
list()¶ Returns information about the supported export flags by the server.
The supported flags are:- PRESERVE_MAC
- Include MAC addresses for network adapters.
- EXTRA_CONFIG
- Include extra configuration in OVF export.
Future server versions might support additional flags.
Return type: Returns: A
listof supported export flags.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read.
-
class
-
class
com.vmware.vcenter.ovf_client.ExtraConfig(key=None, value=None, virtual_system_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ExtraConfigclass contains the information about a vmw:ExtraConfig element which can be used to specify configuration settings that are transferred directly to the.vmxfile. The behavior of the vmw:ExtraConfig element is similar to theextraConfigproperty of theVirtualMachineConfigSpecobject in the VMware vSphere API. Thus, the same restrictions apply, such as you cannot set values that could otherwise be set with other properties in theVirtualMachineConfigSpecobject. See the VMware vSphere API reference for details on this.vmw:ExtraConfig elements may occur as direct child elements of a VirtualHardwareSection, or as child elements of individual virtual hardware items.
SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - key (
str) – The key of the ExtraConfig element. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - value (
str) – The value of the ExtraConfig element. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - virtual_system_id (
str) – The identifier of the virtual system containing the vmw:ExtraConfig element. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- key (
-
class
com.vmware.vcenter.ovf_client.ExtraConfigParams(extra_configs=None, exclude_keys=None, include_keys=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ExtraConfigParamsclass contains the parameters with information about the vmw:ExtraConfig elements in an OVF package.vmw:ExtraConfig elements can be used to specify configuration settings that are transferred directly to the
.vmxfile.The behavior of the vmw:ExtraConfig element is similar to the
extraConfigproperty of theVirtualMachineConfigSpecobject in the VMware vSphere API. Thus, the same restrictions apply, such as you cannot set values that could otherwise be set with other properties in theVirtualMachineConfigSpecobject. See the VMware vSphere API reference for details on this.SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - extra_configs (
listofExtraConfig) –listof vmw:ExtraConfig elements in the OVF package. This attribute is optional in the input parameters when deploying an OVF package. If None there are no extra configuration elements to use for this OVF package deployment. This attribute will always be present in the result when retrieving information about an OVF package. It will be an emptylistif there are no extra configuration elements in the OVF package. - exclude_keys (
listofstr) –Specifies which extra configuration items in the
listin theextraConfigsfieldshould be ignored during deployment.If set, the given keys for extra configurations will be ignored during deployment. The key is defined in the
ExtraConfig.keyattribute. This attribute is optional in the input parameters when deploying an OVF package. It is an error to set both this andExtraConfigParams.include_keys. This attribute is optional in the result when retrieving information about an OVF package. It is an error to set both this andExtraConfigParams.include_keys. - include_keys (
listofstr) –Specifies which extra configuration items in the
listin theextraConfigsfieldshould be included during deployment.If set, all but the given keys for extra configurations will be ignored during deployment. The key is defined in the
ExtraConfig.keyattribute. This attribute is optional in the input parameters when deploying an OVF package. It is an error to set both this andExtraConfigParams.exclude_keys. This attribute is optional in the result when retrieving information about an OVF package. It is an error to set both this andExtraConfigParams.exclude_keys. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- extra_configs (
-
class
com.vmware.vcenter.ovf_client.ImportFlag(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
ImportFlagclass provides methods for retrieving information about the import flags supported by the deployment platform. Import flags can be specified in aLibraryItem.ResourcePoolDeploymentSpecto customize an OVF deployment.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(option=None, description=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ImportFlag.Infoclass describes an import flag supported by the deployment platform.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - option (
str) – The name of the import flag that is supported by the deployment platform. - description (
com.vmware.vapi.std_client.LocalizableMessage) – Localizable description of the import flag.
- option (
-
list(rp)¶ Returns information about the import flags supported by the deployment platform.
The supported flags are:- LAX
- Lax mode parsing of the OVF descriptor.
Future server versions might support additional flags.
Parameters: rp (
str) – The identifier of resource pool target for retrieving the import flag(s). The parameter must be an identifier for the resource type:ResourcePool.Return type: Returns: A
listof supported import flags.Raise: com.vmware.vapi.std.errors_client.NotFoundIf the resource pool associated withrpdoes not exist.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
ResourcePoolreferenced by the parameterrprequiresSystem.Read.
-
class
-
class
com.vmware.vcenter.ovf_client.IpAllocationParams(supported_allocation_scheme=None, supported_ip_allocation_policy=None, ip_allocation_policy=None, supported_ip_protocol=None, ip_protocol=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
IpAllocationParamsclass specifies how IP addresses are allocated to OVF properties. In particular, it informs the deployment platform whether the guest supports IPv4, IPv6, or both. It also specifies whether the IP addresses can be obtained through DHCP or through the properties provided in the OVF environment.Ovf Property elements are exposed to the guest software through the OVF environment. Each Property element exposed in the OVF environment shall be constructed from the value of the ovf:key attribute. A Property element contains a key/value pair, it may optionally specify type qualifiers using the ovf:qualifiers attribute with multiple qualifiers separated by commas.
The settings in
IpAllocationParamsclass are global to a deployment. Thus, if a virtual machine is part of a virtual appliance, then its settings are ignored and the settings for the virtual appliance is used.This information is based on the vmw:IpAssignmentSection in OVF package.
See
LibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - supported_allocation_scheme (
listofIpAllocationParams.IpAllocationScheme) – Specifies the IP allocation schemes supported by the guest software. This attribute defines the valid values for the IP allocation policy. This setting is often configured by the virtual appliance template author or OVF package author to reflect what the guest software supports, and the IP allocation policy is configured at deployment time. SeeIpAllocationParams.ip_allocation_policy. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - supported_ip_allocation_policy (
listofIpAllocationParams.IpAllocationPolicy) – Specifies the IP allocation policies supported. The set of valid options for the policy is based on the capabilities of the virtual appliance software, as specified by theIpAllocationParams.supported_allocation_schemeattribute. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - ip_allocation_policy (
IpAllocationParams.IpAllocationPolicy) – Specifies how IP allocation is done through an IP Pool. This is typically specified by the deployer. This attribute is optional in the input parameters when deploying an OVF package. If None there is no IP allocation policy. This attribute will always be present in the result when retrieving information about an OVF package. - supported_ip_protocol (
listofIpAllocationParams.IpProtocol) – Specifies the IP protocols supported by the guest. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - ip_protocol (
IpAllocationParams.IpProtocol) – Specifies the chosen IP protocol for this deployment. This must be one of the IP protocols supported by the guest software. SeeIpAllocationParams.supported_ip_protocol. This attribute is optional in the input parameters when deploying an OVF package. If None there is no IP protocol chosen. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
-
class
IpAllocationPolicy(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
IpAllocationParams.IpAllocationPolicyclass defines the possible IP allocation policy for a deployment.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theIpAllocationPolicyinstance.-
DHCP= IpAllocationPolicy(string='DHCP')¶ Specifies that DHCP will be used to allocate IP addresses.
-
STATIC_IPPOOL= IpAllocationPolicy(string='STATIC_IPPOOL')¶ Specifies that IP addresses are allocated from the range managed by an IP pool. The IP addresses are allocated at first power-on, and remain allocated at power-off. This ensures that a virtual appliance gets a consistent IP for its life-time.
-
STATIC_MANUAL= IpAllocationPolicy(string='STATIC_MANUAL')¶ Specifies that IP addresses are configured manually upon deployment, and will be kept until reconfigured or the virtual appliance destroyed. This ensures that a property gets a consistent IP for its lifetime.
-
TRANSIENT_IPPOOL= IpAllocationPolicy(string='TRANSIENT_IPPOOL')¶ Specifies that IP addresses are allocated from an IP pool. The IP addresses are allocated when needed, typically at power-on, and deallocated during power-off. There is no guarantee that a property will receive same IP address when restarted.
-
-
class
IpAllocationScheme(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
IpAllocationParams.IpAllocationSchemeclass defines the possible IP allocation schemes that can be supported by the guest software.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theIpAllocationSchemeinstance.-
DHCP= IpAllocationScheme(string='DHCP')¶ It supports DHCP to acquire IP configuration.
-
OVF_ENVIRONMENT= IpAllocationScheme(string='OVF_ENVIRONMENT')¶ It supports setting the IP configuration through the properties provided in the OVF environment.
-
-
class
IpProtocol(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
IpAllocationParams.IpProtocolclass defines the IP protocols supported by the guest software.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theIpProtocolinstance.-
IPV4= IpProtocol(string='IPV4')¶ It supports the IPv4 protocol.
-
IPV6= IpProtocol(string='IPV6')¶ It supports the IPv6 protocol.
-
- supported_allocation_scheme (
-
class
com.vmware.vcenter.ovf_client.LibraryItem(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
LibraryItemclass provides methods to deploy virtual machines and virtual appliances from library items containing Open Virtualization Format (OVF) packages in content library, as well as methods to create library items in content library from virtual machines and virtual appliances.To deploy a virtual machine or a virtual appliance from a library item:- Create a
LibraryItem.DeploymentTargetto specify the target deployment type and target deployment designation. - Create a
LibraryItem.ResourcePoolDeploymentSpecto specify the parameters for the target deployment. - Use the
deploymethod with the created target and parameter specifications, along with the identifier of the specified source content library item. SeeLibraryItem.deploy().
To create a library item in content library from a virtual machine or virtual appliance:
- Create a
LibraryItem.DeployableIdentityto specify the source virtual machine or virtual appliance to be used as the OVF template source. - Create a
LibraryItem.CreateTargetto specify the target library and library item. - Create a
LibraryItem.CreateSpecto specify the settings for the OVF package to be created. - Use the
createmethod with the created target and parameter specifications, along with the specified source entity. SeeLibraryItem.create().
Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
CreateResult(succeeded=None, ovf_library_item_id=None, error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.CreateResultclass defines the result of thecreatemethod. SeeLibraryItem.create().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - succeeded (
bool) – Whether thecreatemethod completed successfully. - ovf_library_item_id (
strorNone) – Identifier of the created or updated library item. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.library.Item. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.library.Item. If None, thecreatemethod failed andLibraryItem.CreateResult.errorwill describe the error(s) that caused the failure. - error (
LibraryItem.ResultInfoorNone) – Errors, warnings, and informational messages produced by thecreatemethod. If None, no errors, warnings, or informational messages were reported by thecreatemethod.
- succeeded (
-
class
CreateSpec(name=None, description=None, flags=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.CreateSpecclass defines the information used to create or update a library item containing an OVF package.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
strorNone) – Name to use in the OVF descriptor stored in the library item. If None, the server will use source’s current name. - description (
strorNone) – Description to use in the OVF descriptor stored in the library item. If None, the server will use source’s current annotation. - flags (
listofstrorNone) – Flags to use for OVF package creation. The supported flags can be obtained usingExportFlag.list(). If None, no flags will be used.
- name (
-
class
CreateTarget(library_id=None, library_item_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.CreateTargetclass specifies the target library item when capturing a virtual machine or virtual appliance as an OVF package in a library item in a content library. The target can be an existing library item, which will be updated, creating a new version, or it can be a newly created library item in a specified library. SeeLibraryItem.create().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - library_id (
strorNone) – Identifier of the library in which a new library item should be created. This attribute is not used if thelibraryItemIdattribute is specified. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.Library. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.Library. If None, thelibraryItemIdattribute must be specified. - library_item_id (
strorNone) – Identifier of the library item that should be should be updated. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.library.Item. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.library.Item. If None, a new library item will be created. ThelibraryIdattribute must be specified if this attribute is None.
- library_id (
-
DEPLOYABLE= ['VirtualMachine', 'VirtualApp']¶ The types of resources that can be created by deploying an OVF package and can be captured to create a library item using the
LibraryItemclass.
-
class
DeployableIdentity(type=None, id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.DeployableIdentityclass describes the resource created by a deployment, or the source resource from which library item can be created, by specifying its resource type and resource identifier.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
str) – Type of the deployable resource. When clients pass a value of this class as a parameter, the attribute must be one ofVirtualMachineorVirtualApp. When methods return a value of this class as a return value, the attribute will be one ofVirtualMachineorVirtualApp. - id (
str) – Identifier of the deployable resource. When clients pass a value of this class as a parameter, the attributetypemust contain the actual resource type. When methods return a value of this class as a return value, the attributetypewill contain the actual resource type.
- type (
-
class
DeploymentResult(succeeded=None, resource_id=None, error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.DeploymentResultclass defines the result of thedeploymethod. SeeLibraryItem.deploy().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - succeeded (
bool) – Whether thedeploymethod completed successfully. - resource_id (
LibraryItem.DeployableIdentityorNone) – Identifier of the deployed resource entity. If None, thedeploymethod failed andLibraryItem.DeploymentResult.errorwill describe the error(s) that caused the failure. - error (
LibraryItem.ResultInfoorNone) – Errors, warnings, and informational messages produced by thedeploymethod. If None, no errors, warnings, or informational messages were reported by thedeploymethod.
- succeeded (
-
class
DeploymentTarget(resource_pool_id=None, host_id=None, folder_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.DeploymentTargetclass describes the location (target) where a virtual machine or virtual appliance should be deployed. It is used in thedeployandfiltermethods. SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - resource_pool_id (
str) – Identifier of the resource pool to which the virtual machine or virtual appliance should be attached. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool. - host_id (
strorNone) – Identifier of the target host on which the virtual machine or virtual appliance will run. The target host must be a member of the cluster that contains the resource pool identified byLibraryItem.DeploymentTarget.resource_pool_id. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:HostSystem. If None, the server will automatically select a target host from the resource pool ifLibraryItem.DeploymentTarget.resource_pool_idis a stand-alone host or a cluster with Distributed Resource Scheduling (DRS) enabled. - folder_id (
strorNone) – Identifier of the vCenter folder that should contain the virtual machine or virtual appliance. The folder must be virtual machine folder. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder. If None, the server will choose the deployment folder.
- resource_pool_id (
-
class
OvfSummary(name=None, annotation=None, eulas=None, networks=None, storage_groups=None, additional_params=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.OvfSummaryclass defines the result of thefiltermethod. SeeLibraryItem.filter(). The attributes in the class describe parameterizable information in the OVF descriptor, with respect to a deployment target, for thedeploymethod. SeeLibraryItem.deploy().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
strorNone) – Default name for the virtual machine or virtual appliance. If None, the OVF descriptor did not specify a name. - annotation (
strorNone) – Default annotation for the virtual machine or virtual appliance. If None, the OVF descriptor did not specify an annotation. - eulas (
listofstr) – End User License Agreements specified in the OVF descriptor. All end user license agreements must be accepted in order for thedeploymethod to succeed. SeeLibraryItem.ResourcePoolDeploymentSpec.accept_all_eula. - networks (
listofstrorNone) – Section identifiers for sections of type ovf:NetworkSection in the OVF descriptor. These identifiers can be used as keys inLibraryItem.ResourcePoolDeploymentSpec.network_mappings. If None, the OVF descriptor did not specify any networks. - storage_groups (
listofstrorNone) – Section identifiers for sections of type vmw:StorageGroupSection in the OVF descriptor. These identifiers can be used as keys inLibraryItem.ResourcePoolDeploymentSpec.storage_mappings. If None, the OVF descriptor did not specify any storage groups. - additional_params (
listofvmware.vapi.struct.VapiStructorNone) – Additional OVF parameters which can be specified for the deployment target. These OVF parameters can be inspected, optionally modified, and used as values inLibraryItem.ResourcePoolDeploymentSpec.additional_parametersfor thedeploymethod. When clients pass a value of this class as a parameter, the attribute must contain all the attributes defined inOvfParams. When methods return a value of this class as a return value, the attribute will contain all the attributes defined inOvfParams. If None, the OVF descriptor does not require addtional parameters or does not have additional parameters suitable for the deployment target.
- name (
-
class
ResourcePoolDeploymentSpec(name=None, annotation=None, accept_all_eula=None, network_mappings=None, storage_mappings=None, storage_provisioning=None, storage_profile_id=None, locale=None, flags=None, additional_parameters=None, default_datastore_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.ResourcePoolDeploymentSpecclass defines the deployment parameters that can be specified for thedeploymethod where the deployment target is a resource pool. SeeLibraryItem.deploy().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
strorNone) – Name assigned to the deployed target virtual machine or virtual appliance. If None, the server will use the name from the OVF package. - annotation (
strorNone) – Annotation assigned to the deployed target virtual machine or virtual appliance. If None, the server will use the annotation from the OVF package. - accept_all_eula (
bool) – Whether to accept all End User License Agreements. SeeLibraryItem.OvfSummary.eulas. - network_mappings ((
dictofstrandstr) orNone) – Specification of the target network to use for sections of type ovf:NetworkSection in the OVF descriptor. The key in thedictis the section identifier of the ovf:NetworkSection section in the OVF descriptor and the value is the target network to be used for deployment. When clients pass a value of this class as a parameter, the value in the attributedictmust be an identifier for the resource type:Network. When methods return a value of this class as a return value, the value in the attributedictwill be an identifier for the resource type:Network. If None, the server will choose a network mapping. - storage_mappings ((
dictofstrandLibraryItem.StorageGroupMapping) orNone) – Specification of the target storage to use for sections of type vmw:StorageGroupSection in the OVF descriptor. The key in thedictis the section identifier of the ovf:StorageGroupSection section in the OVF descriptor and the value is the target storage specification to be used for deployment. SeeLibraryItem.StorageGroupMapping. If None, the server will choose a storage mapping. - storage_provisioning (
DiskProvisioningTypeorNone) – Default storage provisioning type to use for all sections of type vmw:StorageSection in the OVF descriptor. If None, the server will choose the provisioning type. - storage_profile_id (
strorNone) – Default storage profile to use for all sections of type vmw:StorageSection in the OVF descriptor. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:StorageProfile. If None, the server will choose the default profile. - locale (
strorNone) – The locale to use for parsing the OVF descriptor. If None, the server locale will be used. - flags (
listofstrorNone) – Flags to be use for deployment. The supported flag values can be obtained usingImportFlag.list(). If None, no flags will be used. - additional_parameters (
listofvmware.vapi.struct.VapiStructorNone) –Additional OVF parameters that may be needed for the deployment. Additional OVF parameters may be required by the OVF descriptor of the OVF package in the library item. Examples of OVF parameters that can be specified through this attribute include, but are not limited to:
DeploymentOptionParamsExtraConfigParamsIpAllocationParamsPropertyParamsScaleOutParamsVcenterExtensionParams
When clients pass a value of this class as a parameter, the attribute must contain all the attributes defined in
OvfParams. When methods return a value of this class as a return value, the attribute will contain all the attributes defined inOvfParams. If None, the server will choose default settings for all parameters necessary for thedeploymethod. SeeLibraryItem.deploy(). - default_datastore_id (
strorNone) – Default datastore to use for all sections of type vmw:StorageSection in the OVF descriptor. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. If None, the server will choose the default datastore.
- name (
-
class
ResultInfo(errors=None, warnings=None, information=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.ResultInfoclass defines the information returned along with the result of acreateordeploymethod to describe errors, warnings, and informational messages produced by the server.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - errors (
listofOvfError) – Errors reported by thecreateordeploymethod. These errors would have prevented thecreateordeploymethod from completing successfully. - warnings (
listofOvfWarning) – Warnings reported by thecreateordeploymethod. These warnings would not have prevented thecreateordeploymethod from completing successfully, but there might be issues that warrant attention. - information (
listofOvfInfo) – Information messages reported by thecreateordeploymethod. For example, a non-required parameter was ignored.
- errors (
-
class
StorageGroupMapping(type=None, datastore_id=None, storage_profile_id=None, provisioning=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItem.StorageGroupMappingclass defines the storage deployment target and storage provisioning type for a section of type vmw:StorageGroupSection in the OVF descriptor.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
LibraryItem.StorageGroupMapping.Type) – Type of storage deployment target to use for the vmw:StorageGroupSection section. The specified value must beLibraryItem.StorageGroupMapping.Type.DATASTOREorLibraryItem.StorageGroupMapping.Type.STORAGE_PROFILE. - datastore_id (
str) – Target datastore to be used for the storage group. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. This attribute is optional and it is only relevant when the value oftypeisLibraryItem.StorageGroupMapping.Type.DATASTORE. - storage_profile_id (
str) – Target storage profile to be used for the storage group. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:StorageProfile. This attribute is optional and it is only relevant when the value oftypeisLibraryItem.StorageGroupMapping.Type.STORAGE_PROFILE. - provisioning (
DiskProvisioningTypeorNone) – Target provisioning type to use for the storage group. If None,LibraryItem.ResourcePoolDeploymentSpec.storage_provisioningwill be used.
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
LibraryItem.StorageGroupMapping.Typeclass defines the supported types of storage targets for sections of type vmw:StorageGroupSection in the OVF descriptor.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
DATASTORE= Type(string='DATASTORE')¶ Storage deployment target is a datastore.
-
STORAGE_PROFILE= Type(string='STORAGE_PROFILE')¶ Storage deployment target is a storage profile.
-
- type (
-
create(source, target, create_spec, client_token=None)¶ Creates a library item in content library from a virtual machine or virtual appliance.
This method creates a library item in content library whose content is an OVF package derived from a source virtual machine or virtual appliance, using the supplied create specification. The OVF package may be stored as in a newly created library item or in an in an existing library item. For an existing library item whose content is updated by this method, the original content is overwritten.
Parameters: - client_token (
strorNone) – Client-generated token used to retry a request if the client fails to get a response from the server. If the original request succeeded, the result of that request will be returned, otherwise the operation will be retried. If None, the server will create a token. - source (
LibraryItem.DeployableIdentity) – Identifier of the virtual machine or virtual appliance to use as the source. - target (
LibraryItem.CreateTarget) – Specification of the target content library and library item. - create_spec (
LibraryItem.CreateSpec) – Information used to create the OVF package from the source virtual machine or virtual appliance.
Return type: Returns: Information about the success or failure of the method, along with the details of the result or failure.
Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifcreate_speccontains invalid arguments.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifsourcedescribes an unexpected resource type.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine or virtual appliance specified bysourcedoes not exist.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library or library item specified bytargetdoes not exist.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation cannot be performed because of the specified virtual machine or virtual appliance’s current state. For example, if the virtual machine configuration information is not available, or if the virtual appliance is running.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there was an error accessing a file from the source virtual machine or virtual appliance.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the specified virtual machine or virtual appliance is busy.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The attribute
LibraryItem.DeployableIdentity.idrequiresVApp.Export. - The resource
com.vmware.content.Libraryreferenced by the attributeLibraryItem.CreateTarget.library_idrequiresContentLibrary.AddLibraryItem. - The resource
com.vmware.content.library.Itemreferenced by the attributeLibraryItem.CreateTarget.library_item_idrequiresSystem.Read.
- client_token (
-
deploy(ovf_library_item_id, target, deployment_spec, client_token=None)¶ Deploys an OVF package stored in content library to a newly created virtual machine or virtual appliance.
This method deploys an OVF package which is stored in the library item specified by
ovf_library_item_id. It uses the deployment specification indeployment_specto deploy the OVF package to the location specified bytarget.Parameters: - client_token (
strorNone) – Client-generated token used to retry a request if the client fails to get a response from the server. If the original request succeeded, the result of that request will be returned, otherwise the operation will be retried. If None, the server will create a token. - ovf_library_item_id (
str) – Identifier of the content library item containing the OVF package to be deployed. The parameter must be an identifier for the resource type:com.vmware.content.library.Item. - target (
LibraryItem.DeploymentTarget) – Specification of the deployment target. - deployment_spec (
LibraryItem.ResourcePoolDeploymentSpec) – Specification of how the OVF package should be deployed to the target.
Return type: Returns: Information about the success or failure of the method, along with the details of the result or failure.
Raise: com.vmware.vapi.std.errors_client.InvalidArgumentiftargetcontains invalid arguments.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifdeployment_speccontains invalid arguments or has attributes that are inconsistent withtarget.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library item specified byovf_library_item_iddoes not exist.Raise: com.vmware.vapi.std.errors_client.NotFoundif any resource specified by a attribute of theLibraryItem.DeploymentTargetclass, specified bytarget, does not exist.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there was an error accessing the OVF package stored in the library item specified byovf_library_item_id.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows :
- Method execution requires VirtualMachine.Config.AddNewDisk if the OVF descriptor has a disk drive (type 17) section.
- Method execution requires VirtualMachine.Config.AdvancedConfig if the OVF descriptor has an ExtraConfig section.
- Method execution requires Extension.Register for specified resource group if the OVF descriptor has a vServiceDependency section.
- Method execution requires Network.Assign for target network if specified.
- Method execution requires Datastore.AllocateSpace for target datastore if specified.
Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
com.vmware.content.library.Itemreferenced by the parameterovf_library_item_idrequiresSystem.Read. - The resource
HostSystemreferenced by the attributeLibraryItem.DeploymentTarget.host_idrequiresSystem.Read. - The resource
Networkreferenced by thedictvalue of attributeLibraryItem.ResourcePoolDeploymentSpec.network_mappingsrequiresSystem.Read. - The resource
StorageProfilereferenced by the attributeLibraryItem.ResourcePoolDeploymentSpec.storage_profile_idrequiresSystem.Read. - The resource
Datastorereferenced by the attributeLibraryItem.ResourcePoolDeploymentSpec.default_datastore_idrequiresSystem.Read. - The resource
ResourcePoolreferenced by the attributeLibraryItem.DeploymentTarget.resource_pool_idrequiresVApp.Import. - The resource
Folderreferenced by the attributeLibraryItem.DeploymentTarget.folder_idrequiresVApp.Import.
- client_token (
-
filter(ovf_library_item_id, target)¶ Queries an OVF package stored in content library to retrieve information to use when deploying the package. See
LibraryItem.deploy().This method retrieves information from the descriptor of the OVF package stored in the library item specified by
ovf_library_item_id. The information returned by the method can be used to populate the deployment specification (seeLibraryItem.ResourcePoolDeploymentSpecwhen deploying the OVF package to the deployment target specified bytarget.Parameters: - ovf_library_item_id (
str) – Identifier of the content library item containing the OVF package to query. The parameter must be an identifier for the resource type:com.vmware.content.library.Item. - target (
LibraryItem.DeploymentTarget) – Specification of the deployment target.
Return type: Returns: Information that can be used to populate the deployment specification (see
LibraryItem.ResourcePoolDeploymentSpec) when deploying the OVF package to the deployment target specified bytarget.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentiftargetcontains invalid arguments.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library item specified byovf_library_item_iddoes not exist.Raise: com.vmware.vapi.std.errors_client.NotFoundif any resource specified by a attribute of theLibraryItem.DeploymentTargetclass, specified bytarget, does not exist.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there was an error accessing the OVF package at the specifiedovf_library_item_id.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
com.vmware.content.library.Itemreferenced by the parameterovf_library_item_idrequiresSystem.Read. - The resource
ResourcePoolreferenced by the attributeLibraryItem.DeploymentTarget.resource_pool_idrequiresSystem.Read. - The resource
HostSystemreferenced by the attributeLibraryItem.DeploymentTarget.host_idrequiresSystem.Read. - The resource
Folderreferenced by the attributeLibraryItem.DeploymentTarget.folder_idrequiresSystem.Read.
- ovf_library_item_id (
- Create a
-
class
com.vmware.vcenter.ovf_client.OvfError(category=None, issues=None, name=None, value=None, message=None, error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
OvfErrorclass describes an error related to accessing, validating, deploying, or exporting an OVF package.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - category (
OvfMessage.Category) – The message category. - issues (
listofParseIssue) –listof parse issues (seeParseIssue). This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.VALIDATION. - name (
str) – The name of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - value (
str) – The value of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - message (
com.vmware.vapi.std_client.LocalizableMessage) – A localizable message. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - error (
vmware.vapi.struct.VapiStruct) – Represents a servercom.vmware.vapi.std.errors_client.Error. When clients pass a value of this class as a parameter, the attribute must contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. When methods return a value of this class as a return value, the attribute will contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.SERVER.
- category (
-
class
com.vmware.vcenter.ovf_client.OvfInfo(messages=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
OvfInfoclass contains informational messages related to accessing, validating, deploying, or exporting an OVF package.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: messages ( listofcom.vmware.vapi.std_client.LocalizableMessage) – Alistof localizable messages (seecom.vmware.vapi.std_client.LocalizableMessage).
-
class
com.vmware.vcenter.ovf_client.OvfMessage(category=None, issues=None, name=None, value=None, message=None, error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
OvfMessageclass describes a base OVF handling error message related to accessing, validating, deploying, or exporting an OVF package.These messages fall into different categories defined in
OvfMessage.Category:Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - category (
OvfMessage.Category) – The message category. - issues (
listofParseIssue) –listof parse issues (seeParseIssue). This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.VALIDATION. - name (
str) – The name of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - value (
str) – The value of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - message (
com.vmware.vapi.std_client.LocalizableMessage) – A localizable message. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - error (
vmware.vapi.struct.VapiStruct) – Represents a servercom.vmware.vapi.std.errors_client.Error. When clients pass a value of this class as a parameter, the attribute must contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. When methods return a value of this class as a return value, the attribute will contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.SERVER.
-
class
Category(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
OvfMessage.Categoryclass defines the categories of messages (seeOvfMessage).Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theCategoryinstance.-
INPUT= Category(string='INPUT')¶ The user provided input parameters are invalid.
-
SERVER= Category(string='SERVER')¶ Server error.
-
VALIDATION= Category(string='VALIDATION')¶ The OVF descriptor is invalid, for example, syntax errors or schema errors.
-
- category (
-
class
com.vmware.vcenter.ovf_client.OvfParams(type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
OvfParamsclass defines the common attributes for all OVF deployment parameters. OVF parameters serve several purposes:- Describe information about a given OVF package.
- Describe default deployment configuration.
- Describe possible deployment values based on the deployment environment.
- Provide deployment-specific configuration.
Each OVF parameters class specifies a particular configurable aspect of OVF deployment. An aspect has both a query-model and a deploy-model. The query-model is used when the OVF package is queried, and the deploy-model is used when deploying an OVF package.
Most OVF parameter classes provide both informational and deployment parameters. However, some are purely informational (for example, download size) and some are purely deployment parameters (for example, the flag to indicate whether registration as a vCenter extension is accepted).
SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: type ( str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
-
class
com.vmware.vcenter.ovf_client.OvfWarning(category=None, issues=None, name=None, value=None, message=None, error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
OvfWarningclass describes a warning related to accessing, validating, deploying, or exporting an OVF package.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - category (
OvfMessage.Category) – The message category. - issues (
listofParseIssue) –listof parse issues (seeParseIssue). This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.VALIDATION. - name (
str) – The name of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - value (
str) – The value of input parameter. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - message (
com.vmware.vapi.std_client.LocalizableMessage) – A localizable message. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.INPUT. - error (
vmware.vapi.struct.VapiStruct) – Represents a servercom.vmware.vapi.std.errors_client.Error. When clients pass a value of this class as a parameter, the attribute must contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. When methods return a value of this class as a return value, the attribute will contain all the attributes defined incom.vmware.vapi.std.errors_client.Error. This attribute is optional and it is only relevant when the value ofcategoryisOvfMessage.Category.SERVER.
- category (
-
class
com.vmware.vcenter.ovf_client.ParseIssue(category=None, file=None, line_number=None, column_number=None, message=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ParseIssueclass contains the information about the issue found when parsing an OVF package during deployment or exporting an OVF package including:- Parsing and validation error on OVF descriptor (which is an XML document), manifest and certificate files.
- OVF descriptor generating and device error.
- Unexpected server error.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - category (
ParseIssue.Category) – The category of the parse issue. - file (
str) – The name of the file in which the parse issue was found. - line_number (
long) – The line number of the line in the file (seeParseIssue.file) where the parse issue was found (or -1 if not applicable). - column_number (
long) – The position in the line (seeParseIssue.line_number) (or -1 if not applicable). - message (
com.vmware.vapi.std_client.LocalizableMessage) – A localizable message describing the parse issue.
-
class
Category(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
ParseIssue.Categoryclass defines the categories of issues that can be found when parsing files inside an OVF package (seeParseIssue) including OVF descriptor (which is an XML document), manifest and certificate files, or exporting an OVF package.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theCategoryinstance.-
ATTRIBUTE_ILLEGAL= Category(string='ATTRIBUTE_ILLEGAL')¶ Illegal attribute error. It indicates that an illegal attribute is set for an element in the OVF descriptor. For example, empty disks do not use format, parentRef, and populatedSize attributes, if these attributes are present in an empty disk element then will get this pasrse issue.
-
ATTRIBUTE_REQUIRED= Category(string='ATTRIBUTE_REQUIRED')¶ Required attribute error. It indicates that a required attribute is missing from an element in the OVF descriptor.
-
ELEMENT_ILLEGAL= Category(string='ELEMENT_ILLEGAL')¶ Illegal element error. It indicates that an element is present in a location which is not allowed, or found multiple elements but only one is allowed at the location in the OVF descriptor.
-
ELEMENT_REQUIRED= Category(string='ELEMENT_REQUIRED')¶ Required element error. It indicates that a required element is missing from the OVF descriptor.
-
ELEMENT_UNKNOWN= Category(string='ELEMENT_UNKNOWN')¶ Unknown element error. It indicates that an element is unsupported when parsing an OVF descriptor.
-
EXPORT_ERROR= Category(string='EXPORT_ERROR')¶ Issue during OVF export, for example, malformed deviceId, controller not found, or file backing for a device not found.
-
GENERATE_ERROR= Category(string='GENERATE_ERROR')¶ OVF descriptor (which is an XML document) generating error, for example, well-formedness errors as well as unexpected processing conditions.
-
INTERNAL_ERROR= Category(string='INTERNAL_ERROR')¶ Server encountered an unexpected error which prevented it from fulfilling the request.
-
PARSE_ERROR= Category(string='PARSE_ERROR')¶ OVF package parsing error, including:
- OVF descriptor parsing errors, for example, syntax errors or schema errors.
- Manifest file parsing and verification errors.
- Certificate file parsing and verification errors.
-
SECTION_RESTRICTION= Category(string='SECTION_RESTRICTION')¶ Section restriction error. It indicates that a section appears in place in the OVF descriptor where it is not allowed, a section appears fewer times than is required, or a section appears more times than is allowed.
-
SECTION_UNKNOWN= Category(string='SECTION_UNKNOWN')¶ Section unknown error. It indicates that a section is unsupported when parsing an OVF descriptor.
-
VALIDATION_ERROR= Category(string='VALIDATION_ERROR')¶ An issue with the manifest and signing.
-
VALUE_ILLEGAL= Category(string='VALUE_ILLEGAL')¶ Illegal value error. For example, the value is malformed, not a number, or outside of the given range, and so on.
-
-
class
com.vmware.vcenter.ovf_client.Property(class_id=None, id=None, instance_id=None, category=None, ui_optional=None, label=None, description=None, type=None, value=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Propertyclass contains the information about a property in an OVF package.A property is uniquely identified by its [classid.]id[.instanceid] fully-qualified name (see
Property.class_id,Property.id, andProperty.instance_id). If multiple properties in an OVF package have the same fully-qualified name, then the property is excluded and cannot be set. We do warn about this during import.SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - class_id (
str) – The classId of this OVF property. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - id (
str) – The identifier of this OVF property. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - instance_id (
str) – The instanceId of this OVF property. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - category (
str) – If this is set to a non-empty string, this property starts a new category. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. If None, the property is in the same category as the previous item, otherwise, it starts a new category. - ui_optional (
bool) –Whether a category is UI optional. This is only used if this property starts a new category (see
Property.category).The value is stored in an optional attribute vmw:uioptional to the ovf:Category element. The default value is false. If this value is true, the properties within this category are optional. The UI renders this as a group with a check box, and the group is grayed out until the check box is selected. When the check box is selected, the input values are read and used in deployment. If properties within the same category specify conflicting values the default is used. Only implemented in vSphere Web Client 5.1 and later as of Nov 2012. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package.
- label (
str) – The display name of this OVF property. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - description (
str) – A description of this OVF property. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. - type (
str) – The type of this OVF property. Refer to the configuration of a virtual appliance/virtual machine for the valid values. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - value (
str) – The OVF property value. This contains the default value from ovf:defaultValue if ovf:value is not present when read. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- class_id (
-
class
com.vmware.vcenter.ovf_client.PropertyParams(properties=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
PropertyParamsclass contains alistof OVF properties that can be configured when the OVF package is deployed.This is based on the ovf:ProductSection.
See
LibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - properties (
listofProperty) –listof OVF properties. This attribute is optional in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- properties (
-
class
com.vmware.vcenter.ovf_client.ScaleOutGroup(id=None, description=None, instance_count=None, minimum_instance_count=None, maximum_instance_count=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ScaleOutGroupclass contains information about a scale-out group.It allows a virtual system collection to contain a set of children that are homogeneous with respect to a prototypical virtual system or virtual system collection. It shall cause the deployment function to replicate the prototype a number of times, thus allowing the number of instantiated virtual systems to be configured dynamically at deployment time.
This is based on the ovf2:ScaleOutSection.
See
LibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - id (
str) – The identifier of the scale-out group. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - description (
str) – The description of the scale-out group. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - instance_count (
long) – The scaling factor to use. It defines the number of replicas of the prototypical virtual system or virtual system collection. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - minimum_instance_count (
long) – The minimum scaling factor. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. This will be 1 if there is no explicit limit. - maximum_instance_count (
long) – The maximum scaling factor. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. This will be None if there is no explicit limit.
- id (
-
class
com.vmware.vcenter.ovf_client.ScaleOutParams(groups=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ScaleOutParamsclass contains information about the scale-out groups described in the OVF package.When deploying an OVF package, a deployment specific instance count can be specified (see
ScaleOutGroup.instance_count.This is based on the ovf2:ScaleOutSection.
See
LibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - groups (
listofScaleOutGroup) – Thelistof scale-out groups. This attribute is optional in the input parameters when deploying an OVF package. If None there are no scale-out groups. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- groups (
-
class
com.vmware.vcenter.ovf_client.SizeParams(approximate_download_size=None, approximate_flat_deployment_size=None, approximate_sparse_deployment_size=None, variable_disk_size=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
SizeParamsclass contains estimates of the download and deployment sizes.This information is based on the file references and the ovf:DiskSection in the OVF descriptor.
SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - approximate_download_size (
long) –A best guess as to the total amount of data that must be transferred to download the OVF package.
This may be inaccurate due to disk compression etc.This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. It will be None if there is insufficient information to provide a proper estimate.
- approximate_flat_deployment_size (
long) – A best guess as to the total amount of space required to deploy the OVF package if using flat disks. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. It will be None if there is insufficient information to provide a proper estimate. - approximate_sparse_deployment_size (
long) – A best guess as to the total amount of space required to deploy the OVF package using sparse disks. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. It will be None if there is insufficient information to provide a proper estimate. - variable_disk_size (
bool) –Whether the OVF uses variable disk sizes.
For empty disks, rather than specifying a fixed virtual disk capacity, the capacity may be given using a reference to a ovf:Property element in a ovf:ProductSection element in OVF package. This attribute is not used in the input parameters when deploying an OVF package. This attribute is optional in the result when retrieving information about an OVF package. If None or false, the OVF does not use variable disk sizes.
- type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- approximate_download_size (
-
class
com.vmware.vcenter.ovf_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
-
class
com.vmware.vcenter.ovf_client.UnknownSection(tag=None, info=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
UnknownSectionclass contains information about an unknown section in an OVF package.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - tag (
str) – A namespace-qualified tag in the form{ns}tag. - info (
str) – The description of the Info element.
- tag (
-
class
com.vmware.vcenter.ovf_client.UnknownSectionParams(unknown_sections=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
UnknownSectionParamsclass contains alistof unknown, non-required sections.SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - unknown_sections (
listofUnknownSection) –listof unknown, non-required sections. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- unknown_sections (
-
class
com.vmware.vcenter.ovf_client.VcenterExtensionParams(required=None, registration_accepted=None, type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
VcenterExtensionParamsclass specifies that the OVF package should be registered as a vCenter extension. The virtual machine or virtual appliance will gain unrestricted access to the vCenter Server APIs. It must be connected to a network with connectivity to the vCenter server.SeeLibraryItem.deploy()andLibraryItem.filter().Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - required (
bool) – Whether registration as a vCenter extension is required. This attribute is not used in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - registration_accepted (
bool) –Whether registration as a vCenter extension is accepted.
If registration as a vCenter extension is required (see
VcenterExtensionParams.required), this must be set to true during deployment. Defaults to false when returned from server. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package. - type (
str) – Unique identifier describing the type of the OVF parameters. The value is the name of the OVF parameters class. This attribute must be provided in the input parameters when deploying an OVF package. This attribute will always be present in the result when retrieving information about an OVF package.
- required (
com.vmware.vcenter.services_client module¶
-
class
com.vmware.vcenter.services_client.Service(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Serviceclass provides methods to manage a single/set of vCenter Server services. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Health(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Service.Healthclass defines the possible values for health of a service. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theHealthinstance.-
DEGRADED= Health(string='DEGRADED')¶ Service is in degraded state, it is not functional. This class attribute was added in vSphere API 6.7.
-
HEALTHY= Health(string='HEALTHY')¶ Service is in a healthy state and is fully functional. This class attribute was added in vSphere API 6.7.
-
HEALTHY_WITH_WARNINGS= Health(string='HEALTHY_WITH_WARNINGS')¶ Service is healthy with warnings. This class attribute was added in vSphere API 6.7.
-
-
class
Info(name_key=None, description_key=None, startup_type=None, state=None, health=None, health_messages=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Service.Infoclass contains information about a service. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name_key (
str) – Service name key. Can be used to lookup resource bundle. This attribute was added in vSphere API 6.7. - description_key (
str) – Service description key. Can be used to lookup resource bundle. This attribute was added in vSphere API 6.7. - startup_type (
Service.StartupType) – Startup Type. This attribute was added in vSphere API 6.7. - state (
Service.State) – Running State. This attribute was added in vSphere API 6.7. - health (
Service.Health) – Health of service. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofstateisService.State.STARTED. - health_messages (
listofcom.vmware.vapi.std_client.LocalizableMessage) – Localizable messages associated with the health of the service. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofstateisService.State.STARTED.
- name_key (
-
class
StartupType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Service.StartupTypeclass defines valid Startup Type for vCenter Server services. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theStartupTypeinstance.-
AUTOMATIC= StartupType(string='AUTOMATIC')¶ Service Startup type is Automatic, thus during starting all services or issuing explicit start on the service will start it. This class attribute was added in vSphere API 6.7.
-
DISABLED= StartupType(string='DISABLED')¶ Service Startup type is Disabled, thus it will not start unless the startup type changes to manual or automatic. This class attribute was added in vSphere API 6.7.
-
MANUAL= StartupType(string='MANUAL')¶ Service Startup type is Manual, thus issuing an explicit start on the service will start it. This class attribute was added in vSphere API 6.7.
-
-
class
State(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Service.Stateclass defines valid Run State for services. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theStateinstance.-
STARTED= State(string='STARTED')¶ Service Run State is Started, it is fully functional. This class attribute was added in vSphere API 6.7.
-
STARTING= State(string='STARTING')¶ Service Run State is Starting, it is still not functional. This class attribute was added in vSphere API 6.7.
-
STOPPED= State(string='STOPPED')¶ Service Run State is Stopped. This class attribute was added in vSphere API 6.7.
-
STOPPING= State(string='STOPPING')¶ Service Run State is Stopping, it is not functional. This class attribute was added in vSphere API 6.7.
-
-
class
UpdateSpec(startup_type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Service.UpdateSpecclass describes the changes to be made to the configuration of the service. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: startup_type ( Service.StartupTypeorNone) – Startup Type. This attribute was added in vSphere API 6.7. If unspecified, leaves value unchanged.
-
get(service)¶ Returns the state of a service. This method was added in vSphere API 6.7.
Parameters: service ( str) – identifier of the service whose state is being queried. The parameter must be an identifier for the resource type:com.vmware.vcenter.services.Service.Return type: Service.InfoReturns: Service Info structure. Raise: com.vmware.vapi.std.errors_client.NotFoundif the service associated withservicedoes not exist.Raise: com.vmware.vapi.std.errors_client.Errorif any other error occurs during the execution of the operation.
-
list_details()¶ Lists details of vCenter services. This method was added in vSphere API 6.7.
Return type: dictofstrandService.InfoReturns: Map of service identifiers to service Info structures. The key in the return value dictwill be an identifier for the resource type:com.vmware.vcenter.services.Service.Raise: com.vmware.vapi.std.errors_client.Errorif any error occurs during the execution of the operation.
-
restart(service)¶ Restarts a service. This method was added in vSphere API 6.7.
Parameters: service ( str) – identifier of the service to restart The parameter must be an identifier for the resource type:com.vmware.vcenter.services.Service.Raise: com.vmware.vapi.std.errors_client.NotFoundif the service associated withservicedoes not exist.Raise: com.vmware.vapi.std.errors_client.TimedOutif any timeout occurs during the execution of the restart operation.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation is denied in the current state of the service. If a stop or start operation is in progress, issuing a restart operation will lead to this error.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif a restart operation is issued on a service which has startup typeService.StartupType.DISABLEDRaise: com.vmware.vapi.std.errors_client.Errorif any other error occurs during the execution of the operation.
-
start(service)¶ Starts a service. This method was added in vSphere API 6.7.
Parameters: service ( str) – identifier of the service to start The parameter must be an identifier for the resource type:com.vmware.vcenter.services.Service.Raise: com.vmware.vapi.std.errors_client.NotFoundif the service associated withservicedoes not exist.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation is denied in the current state of the service. If a stop or restart operation is in progress, the start operation will not be allowed.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif start operation is issued on a service which has startup typeService.StartupType.DISABLED.Raise: com.vmware.vapi.std.errors_client.TimedOutif any timeout occurs during the execution of the start operation. Timeout occurs when the service takes longer than StartTimeout to start.Raise: com.vmware.vapi.std.errors_client.Errorif any other error occurs during the execution of the operation.
-
stop(service)¶ Stops a service. This method was added in vSphere API 6.7.
Parameters: service ( str) – identifier of the service to stop The parameter must be an identifier for the resource type:com.vmware.vcenter.services.Service.Raise: com.vmware.vapi.std.errors_client.NotFoundif the service associated withservicedoes not exist.Raise: com.vmware.vapi.std.errors_client.Errorif any other error occurs during the execution of the operation.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation is denied in the current state of the service. If a stop operation is in progress, issuing another stop operation will lead to this error.
-
update(service, spec)¶ Updates the properties of a service. This method was added in vSphere API 6.7.
Parameters: - service (
str) – identifier of the service whose properties are being updated. The parameter must be an identifier for the resource type:com.vmware.vcenter.services.Service. - spec (
Service.UpdateSpec) – Service Update specification.
Raise: com.vmware.vapi.std.errors_client.NotFoundif the service associated withservicedoes not exist.Raise: com.vmware.vapi.std.errors_client.Errorif any other error occurs during the execution of the operation.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation is denied in the current state of the service. If a start, stop or restart operation is in progress, update operation will fail with this error.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif a request to set theService.UpdateSpec.startup_typeattribute ofspectoService.StartupType.DISABLEDcomes in for a service that is not inService.State.STOPPEDstate.- service (
-
class
-
class
com.vmware.vcenter.services_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.storage_client module¶
-
class
com.vmware.vcenter.storage_client.Policies(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Policiesclass provides methods for managing the storage policies. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
CompatibilityInfo(compatible_datastores=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Policies.CompatibilityInfoclass contains info about a list of datastores compatible with a specific storage policy. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: compatible_datastores ( listofPolicies.CompatibleDatastoreInfo) – Info about a list of datastores compatible with a specific storage policy. This attribute was added in vSphere API 6.7.
-
class
CompatibleDatastoreInfo(datastore=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Policies.CompatibleDatastoreInfoclass contains compatible datastore’s information. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: datastore ( str) – Identifier of the datastore. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore.
-
class
FilterSpec(policies=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Policies.FilterSpecclass contains attributes used to filter the results when listing the storage policies (seePolicies.list()). This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: policies ( setofstrorNone) – Identifiers of storage policies that can match the filter. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vcenter.StoragePolicy. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vcenter.StoragePolicy. If None or empty, storage policies with any identifiers match the filter.
-
RESOURCE_TYPE= 'com.vmware.vcenter.StoragePolicy'¶ Resource type for vAPI metadata policy. This class attribute was added in vSphere API 6.7.
-
class
Summary(policy=None, name=None, description=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Policies.Summaryclass contains commonly used information about a storage policy. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - policy (
str) – Identifier of the storage policy. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.StoragePolicy. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.StoragePolicy. - name (
str) – Name of the storage policy. This attribute was added in vSphere API 6.7. - description (
str) – Description of the storage policy. This attribute was added in vSphere API 6.7.
- policy (
-
check_compatibility(policy, datastores)¶ Returns datastore compatibility summary about a specific storage policy. This method was added in vSphere API 6.7.
Parameters: - policy (
str) – The storage policy identifier The parameter must be an identifier for the resource type:com.vmware.vcenter.StoragePolicy. - datastores (
setofstr) – Datastores used to check compatibility against a storage policy. The number of datastores is limited to 1024. The parameter must contain identifiers for the resource type:Datastore.
Return type: Returns: datastore compatibility summary about a specific storage policy.
Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the storage policy specified does not exist.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif input more than 1024 datastores.- policy (
-
list(filter=None)¶ Returns information about at most 1024 visible (subject to permission checks) storage solicies availabe in vCenter. These storage policies can be used for provisioning virtual machines or disks. This method was added in vSphere API 6.7.
Parameters: filter ( Policies.FilterSpecorNone) – Specification of matching storage policies for which information should be returned. If None, the behavior is equivalent to aPolicies.FilterSpecwith all attributes None which means all storage policies match the filterReturn type: listofPolicies.SummaryReturns: Commonly used Information about the storage policies. Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif thePolicies.FilterSpeccontains a value that is not supported by the server.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif more than 1024 storage policies exist.
-
class
-
class
com.vmware.vcenter.storage_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.system_config_client module¶
-
class
com.vmware.vcenter.system_config_client.DeploymentType(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
DeploymentTypeclass provides methods to get/set the type of the appliance. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(type=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DeploymentType.Infoclass contains the fields used to get the appliance type. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: type ( com.vmware.vcenter.deployment_client.ApplianceType) – The type of the appliance. This attribute was added in vSphere API 6.7.
-
class
ReconfigureSpec(type=None, remote_psc=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DeploymentType.ReconfigureSpecclass contains the fields used to get and set the appliance type. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
com.vmware.vcenter.deployment_client.ApplianceType) – The type of the appliance. This attribute was added in vSphere API 6.7. - remote_psc (
com.vmware.vcenter.deployment_client.RemotePscSpecorNone) – External PSC to register with when reconfiguring a VCSA_EMBEDDED appliance to a VCSA_EXTERNAL appliance. This attribute was added in vSphere API 6.7. Only required when reconfiguring an VCSA_EMBEDDED node to a VCSA_EXTERNAL.
- type (
-
get()¶ Get the type of the vCenter appliance. This method was added in vSphere API 6.7.
Return type: DeploymentType.InfoReturns: The type of the vCenter appliance. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif appliance is not in CONFIGURED state.
-
reconfigure(spec)¶ Reconfigure the type of the vCenter appliance. This method was added in vSphere API 6.7.
Parameters: spec ( DeploymentType.ReconfigureSpec) – ReconfigureSpec to set the appliance type.Raise: com.vmware.vapi.std.errors_client.Unsupportedif the appliance is in CONFIGURED state and if not changing the type form VCSA_EMBEDDED to VCSA_EXTERNAL.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif external PSC credentials are not valid.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is not in INITIALIZED or CONFIGURED state.
-
class
-
class
com.vmware.vcenter.system_config_client.PscRegistration(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
PscRegistrationclass provides methods to get and set the PSC_EXTERNAL appliance a VCSA_EXTERNAL appliance is registered with. This class was added in vSphere API 6.7.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(address=None, https_port=None, sso_domain=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
PscRegistration.Infoclass has fields to specify information about the PSC node. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - address (
str) – The IP address or DNS resolvable name of the PSC this appliance is registered with. This attribute was added in vSphere API 6.7. - https_port (
long) – The HTTPs port used by the external PSC. This attribute was added in vSphere API 6.7. - sso_domain (
str) – The Single Sign-On domain name of the external PSC. This attribute was added in vSphere API 6.7.
- address (
-
get()¶ Get information of the PSC that this appliance is registered with. This method was added in vSphere API 6.7.
Return type: PscRegistration.InfoReturns: Info structure containing information about the external PSC node this appliance is registered with. Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is in NOT_INITIALIZED state.
-
repoint(spec)¶ Repoint this vCenter Server appliance to a different external PSC. This method was added in vSphere API 6.7.
Parameters: spec ( com.vmware.vcenter.deployment_client.RemotePscSpec) – RemotePscSpec structure containing information about the external PSC node to repoint this vCenter Server appliance to.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the caller is not authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the passed external PSC credentials is invalid.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif the passed external PSC is not a replicating with the current PSC this appliance is registered with.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif passed arguments are invalid.Raise: com.vmware.vapi.std.errors_client.Unsupportedif the current appliance is not of the type VCSA_EXTERNAL.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the appliance is NOT in CONFIGURED state.
-
class
-
class
com.vmware.vcenter.system_config_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.vcha_client module¶
The com.vmware.vcenter.vcha_client module provides classes for deploying
and monitoring a vCenter High Availability (VCHA) Cluster.
-
class
com.vmware.vcenter.vcha_client.CertificateInfo(ssl_thumbprint=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CertificateInfoClass contains information about the SSL certificate for a management vCenter server. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: ssl_thumbprint ( str) – The SHA-256 thumbprint of the SSL certificate for a management vCenter server. This attribute was added in vSphere API 6.7 U1.
-
class
com.vmware.vcenter.vcha_client.Cluster(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Clusterclass provides methods to deploy and undeploy a vCenter High Availability (VCHA) cluster, failover from the active VCHA node to the passive VCHA node, and retrieve the status of the VCHA cluster. This class was added in vSphere API 6.7 U1.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
ActiveSpec(ha_network_type=None, ha_network=None, ha_ip=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.ActiveSpecclass contains the deploy specification for the Active Node of the VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - ha_network_type (
NetworkTypeorNone) – The type of the Network object used by the HA network. If theCluster.ActiveSpec.ha_networkattribute is set, then theCluster.ActiveSpec.ha_network_typefield must be set. If theCluster.ActiveSpec.ha_networkattribute is None, then theCluster.ActiveSpec.ha_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. If None and theCluster.ActiveSpec.ha_networkattribute is unset, then the second NIC is assumed to be already configured. If None and theCluster.ActiveSpec.ha_networkattribute is set, then an error is reported. - ha_network (
strorNone) – The identifier of the Network object used for the HA network. If theCluster.ActiveSpec.ha_networkattribute is set, then theCluster.ActiveSpec.ha_network_typeattribute must be set. If theCluster.ActiveSpec.ha_networkattribute is None, then theCluster.ActiveSpec.ha_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network:VCenter. If None and theCluster.ActiveSpec.ha_network_typeattribute is unset, then the second NIC is assumed to be already configured. If None and theCluster.ActiveSpec.ha_networkattribute is set, then an error is reported. - ha_ip (
IpSpec) – IP specification for the HA network. This attribute was added in vSphere API 6.7 U1.
- ha_network_type (
-
class
ClusterMode(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.ClusterModeclass defines the possible modes for a VCHA Cluster. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theClusterModeinstance.-
DISABLED= ClusterMode(string='DISABLED')¶ VCHA Cluster is disabled. State replication between the Active and Passive node is disabled and automatic failover is not allowed. This class attribute was added in vSphere API 6.7 U1.
-
ENABLED= ClusterMode(string='ENABLED')¶ VCHA Cluster is enabled. State replication between the Active and Passive node is enabled and automatic failover is allowed. This class attribute was added in vSphere API 6.7 U1.
-
MAINTENANCE= ClusterMode(string='MAINTENANCE')¶ VCHA Cluster is in maintenance mode. State replication between the Active and Passive node is enabled but automatic failover is not allowed. This class attribute was added in vSphere API 6.7 U1.
-
-
class
ClusterState(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.ClusterStateclass defines the possible for a VCHA Cluster. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theClusterStateinstance.-
DEGRADED= ClusterState(string='DEGRADED')¶ A VCHA Cluster is said to be in a degraded state for either or all of the following reasons:
- There is a node loss.
- State replication between the Active and Passive node fails.
. This class attribute was added in vSphere API 6.7 U1.
-
HEALTHY= ClusterState(string='HEALTHY')¶ All three nodes in a VCHA Cluster are healthy and connected. State replication between Active and Passive node is working and both nodes are in sync. This class attribute was added in vSphere API 6.7 U1.
-
ISOLATED= ClusterState(string='ISOLATED')¶ All three nodes are isolated from each other. This class attribute was added in vSphere API 6.7 U1.
-
-
class
ConfigState(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.ConfigStateclass defines the VCHA configuration state. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theConfigStateinstance.-
CONFIGURED= ConfigState(string='CONFIGURED')¶ VCHA cluster is configured. This class attribute was added in vSphere API 6.7 U1.
-
INVALID= ConfigState(string='INVALID')¶ VCHA cluster is in an invalid/dirty state. This class attribute was added in vSphere API 6.7 U1.
-
NOTCONFIGURED= ConfigState(string='NOTCONFIGURED')¶ VCHA cluster is not configured. This class attribute was added in vSphere API 6.7 U1.
-
PREPARED= ConfigState(string='PREPARED')¶ vCenter server appliance has been prepared for VCHA cluster configuration. This class attribute was added in vSphere API 6.7 U1.
-
-
class
DeploySpec(vc_spec=None, deployment=None, active=None, passive=None, witness=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.DeploySpecclass contains the deploy specification for the three nodes of a VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - vc_spec (
CredentialsSpecorNone) – Contains the active node’s management vCenter server credentials. This attribute was added in vSphere API 6.7 U1. If None, then the active vCenter server is assumed to be managed by itself. - deployment (
Cluster.Type) – Contains the deployment type. This attribute was added in vSphere API 6.7 U1. - active (
Cluster.ActiveSpec) – Contains the active node’s network configuration. This attribute was added in vSphere API 6.7 U1. - passive (
Cluster.PassiveSpec) – Contains the passive node’s placement configuration. This attribute was added in vSphere API 6.7 U1. - witness (
Cluster.WitnessSpec) – Contains the witness node’s placement configuration. This attribute was added in vSphere API 6.7 U1.
- vc_spec (
-
class
ErrorCondition(error=None, recommendation=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.ErrorConditionclass contains an error condition and a recommendation to handle the error condition. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - error (
com.vmware.vapi.std_client.LocalizableMessage) – Contains an error condition. This attribute was added in vSphere API 6.7 U1. - recommendation (
com.vmware.vapi.std_client.LocalizableMessageorNone) – Contains a recommendation on handling the error condition. This attribute was added in vSphere API 6.7 U1. If None, there is no tip for the error condition.
- error (
-
class
Info(config_state=None, node1=None, node2=None, witness=None, mode=None, health_state=None, health_exception=None, health_warnings=None, manual_failover_allowed=None, auto_failover_allowed=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.Infoclass contains the configuration and health information of the three nodes in a VCHA Cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - config_state (
Cluster.ConfigStateorNone) – Configuration state of the VCHA cluster. The active node’s management vCenter server credentials are not required to populate this attribute. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable. - node1 (
Cluster.NodeInfoorNone) – Node configuration information for the VCHA cluster. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable. - node2 (
Cluster.NodeInfoorNone) – Node configuration information for the VCHA cluster. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the node is not cloned yet. - witness (
Cluster.WitnessInfoorNone) – Node configuration information for the VCHA cluster. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the node is not cloned yet. - mode (
Cluster.ClusterModeorNone) – Operational mode of the VCHA Cluster. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the node is not cloned yet. - health_state (
Cluster.ClusterStateorNone) – Last known state of the VCHA Cluster. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the node is not cloned yet. - health_exception (
listofcom.vmware.vapi.std_client.LocalizableMessageorNone) – Health warning messages if the health information is unavailable. This attribute was added in vSphere API 6.7 U1. If None, then the cluster is in a healthy state. - health_warnings (
listofCluster.ErrorConditionorNone) – A collection of messages describing the reason for a non-healthy Cluster. This attribute was added in vSphere API 6.7 U1. If None, then the cluster is in a healthy state. - manual_failover_allowed (
boolorNone) – Specifies if manual failover is allowed. This attribute was added in vSphere API 6.7 U1. If None, then the cluster state healthy and manual failover allowance in accordance with the cluster mode. - auto_failover_allowed (
boolorNone) – Specifies if automatic failover is allowed. This attribute was added in vSphere API 6.7 U1. If None, then the cluster state healthy and automatic failover allowance in accordance with the cluster mode.
- config_state (
-
class
IpFamily(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.IpFamilyclass defines the IP address family. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theIpFamilyinstance.-
IPV4= IpFamily(string='IPV4')¶ IPV4 address family. This class attribute was added in vSphere API 6.7 U1.
-
IPV6= IpFamily(string='IPV6')¶ IPV6 address family. This class attribute was added in vSphere API 6.7 U1.
-
-
class
IpInfo(ip_family=None, ipv4=None, ipv6=None, gateway_ip=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.IpInfoclass contains attributes related to an ip. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - ip_family (
Cluster.IpFamily) – Family of the ip. This attribute was added in vSphere API 6.7 U1. - ipv4 (
Cluster.Ipv4Info) – If the type of the ip family is IPV4, then this will point to IPv4 address specification. This attribute was added in vSphere API 6.7 U1. This attribute is optional and it is only relevant when the value ofipFamilyisCluster.IpFamily.IPV4. - ipv6 (
Cluster.Ipv6Info) – If the type of the ip family is IPV6, then this will point to IPv6 address specification. This attribute was added in vSphere API 6.7 U1. This attribute is optional and it is only relevant when the value ofipFamilyisCluster.IpFamily.IPV6. - gateway_ip (
strorNone) – Gateway IP address. This attribute was added in vSphere API 6.7 U1. If None, no gateway is specified.
- ip_family (
-
class
Ipv4Info(address=None, subnet_mask=None, prefix=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.Ipv4Infoclass contains attributes to describe IPV4 information of the configured network interface. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - address (
str) – IP address of the configured network interface. This attribute was added in vSphere API 6.7 U1. - subnet_mask (
str) – The subnet mask of the interface. This attribute was added in vSphere API 6.7 U1. - prefix (
longorNone) – The CIDR prefix of the interface. This attribute was added in vSphere API 6.7 U1. If None , then the subnet mask is invalid.
- address (
-
class
Ipv6Info(address=None, prefix=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.Ipv6Infoclass contains attributes to describe IPV6 information of the configured network interface. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - address (
str) – IP address of the configured network interface. This attribute was added in vSphere API 6.7 U1. - prefix (
long) – The CIDR prefix of the interface. This attribute was added in vSphere API 6.7 U1.
- address (
-
class
NodeInfo(failover_ip=None, ha_ip=None, runtime=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.NodeInfoclass defines the configuration information for the active and passive nodes in the cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - failover_ip (
Cluster.IpInfoorNone) – Failover IP address that this node will assume after the failover to serve client requests. Each failover node can have a different failover IP address. The active node’s management vCenter server credentials are not required to populateCluster.NodeInfo.failover_ip. This attribute was added in vSphere API 6.7 U1. If None, then it will assume the public IP address of the Active vCenter Server. - ha_ip (
Cluster.IpInfo) – VCHA Cluster network configuration of the node. All cluster communication (state replication, heartbeat, cluster messages) happens over this network. The active node’s management vCenter server credentials are not required to populate thisCluster.NodeInfo.ha_ip. This attribute was added in vSphere API 6.7 U1. - runtime (
Cluster.NodeRuntimeInfoorNone) – Runtime information for the node in the VCHA Cluster. The active node’s management vCenter server credentials are required to populate some attributes ofCluster.NodeInfo.runtime. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the specified Active vCenter server management credentials are invalid or the node is not cloned yet.
- failover_ip (
-
class
NodeRole(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.NodeRoleclass defines the role node can be in a VCHA Cluster. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theNodeRoleinstance.-
ACTIVE= NodeRole(string='ACTIVE')¶ Node is having a role of Active. In this role, node runs a vCenter Server that serves client requests. This class attribute was added in vSphere API 6.7 U1.
-
PASSIVE= NodeRole(string='PASSIVE')¶ Node is having a role of Passive. In this role node, runs as a standby for the Active vCenter Server and receives state updates. This node takes over the role of Active vCenter Server upon failover. This class attribute was added in vSphere API 6.7 U1.
-
WITNESS= NodeRole(string='WITNESS')¶ Node is having a role of Witness. In this role, node acts as a quorum node for avoiding the classic split-brain problem. This class attribute was added in vSphere API 6.7 U1.
-
-
class
NodeRuntimeInfo(state=None, role=None, placement=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.NodeRuntimeInfoclass describes a node’s runtime information in a VCHA Cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - state (
Cluster.NodeStateorNone) – Last known state of the node. The active node’s management vCenter server credentials are not required to populateCluster.NodeRuntimeInfo.state. This attribute was added in vSphere API 6.7 U1. If None, then information is unavailable or the passive and witness nodes are not cloned yet. - role (
Cluster.NodeRoleorNone) – Last known role of the node. The active node’s management vCenter server credentials are not required to populateCluster.NodeRuntimeInfo.role. This attribute was added in vSphere API 6.7 U1. If None, then information is unavailable or the passive and witness nodes are not cloned yet. - placement (
PlacementInfoorNone) – Placement information of the node. The active node’s management vCenter server credentials are required to populate most attributes ofCluster.NodeRuntimeInfo.placement. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the specified Active vCenter server management credentials are invalid or the node is not cloned yet or the VCHA cluster was deployed in a manual fashion.
- state (
-
class
NodeState(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.NodeStateclass defines possible state a node can be in a VCHA Cluster. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theNodeStateinstance.-
DOWN= NodeState(string='DOWN')¶ Node is down and has left the VCHA Cluster. This class attribute was added in vSphere API 6.7 U1.
-
UP= NodeState(string='UP')¶ Node is up and has joined the VCHA Cluster. This class attribute was added in vSphere API 6.7 U1.
-
-
class
NodeVmInfo(vm=None, bios_uuid=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.NodeVmInfoclass contains information to describe the Virtual Machine of a node of a VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - vm (
str) – The identifier of the virtual machine of the VCHA node. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine:VCenter. - bios_uuid (
str) – BIOS UUID for the node. This attribute was added in vSphere API 6.7 U1.
- vm (
-
class
PassiveSpec(placement=None, ha_ip=None, failover_ip=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.PassiveSpecclass contains the deploy specification for the Passive Node of the VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - placement (
PlacementSpecorNone) – Contains the placement configuration of the node. This attribute was added in vSphere API 6.7 U1. If None, then the it is assumed that the clone will be done manually by the customer. In this case, the placement configuration for the witness node should also be omitted. Only the network configuration will be setup. Once the passive and witness nodes are cloned from the active node, the VCHA high availability is turned on. - ha_ip (
IpSpec) – IP specification for the HA network. This attribute was added in vSphere API 6.7 U1. - failover_ip (
IpSpecorNone) – IP specification for the management network. This attribute was added in vSphere API 6.7 U1. If None, then it will assume the public IP address of the Active vCenter Server.
- placement (
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Cluster.Typeclass defines the possible deployment types for a VCHA Cluster. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
AUTO= Type(string='AUTO')¶ Passive and witness nodes are cloned automatically. This class attribute was added in vSphere API 6.7 U1.
-
MANUAL= Type(string='MANUAL')¶ Passive and witness nodes are not cloned automatically. After deployment, the customer should clone the passive and witness virtual machines. This class attribute was added in vSphere API 6.7 U1.
-
-
class
UndeploySpec(vc_spec=None, force_delete=None, vms=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.UndeploySpecclass contains the undeploy specification for a VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - vc_spec (
CredentialsSpecorNone) – Contains the active node’s management vCenter server credentials. This attribute was added in vSphere API 6.7 U1. If None, then the active vCenter server is assumed to be managed by itself. - force_delete (
boolorNone) –Flag controlling in what circumstances the virtual machines will be deleted. For this flag to take effect, the VCHA cluster should have been successfully configured using automatic deployment.
- If true, the
Cluster.UndeploySpec.vmsattribute will be ignored, the VCHA cluster specific information is removed, and the passive and witness virtual machines will be deleted. - If false, the
Cluster.UndeploySpec.vmsattribute contains the information identifying the passive and witness virtual machines. - If the
Cluster.UndeploySpec.vmsattribute is set, then it will be validated prior to deleting the passive and witness virtual machines and VCHA cluster specific information is removed. - If the
Cluster.UndeploySpec.vmsattribute is None, then the passive and witness virtual machines will not be deleted. The customer should delete them in order to cleanup completely. VCHA cluster specific information is removed.
. This attribute was added in vSphere API 6.7 U1. If None, the
Cluster.UndeploySpec.vmsattribute contains the information identifying the passive and witness virtual machines.- If the
Cluster.UndeploySpec.vmsattribute is set, then it will be validated prior to deleting the passive and witness virtual machines. VCHA cluster specific information is removed. - If the
Cluster.UndeploySpec.vmsattribute is None, then the passive and witness virtual machines will not be deleted. The customer should delete them in order to cleanup completely. VCHA cluster specific information is removed.
- If true, the
- vms (
Cluster.VmInfoorNone) –Contains virtual machine information for the passive and witness virtual machines. For this flag to take effect, the VCHA cluster should have been successfully configured using automatic deployment.
If set, the
Cluster.UndeploySpec.force_deleteattribute controls whether this information is validated.- If the
Cluster.UndeploySpec.force_deleteattribute is true, then this information is ignored, VCHA cluster specific information is removed and the passive and witness virtual machines will be deleted. - If the
Cluster.UndeploySpec.force_deleteattribute is None or false, then this information is validated prior to deleting the passive and witness virtual machines. VCHA cluster specific information is removed.
. This attribute was added in vSphere API 6.7 U1. If None, the
Cluster.UndeploySpec.force_deleteattribute controls the deletion of the passive and witness virtual machines.- If the
Cluster.UndeploySpec.force_deleteattribute is true, then the passive and witness virtual machines will be deleted. VCHA cluster specific information is removed. - If the
Cluster.UndeploySpec.force_deleteattribute is None or false, then the passive and witness virtual machines will not be deleted. The customer should delete them in order to cleanup completely. VCHA cluster specific information is removed.
- If the
- vc_spec (
-
class
VmInfo(passive=None, witness=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.VmInfoclass contains information to describe the Virtual Machines of passive and witness nodes of a VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - passive (
Cluster.NodeVmInfo) – The virtual machine information of the passive node. This attribute was added in vSphere API 6.7 U1. - witness (
Cluster.NodeVmInfo) – The virtual machine information of the witness node. This attribute was added in vSphere API 6.7 U1.
- passive (
-
class
WitnessInfo(ha_ip=None, runtime=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.WitnessInfoclass defines the configuration and runtime information for the witness node in the cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - ha_ip (
Cluster.IpInfo) – VCHA Cluster network configuration of the node. All cluster communication (state replication, heartbeat, cluster messages) happens over this network. The active node’s management vCenter server credentials are not required to populateCluster.WitnessInfo.ha_ip. This attribute was added in vSphere API 6.7 U1. - runtime (
Cluster.NodeRuntimeInfoorNone) – Runtime information for the node in the VCHA Cluster. The active node’s management vCenter server credentials are required to populate some attributes ofCluster.WitnessInfo.runtime. This attribute was added in vSphere API 6.7 U1. If None, then the information is unavailable or the node is not cloned yet.
- ha_ip (
-
class
WitnessSpec(placement=None, ha_ip=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Cluster.WitnessSpecclass contains the deploy specification for the Witness Node of the VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - placement (
PlacementSpecorNone) – Contains the placement configuration of the node. This attribute was added in vSphere API 6.7 U1. If None, then it is assumed that the clone will be done manually by the customer. In this case, the placement configuration for the witness node should also be omitted. Only the network configuration will be setup. Once the passive and witness nodes are cloned from the active node, the VCHA high availability is turned on. - ha_ip (
IpSpec) – IP specification for the HA network. This attribute was added in vSphere API 6.7 U1.
- placement (
-
deploy_task(spec)¶ Prepares, clones, and configures a VCHA cluster. This method was added in vSphere API 6.7 U1.
Parameters: spec ( Cluster.DeploySpec) – Contains the deploy specification for all three nodes of a VCHA cluster.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentIf the credentials provided for authenticating with the active node’s management vCenter server are invalid.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user has insufficient privilege to perform the operation. Operation execution requires the Global.VCServer privilege.Raise: com.vmware.vapi.std.errors_client.UnverifiedPeerIf the SSL certificate of the management vCenter server cannot be validated. The value of the data attribute ofcom.vmware.vapi.std.errors_client.Errorwill be a class that contains all the attributes defined inCertificateInfo.Raise: com.vmware.vapi.std.errors_client.ErrorIf any other error occurs.
-
failover_task(planned)¶ Initiates failover from the active vCenter node to the passive node.
For forced failover, Active node immediately initiates a failover. This may result into a data loss after failover.
For planned failover, Active node flushes all the state to the Passive node, waits for the flush to complete before causing a failover. After the failover, Passive node starts without any data loss.
A failover is allowed only in the following cases:- Cluster’s mode is enabled and all cluster members are present.
- Cluster’s mode is maintenance and all cluster members are present.
. This method was added in vSphere API 6.7 U1.
Parameters: planned ( bool) – If false, a failover is initiated immediately and may result in data loss. If true, a failover is initated after the Active node flushes its state to Passive and there is no data loss.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user has insufficient privilege to perform the operation. Operation execution requires the Global.VCServer privilege.Raise: com.vmware.vapi.std.errors_client.ErrorIf any other error occurs.
-
get(vc_spec=None, partial=None)¶ Retrieves the status of a VCHA cluster. This method was added in vSphere API 6.7 U1.
Parameters: - vc_spec (
CredentialsSpecorNone) – Contains active node’s management vCenter server credentials. If None, then the active vCenter server is assumed to be managed by itself. - partial (
boolorNone) –If true, then return only the information that does not require connecting to the Active vCenter Server.
If false or unset, then return all the information.If None, then return all the information.
Return type: Returns: Info structure containing the VCHA configuration and health information.
Raise: com.vmware.vapi.std.errors_client.InvalidArgumentIf the credentials provided for authenticating with the active node’s management vCenter server are invalid.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user has insufficient privilege to perform the operation.- If
partialis false or unset, then the operation execution requires the Global.VCServer privilege. - If
partialis true, then the operation execution requires the System.Read privilege.
Raise: com.vmware.vapi.std.errors_client.UnverifiedPeerIf the SSL certificate of the management vCenter server cannot be validated. The value of the data attribute ofcom.vmware.vapi.std.errors_client.Errorwill be a class that contains all the attributes defined inCertificateInfo.Raise: com.vmware.vapi.std.errors_client.ErrorIf any other error occurs.- vc_spec (
-
undeploy_task(spec)¶ Destroys the VCHA cluster and removes all VCHA specific information from the VCVA appliance. Optionally, the passive and witness node virtual machines will be deleted only if VCHA was deployed using automatic deployment. The active node in the cluster continues to run as a standalone VCVA appliance after the destroy operation has been performed.
If the VCHA cluster is in a transition state and not configured, then the VCHA cluster specific information is removed.. This method was added in vSphere API 6.7 U1.
Parameters: spec ( Cluster.UndeploySpec) – Contains the undeploy specification for a VCHA cluster.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentIf the credentials provided for authenticating with the active node’s management vCenter server are invalid.Raise: com.vmware.vapi.std.errors_client.NotFoundIf the passive virtual machine is not managed by the specified vCenter server.Raise: com.vmware.vapi.std.errors_client.NotFoundIf the witness virtual machine is not managed by the specified vCenter server.Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user has insufficient privilege to perform the operation. Operation execution requires the Global.VCServer privilege.Raise: com.vmware.vapi.std.errors_client.UnverifiedPeerIf the SSL certificate of the management vCenter server cannot be validated. The value of the data attribute ofcom.vmware.vapi.std.errors_client.Errorwill be a class that contains all the attributes defined inCertificateInfo.Raise: com.vmware.vapi.std.errors_client.ErrorIf any other error occurs.
-
class
-
class
com.vmware.vcenter.vcha_client.ConnectionSpec(hostname=None, port=None, ssl_thumbprint=None, username=None, password=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
ConnectionSpecclass contains information required to connect to a vCenter server. The connection to the vCenter server always uses the HTTPS protocol. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - hostname (
str) – IP Address or DNS of the vCenter. This attribute was added in vSphere API 6.7 U1. - port (
longorNone) – Port number. This attribute was added in vSphere API 6.7 U1. If None, port 443 will be used. - ssl_thumbprint (
strorNone) – SHA1 hash of the server SSL certificate. This attribute was added in vSphere API 6.7 U1. If None, empty ssl thumbprint is assumed. - username (
strorNone) – Username to access the server. This attribute was added in vSphere API 6.7 U1. This attribute is currently required. If None, an error is returned. In the future, if this attribute is None, the system will attempt to identify the user. If a user cannot be identified, then the requested operation will fail. - password (
strorNone) – Password for the specified user. This attribute was added in vSphere API 6.7 U1. This attribute is currently required. If None, an empty password is assumed. In the future, if this attribute is None, the system will attempt to authenticate the user. If a user cannot be identified, then the requested operation will fail.
- hostname (
-
class
com.vmware.vcenter.vcha_client.CredentialsSpec(active_location=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
CredentialsSpecclass contains information to connect to the vCenter server managing the VCHA nodes. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: active_location ( ConnectionSpec) – Connection information for the management vCenter Server of the Active Node in a VCHA Cluster. This attribute was added in vSphere API 6.7 U1.
-
class
com.vmware.vcenter.vcha_client.DiskInfo(datastore=None, datastore_name=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DiskInfoclass contains information to describe the storage configuration of a vCenter virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
str) – The identifier of the datastore to put all the virtual disks on. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore:VCenter. - datastore_name (
str) – The name of the datastore. This attribute was added in vSphere API 6.7 U1.
- datastore (
-
class
com.vmware.vcenter.vcha_client.DiskSpec(datastore=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
DiskSpecclass contains information to describe the storage configuration of a vCenter virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: datastore ( strorNone) – The identifier of the datastore to put all the virtual disks on. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore:VCenter. This field needs to be set. If None, then see vim.vm.RelocateSpec.datastore.
-
class
com.vmware.vcenter.vcha_client.IpFamily(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
IpFamilyclass defines the Ip address family. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theIpFamilyinstance.-
IPV4= IpFamily(string='IPV4')¶ IPV4 address family. This class attribute was added in vSphere API 6.7 U1.
-
IPV6= IpFamily(string='IPV6')¶ IPv6 address family. This class attribute was added in vSphere API 6.7 U1.
-
-
class
com.vmware.vcenter.vcha_client.IpSpec(ip_family=None, ipv4=None, ipv6=None, default_gateway=None, dns_servers=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
IpSpecclass contains IP information used to configure a network interface. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - ip_family (
IpFamily) – Family of the IP address to configure the interface. This attribute was added in vSphere API 6.7 U1. - ipv4 (
Ipv4Spec) – If the family of the ip is IPV4, then this will point to IPv4 address specification. This attribute was added in vSphere API 6.7 U1. This attribute is optional and it is only relevant when the value ofipFamilyisIpFamily.IPV4. - ipv6 (
Ipv6Spec) – If the family of the ip is IPV6, then this will point to IPv6 address specification. This attribute was added in vSphere API 6.7 U1. This attribute is optional and it is only relevant when the value ofipFamilyisIpFamily.IPV6. - default_gateway (
strorNone) – The IP address of the Gateway for this interface. This attribute was added in vSphere API 6.7 U1. If None, gateway will not be used for the network interface. - dns_servers (
listofstrorNone) – The list of IP addresses of the DNS servers for this interface. This list is a comma separated list. This attribute was added in vSphere API 6.7 U1. If None, DNS servers will not be used for the network interface.
- ip_family (
-
class
com.vmware.vcenter.vcha_client.Ipv4Spec(address=None, subnet_mask=None, prefix=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Ipv4Specclass contains IPV4 information used to configure a network interface. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - address (
str) – IPV4 address to be used to configure the interface. This attribute was added in vSphere API 6.7 U1. - subnet_mask (
strorNone) – The subnet mask for the interface. This attribute was added in vSphere API 6.7 U1. If None and theprefixattribute is None, then an error will be reported. If None and theprefixattribute is set, then theprefixattribute will be used to create a subnet mask whose first prefix bits are 1 and the remaining bits 0. If both thesubnetMaskattribute and theprefixattribute are set and they do not represent the same value, then an error will be reported. - prefix (
longorNone) – The CIDR prefix for the interface. This attribute was added in vSphere API 6.7 U1. If None and thesubnetMaskattribute is None, this an error will be reported. If None and thesubnetMaskattribute is set, then thesubnetMaskattribute will be used. If both thesubnetMaskattribute and theprefixattribute are set and they do not represent the same value, then an error will be reported.
- address (
-
class
com.vmware.vcenter.vcha_client.Ipv6Spec(address=None, prefix=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Ipv6Specclass contains IPV6 information used to configure a network interface. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - address (
str) – IPv6 address to be used to configure the interface. This attribute was added in vSphere API 6.7 U1. - prefix (
long) – The CIDR prefix for the interface. This attribute was added in vSphere API 6.7 U1.
- address (
-
class
com.vmware.vcenter.vcha_client.NetworkType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
NetworkTypeclass defines the type of a vCenter Server network. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theNetworkTypeinstance.-
DISTRIBUTED_PORTGROUP= NetworkType(string='DISTRIBUTED_PORTGROUP')¶ Distributed virtual switch. This class attribute was added in vSphere API 6.7 U1.
-
STANDARD_PORTGROUP= NetworkType(string='STANDARD_PORTGROUP')¶ vSphere standard portgroup network. This class attribute was added in vSphere API 6.7 U1.
-
-
class
com.vmware.vcenter.vcha_client.Operations(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Operationsclass provides methods to figure out the currently active operations and currently disabled operations in a vCenter High Availability (VCHA) cluster. This class was added in vSphere API 6.7 U1.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
CLUSTER_DEPLOY_OP= 'com.vmware.vcenter.vcha.cluster.deploy'¶ Identifier of the cluster deploy operation. This class attribute was added in vSphere API 6.7 U1.
-
CLUSTER_FAILOVER_OP= 'com.vmware.vcenter.vcha.cluster.failover'¶ Identifier of the cluster failover operation. This class attribute was added in vSphere API 6.7 U1.
-
CLUSTER_GET_OP= 'com.vmware.vcenter.vcha.cluster.get'¶ Identifier of the cluster get operation. This class attribute was added in vSphere API 6.7 U1.
-
CLUSTER_UNDEPLOY_OP= 'com.vmware.vcenter.vcha.cluster.undeploy'¶ Identifier of the cluster undeploy operation. This class attribute was added in vSphere API 6.7 U1.
-
class
Info(disabled=None, active=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Operations.Infoclass contains information about which the VCHA operations cannot be invoked in the current state of the system and the list of currently active VCHA operations. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - disabled (
setofstr) – Identifiers of the operations that are current disabled. These operation strings are one ofOperations.CLUSTER_DEPLOY_OP,Operations.CLUSTER_FAILOVER_OP,Operations.PASSIVE_REDEPLOY_OP,Operations.WITNESS_REDEPLOY_OP,Operations.MODE_SET_OP,Operations.CLUSTER_UNDEPLOY_OPandOperations.CLUSTER_GET_OP. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vapi.operation. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vapi.operation. - active (
setofstr) – Identifiers of the operations that are currently running. These operation strings are one ofOperations.CLUSTER_DEPLOY_OP,Operations.CLUSTER_FAILOVER_OP,Operations.PASSIVE_REDEPLOY_OP,Operations.WITNESS_REDEPLOY_OP,Operations.MODE_SET_OP, andOperations.CLUSTER_UNDEPLOY_OP. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vapi.operation. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vapi.operation.
- disabled (
-
MODE_GET_OP= 'com.vmware.vcenter.vcha.cluster.mode.get'¶ Identifier of the get mode operation. This class attribute was added in vSphere API 6.7 U1.
-
MODE_SET_OP= 'com.vmware.vcenter.vcha.cluster.mode.set'¶ Identifier of the set mode operation. This class attribute was added in vSphere API 6.7 U1.
-
PASSIVE_REDEPLOY_OP= 'com.vmware.vcenter.vcha.cluster.passive.redeploy'¶ Identifier of the passive redeploy operation. This class attribute was added in vSphere API 6.7 U1.
-
WITNESS_REDEPLOY_OP= 'com.vmware.vcenter.vcha.cluster.witness.redeploy'¶ Identifier of the witness redeploy operation. This class attribute was added in vSphere API 6.7 U1.
-
get()¶ Retrieves the current active and disabled operations of a VCHA cluster. This method was added in vSphere API 6.7 U1.
Return type: Operations.InfoReturns: Info structure containing the current running and disabled operations of a VCHA cluster. Raise: com.vmware.vapi.std.errors_client.UnauthorizedIf the user has insufficient privilege to perform the operation. Operation execution requires the System.Read privilege.Raise: com.vmware.vapi.std.errors_client.ErrorIf any other error occurs.
-
-
class
com.vmware.vcenter.vcha_client.PlacementInfo(management_vcenter_name=None, vm_name=None, datacenter=None, datacenter_name=None, host=None, host_name=None, cluster=None, cluster_name=None, ha_network=None, ha_network_name=None, ha_network_type=None, management_network=None, management_network_name=None, management_network_type=None, storage=None, bios_uuid=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
PlacementInfoclass contains information to describe the inventory placement of a single node of a VCHA cluster. The active node’s management vCenter server credentials are required to populate all attributes except biosUuid. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - management_vcenter_name (
str) – The name of the Management vCenter server of the VCHA node. This attribute was added in vSphere API 6.7 U1. - vm_name (
str) – The virtual machine name of the VCHA node. This attribute was added in vSphere API 6.7 U1. - datacenter (
str) – The identifier of the datacenter of the VCHA node. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datacenter:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datacenter:VCenter. - datacenter_name (
str) – The name of the datacenter of the VCHA node. This attribute was added in vSphere API 6.7 U1. - host (
str) – The identifier of the host of the VCHA node. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:HostSystem:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:HostSystem:VCenter. - host_name (
str) – The name of the host of the VCHA node. This attribute was added in vSphere API 6.7 U1. - cluster (
strorNone) – The identifier of the cluster of whichhostis member. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ClusterComputeResource:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ClusterComputeResource:VCenter. If None,hostis a standalone host. - cluster_name (
strorNone) – The name of the cluster of whichhostis member. This attribute was added in vSphere API 6.7 U1. If None,hostis a standalone host. - ha_network (
strorNone) – The identifier of the Network object used for the HA network. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network:VCenter. If None, the information is currently unavailable or the haNetwork is not configured. - ha_network_name (
strorNone) – The name of the Network object used for the HA network. This attribute was added in vSphere API 6.7 U1. If None, the information is currently unavailable or the haNetwork is not configured. - ha_network_type (
NetworkTypeorNone) – The type of the Network object used for the HA network. This attribute was added in vSphere API 6.7 U1. If None, the information is currently unavailable or the haNetwork is not configured. - management_network (
str) – The identifier of the Network object used for the Management network. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network:VCenter. - management_network_name (
str) – The name of the Network object used for the Management network. This attribute was added in vSphere API 6.7 U1. - management_network_type (
NetworkType) – The type of the Network object used for the Management network. This attribute was added in vSphere API 6.7 U1. - storage (
DiskInfo) – The storage information of the VCHA node. This attribute was added in vSphere API 6.7 U1. - bios_uuid (
strorNone) – BIOS UUID for the node. This attribute was added in vSphere API 6.7 U1. If None, the information is currently unavailable.
- management_vcenter_name (
-
class
com.vmware.vcenter.vcha_client.PlacementSpec(name=None, folder=None, host=None, resource_pool=None, ha_network_type=None, ha_network=None, management_network_type=None, management_network=None, storage=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
PlacementSpecclass contains information to describe the inventory placement of a single node of a VCHA cluster. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
str) – The name of the VCHA node to be used for the virtual machine name. This attribute was added in vSphere API 6.7 U1. - folder (
str) – The identifier of the folder to deploy the VCHA node to. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder:VCenter. - host (
strorNone) – The identifier of the host to deploy the VCHA node to. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:HostSystem:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:HostSystem:VCenter. If None, see vim.vm.RelocateSpec.host. - resource_pool (
strorNone) – The identifier of the resource pool to deploy the VCHA node to. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool:VCenter. If None, then the active node’s resource pool will be used. - ha_network_type (
NetworkTypeorNone) – The type of the Network object used by the HA network. If thePlacementSpec.ha_networkattribute is set, then thePlacementSpec.ha_network_typefield must be set. If thePlacementSpec.ha_networkattribute is None, then thePlacementSpec.ha_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. If None and thePlacementSpec.ha_networkattribute is unset, then the same network present on the Active node virtual machine is used to deploy the virtual machine with an assumption that the network is present on the destination. If None and thePlacementSpec.ha_networkattribute is set, then an error is reported. - ha_network (
strorNone) – The identifier of the Network object used for the HA network. If thePlacementSpec.ha_networkattribute is set, then the {#link #haNetworkType} attribute must be set. If thePlacementSpec.ha_networkattribute is None, then thePlacementSpec.ha_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network:VCenter. If None and thePlacementSpec.ha_network_typeattribute is unset, then the same network present on the Active node virtual machine is used to deploy the virtual machine with an assumption that the network is present on the destination. - management_network_type (
NetworkTypeorNone) – The type of the Network object used by the Management network. If thePlacementSpec.management_networkattribute is set, then the {#link #managementNetworkType} field must be set. If thePlacementSpec.management_networkattribute is None, then thePlacementSpec.management_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. If None and thePlacementSpec.management_networkattribute is unset, then the same network present on the Active node virtual machine is used to deploy the virtual machine with an assumption that the network is present on the destination. If None and thePlacementSpec.management_networkattribute is set, then an error is reported. - management_network (
strorNone) – The identifier of the Network object used for the Management network. If thePlacementSpec.management_networkattribute is set, then thePlacementSpec.management_network_typeattribute must be set. If thePlacementSpec.management_networkattribute is None, then thePlacementSpec.management_network_typeattribute is ignored. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network:VCenter. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network:VCenter. If None and thePlacementSpec.management_network_typeattribute is unset, then the same network present on the Active node virtual machine is used to deploy the virtual machine with an assumption that the network is present on the destination. - storage (
DiskSpecorNone) – The storage specification to deploy the VCHA node to. This attribute was added in vSphere API 6.7 U1. If None, see vim.vm.RelocateSpec.datastore.
- name (
-
class
com.vmware.vcenter.vcha_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.vm_client module¶
The com.vmware.vcenter.vm_client module provides classes for managing
virtual machines.
-
class
com.vmware.vcenter.vm_client.GuestOS(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
GuestOSclass defines the valid guest operating system types used for configuring a virtual machine.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theGuestOSinstance.-
AMAZONLINUX2_64= GuestOS(string='AMAZONLINUX2_64')¶ Amazon Linux 2 (64 bit). This class attribute was added in vSphere API 6.7 U1.
-
ASIANUX_3= GuestOS(string='ASIANUX_3')¶ Asianux Server 3
-
ASIANUX_3_64= GuestOS(string='ASIANUX_3_64')¶ Asianux Server 3 (64 bit)
-
ASIANUX_4= GuestOS(string='ASIANUX_4')¶ Asianux Server 4
-
ASIANUX_4_64= GuestOS(string='ASIANUX_4_64')¶ Asianux Server 4 (64 bit)
-
ASIANUX_5_64= GuestOS(string='ASIANUX_5_64')¶ Asianux Server 5 (64 bit)
-
ASIANUX_7_64= GuestOS(string='ASIANUX_7_64')¶ Asianux Server 7 (64 bit)
-
ASIANUX_8_64= GuestOS(string='ASIANUX_8_64')¶ Asianux Server 8 (64 bit). This class attribute was added in vSphere API 6.7.
-
CENTOS= GuestOS(string='CENTOS')¶ CentOS 4/5
-
CENTOS_6= GuestOS(string='CENTOS_6')¶ CentOS 6
-
CENTOS_64= GuestOS(string='CENTOS_64')¶ CentOS 4/5 (64-bit)
-
CENTOS_6_64= GuestOS(string='CENTOS_6_64')¶ CentOS 6 (64-bit)
-
CENTOS_7= GuestOS(string='CENTOS_7')¶ CentOS 7
-
CENTOS_7_64= GuestOS(string='CENTOS_7_64')¶ CentOS 7 (64-bit)
-
CENTOS_8_64= GuestOS(string='CENTOS_8_64')¶ CentOS 8 (64-bit). This class attribute was added in vSphere API 6.7.
-
COREOS_64= GuestOS(string='COREOS_64')¶ CoreOS Linux (64 bit)
-
DARWIN= GuestOS(string='DARWIN')¶ Mac OS 10.5
-
DARWIN_10= GuestOS(string='DARWIN_10')¶ Mac OS 10.6
-
DARWIN_10_64= GuestOS(string='DARWIN_10_64')¶ Mac OS 10.6 (64 bit)
-
DARWIN_11= GuestOS(string='DARWIN_11')¶ Mac OS 10.7
-
DARWIN_11_64= GuestOS(string='DARWIN_11_64')¶ Mac OS 10.7 (64 bit)
-
DARWIN_12_64= GuestOS(string='DARWIN_12_64')¶ Mac OS 10.8 (64 bit)
-
DARWIN_13_64= GuestOS(string='DARWIN_13_64')¶ Mac OS 10.9 (64 bit)
-
DARWIN_14_64= GuestOS(string='DARWIN_14_64')¶ Mac OS 10.10 (64 bit)
-
DARWIN_15_64= GuestOS(string='DARWIN_15_64')¶ Mac OS 10.11 (64 bit)
-
DARWIN_16_64= GuestOS(string='DARWIN_16_64')¶ Mac OS 10.12 (64 bit)
-
DARWIN_17_64= GuestOS(string='DARWIN_17_64')¶ Mac OS 10.13 (64 bit). This class attribute was added in vSphere API 6.7.
-
DARWIN_18_64= GuestOS(string='DARWIN_18_64')¶ Mac OS 10.14 (64 bit). This class attribute was added in vSphere API 6.7.
-
DARWIN_64= GuestOS(string='DARWIN_64')¶ Mac OS 10.5 (64 bit)
-
DEBIAN_10= GuestOS(string='DEBIAN_10')¶ Debian GNU/Linux 10
-
DEBIAN_10_64= GuestOS(string='DEBIAN_10_64')¶ Debian GNU/Linux 10 (64 bit)
-
DEBIAN_4= GuestOS(string='DEBIAN_4')¶ Debian GNU/Linux 4
-
DEBIAN_4_64= GuestOS(string='DEBIAN_4_64')¶ Debian GNU/Linux 4 (64 bit)
-
DEBIAN_5= GuestOS(string='DEBIAN_5')¶ Debian GNU/Linux 5
-
DEBIAN_5_64= GuestOS(string='DEBIAN_5_64')¶ Debian GNU/Linux 5 (64 bit)
-
DEBIAN_6= GuestOS(string='DEBIAN_6')¶ Debian GNU/Linux 6
-
DEBIAN_6_64= GuestOS(string='DEBIAN_6_64')¶ Debian GNU/Linux 6 (64 bit)
-
DEBIAN_7= GuestOS(string='DEBIAN_7')¶ Debian GNU/Linux 7
-
DEBIAN_7_64= GuestOS(string='DEBIAN_7_64')¶ Debian GNU/Linux 7 (64 bit)
-
DEBIAN_8= GuestOS(string='DEBIAN_8')¶ Debian GNU/Linux 8
-
DEBIAN_8_64= GuestOS(string='DEBIAN_8_64')¶ Debian GNU/Linux 8 (64 bit)
-
DEBIAN_9= GuestOS(string='DEBIAN_9')¶ Debian GNU/Linux 9
-
DEBIAN_9_64= GuestOS(string='DEBIAN_9_64')¶ Debian GNU/Linux 9 (64 bit)
-
DOS= GuestOS(string='DOS')¶ MS-DOS.
-
ECOMSTATION= GuestOS(string='ECOMSTATION')¶ eComStation 1.x
-
ECOMSTATION_2= GuestOS(string='ECOMSTATION_2')¶ eComStation 2.0
-
FEDORA= GuestOS(string='FEDORA')¶ Fedora Linux
-
FEDORA_64= GuestOS(string='FEDORA_64')¶ Fedora Linux (64 bit)
-
FREEBSD= GuestOS(string='FREEBSD')¶ FreeBSD 10 or earlier
-
FREEBSD_11= GuestOS(string='FREEBSD_11')¶ FreeBSD 11. This class attribute was added in vSphere API 6.7.
-
FREEBSD_11_64= GuestOS(string='FREEBSD_11_64')¶ FreeBSD 11 x64. This class attribute was added in vSphere API 6.7.
-
FREEBSD_12= GuestOS(string='FREEBSD_12')¶ FreeBSD 12 or later. This class attribute was added in vSphere API 6.7.
-
FREEBSD_12_64= GuestOS(string='FREEBSD_12_64')¶ FreeBSD 12 x64 or later. This class attribute was added in vSphere API 6.7.
-
FREEBSD_64= GuestOS(string='FREEBSD_64')¶ FreeBSD 10 x64 or earlier
-
GENERIC_LINUX= GuestOS(string='GENERIC_LINUX')¶ Other Linux
-
MANDRAKE= GuestOS(string='MANDRAKE')¶ Mandrake Linux
-
MANDRIVA= GuestOS(string='MANDRIVA')¶ Mandriva Linux
-
MANDRIVA_64= GuestOS(string='MANDRIVA_64')¶ Mandriva Linux (64 bit)
-
NETWARE_4= GuestOS(string='NETWARE_4')¶ Novell NetWare 4
-
NETWARE_5= GuestOS(string='NETWARE_5')¶ Novell NetWare 5.1
-
NETWARE_6= GuestOS(string='NETWARE_6')¶ Novell NetWare 6.x
-
NLD_9= GuestOS(string='NLD_9')¶ Novell Linux Desktop 9
-
OES= GuestOS(string='OES')¶ Open Enterprise Server
-
OPENSERVER_5= GuestOS(string='OPENSERVER_5')¶ SCO OpenServer 5
-
OPENSERVER_6= GuestOS(string='OPENSERVER_6')¶ SCO OpenServer 6
-
OPENSUSE= GuestOS(string='OPENSUSE')¶ OpenSUSE Linux
-
OPENSUSE_64= GuestOS(string='OPENSUSE_64')¶ OpenSUSE Linux (64 bit)
-
ORACLE_LINUX= GuestOS(string='ORACLE_LINUX')¶ Oracle Linux 4/5
-
ORACLE_LINUX_6= GuestOS(string='ORACLE_LINUX_6')¶ Oracle Linux 6
-
ORACLE_LINUX_64= GuestOS(string='ORACLE_LINUX_64')¶ Oracle Linux 4/5 (64-bit)
-
ORACLE_LINUX_6_64= GuestOS(string='ORACLE_LINUX_6_64')¶ Oracle Linux 6 (64-bit)
-
ORACLE_LINUX_7= GuestOS(string='ORACLE_LINUX_7')¶ Oracle Linux 7
-
ORACLE_LINUX_7_64= GuestOS(string='ORACLE_LINUX_7_64')¶ Oracle Linux 7 (64-bit)
-
ORACLE_LINUX_8_64= GuestOS(string='ORACLE_LINUX_8_64')¶ Oracle Linux 8 (64-bit). This class attribute was added in vSphere API 6.7.
-
OS2= GuestOS(string='OS2')¶ OS/2
-
OTHER= GuestOS(string='OTHER')¶ Other Operating System
-
OTHER_24X_LINUX= GuestOS(string='OTHER_24X_LINUX')¶ Linux 2.4x Kernel
-
OTHER_24X_LINUX_64= GuestOS(string='OTHER_24X_LINUX_64')¶ Linux 2.4x Kernel (64 bit) (experimental)
-
OTHER_26X_LINUX= GuestOS(string='OTHER_26X_LINUX')¶ Linux 2.6x Kernel
-
OTHER_26X_LINUX_64= GuestOS(string='OTHER_26X_LINUX_64')¶ Linux 2.6x Kernel (64 bit) (experimental)
-
OTHER_3X_LINUX= GuestOS(string='OTHER_3X_LINUX')¶ Linux 3.x Kernel
-
OTHER_3X_LINUX_64= GuestOS(string='OTHER_3X_LINUX_64')¶ Linux 3.x Kernel (64 bit)
-
OTHER_4X_LINUX= GuestOS(string='OTHER_4X_LINUX')¶ Linux 4.x Kernel. This class attribute was added in vSphere API 6.7.
-
OTHER_4X_LINUX_64= GuestOS(string='OTHER_4X_LINUX_64')¶ Linux 4.x Kernel (64 bit). This class attribute was added in vSphere API 6.7.
-
OTHER_64= GuestOS(string='OTHER_64')¶ Other Operating System (64 bit) (experimental)
-
OTHER_LINUX= GuestOS(string='OTHER_LINUX')¶ Linux 2.2x Kernel
-
OTHER_LINUX_64= GuestOS(string='OTHER_LINUX_64')¶ Linux (64 bit) (experimental)
-
REDHAT= GuestOS(string='REDHAT')¶ Red Hat Linux 2.1
-
RHEL_2= GuestOS(string='RHEL_2')¶ Red Hat Enterprise Linux 2
-
RHEL_3= GuestOS(string='RHEL_3')¶ Red Hat Enterprise Linux 3
-
RHEL_3_64= GuestOS(string='RHEL_3_64')¶ Red Hat Enterprise Linux 3 (64 bit)
-
RHEL_4= GuestOS(string='RHEL_4')¶ Red Hat Enterprise Linux 4
-
RHEL_4_64= GuestOS(string='RHEL_4_64')¶ Red Hat Enterprise Linux 4 (64 bit)
-
RHEL_5= GuestOS(string='RHEL_5')¶ Red Hat Enterprise Linux 5
-
RHEL_5_64= GuestOS(string='RHEL_5_64')¶ Red Hat Enterprise Linux 5 (64 bit) (experimental)
-
RHEL_6= GuestOS(string='RHEL_6')¶ Red Hat Enterprise Linux 6
-
RHEL_6_64= GuestOS(string='RHEL_6_64')¶ Red Hat Enterprise Linux 6 (64 bit)
-
RHEL_7= GuestOS(string='RHEL_7')¶ Red Hat Enterprise Linux 7
-
RHEL_7_64= GuestOS(string='RHEL_7_64')¶ Red Hat Enterprise Linux 7 (64 bit)
-
RHEL_8_64= GuestOS(string='RHEL_8_64')¶ Red Hat Enterprise Linux 8 (64 bit). This class attribute was added in vSphere API 6.7.
-
SJDS= GuestOS(string='SJDS')¶ Sun Java Desktop System
-
SLES= GuestOS(string='SLES')¶ Suse Linux Enterprise Server 9
-
SLES_10= GuestOS(string='SLES_10')¶ Suse linux Enterprise Server 10
-
SLES_10_64= GuestOS(string='SLES_10_64')¶ Suse Linux Enterprise Server 10 (64 bit) (experimental)
-
SLES_11= GuestOS(string='SLES_11')¶ Suse linux Enterprise Server 11
-
SLES_11_64= GuestOS(string='SLES_11_64')¶ Suse Linux Enterprise Server 11 (64 bit)
-
SLES_12= GuestOS(string='SLES_12')¶ Suse linux Enterprise Server 12
-
SLES_12_64= GuestOS(string='SLES_12_64')¶ Suse Linux Enterprise Server 12 (64 bit)
-
SLES_15_64= GuestOS(string='SLES_15_64')¶ Suse Linux Enterprise Server 15 (64 bit). This class attribute was added in vSphere API 6.7.
-
SLES_64= GuestOS(string='SLES_64')¶ Suse Linux Enterprise Server 9 (64 bit)
-
SOLARIS_10= GuestOS(string='SOLARIS_10')¶ Solaris 10 (32 bit) (experimental)
-
SOLARIS_10_64= GuestOS(string='SOLARIS_10_64')¶ Solaris 10 (64 bit) (experimental)
-
SOLARIS_11_64= GuestOS(string='SOLARIS_11_64')¶ Solaris 11 (64 bit)
-
SOLARIS_6= GuestOS(string='SOLARIS_6')¶ Solaris 6
-
SOLARIS_7= GuestOS(string='SOLARIS_7')¶ Solaris 7
-
SOLARIS_8= GuestOS(string='SOLARIS_8')¶ Solaris 8
-
SOLARIS_9= GuestOS(string='SOLARIS_9')¶ Solaris 9
-
SUSE= GuestOS(string='SUSE')¶ Suse Linux
-
SUSE_64= GuestOS(string='SUSE_64')¶ Suse Linux (64 bit)
-
TURBO_LINUX= GuestOS(string='TURBO_LINUX')¶ Turbolinux
-
TURBO_LINUX_64= GuestOS(string='TURBO_LINUX_64')¶ Turbolinux (64 bit)
-
UBUNTU= GuestOS(string='UBUNTU')¶ Ubuntu Linux
-
UBUNTU_64= GuestOS(string='UBUNTU_64')¶ Ubuntu Linux (64 bit)
-
UNIXWARE_7= GuestOS(string='UNIXWARE_7')¶ SCO UnixWare 7
-
VMKERNEL= GuestOS(string='VMKERNEL')¶ VMware ESX 4
-
VMKERNEL_5= GuestOS(string='VMKERNEL_5')¶ VMware ESX 5
-
VMKERNEL_6= GuestOS(string='VMKERNEL_6')¶ VMware ESX 6
-
VMKERNEL_65= GuestOS(string='VMKERNEL_65')¶ VMware ESX 6.5
-
VMWARE_PHOTON_64= GuestOS(string='VMWARE_PHOTON_64')¶ VMware Photon (64 bit)
-
WINDOWS_7= GuestOS(string='WINDOWS_7')¶ Windows 7
-
WINDOWS_7_64= GuestOS(string='WINDOWS_7_64')¶ Windows 7 (64 bit)
-
WINDOWS_7_SERVER_64= GuestOS(string='WINDOWS_7_SERVER_64')¶ Windows Server 2008 R2 (64 bit)
-
WINDOWS_8= GuestOS(string='WINDOWS_8')¶ Windows 8
-
WINDOWS_8_64= GuestOS(string='WINDOWS_8_64')¶ Windows 8 (64 bit)
-
WINDOWS_8_SERVER_64= GuestOS(string='WINDOWS_8_SERVER_64')¶ Windows 8 Server (64 bit)
-
WINDOWS_9= GuestOS(string='WINDOWS_9')¶ Windows 10
-
WINDOWS_9_64= GuestOS(string='WINDOWS_9_64')¶ Windows 10 (64 bit)
-
WINDOWS_9_SERVER_64= GuestOS(string='WINDOWS_9_SERVER_64')¶ Windows 10 Server (64 bit)
-
WINDOWS_HYPERV= GuestOS(string='WINDOWS_HYPERV')¶ Windows Hyper-V
-
WIN_2000_ADV_SERV= GuestOS(string='WIN_2000_ADV_SERV')¶ Windows 2000 Advanced Server
-
WIN_2000_PRO= GuestOS(string='WIN_2000_PRO')¶ Windows 2000 Professional
-
WIN_2000_SERV= GuestOS(string='WIN_2000_SERV')¶ Windows 2000 Server
-
WIN_31= GuestOS(string='WIN_31')¶ Windows 3.1
-
WIN_95= GuestOS(string='WIN_95')¶ Windows 95
-
WIN_98= GuestOS(string='WIN_98')¶ Windows 98
-
WIN_LONGHORN= GuestOS(string='WIN_LONGHORN')¶ Windows Longhorn (experimental)
-
WIN_LONGHORN_64= GuestOS(string='WIN_LONGHORN_64')¶ Windows Longhorn (64 bit) (experimental)
-
WIN_ME= GuestOS(string='WIN_ME')¶ Windows Millennium Edition
-
WIN_NET_BUSINESS= GuestOS(string='WIN_NET_BUSINESS')¶ Windows Small Business Server 2003
-
WIN_NET_DATACENTER= GuestOS(string='WIN_NET_DATACENTER')¶ Windows Server 2003, Datacenter Edition
-
WIN_NET_DATACENTER_64= GuestOS(string='WIN_NET_DATACENTER_64')¶ Windows Server 2003, Datacenter Edition (64 bit) (experimental)
-
WIN_NET_ENTERPRISE= GuestOS(string='WIN_NET_ENTERPRISE')¶ Windows Server 2003, Enterprise Edition
-
WIN_NET_ENTERPRISE_64= GuestOS(string='WIN_NET_ENTERPRISE_64')¶ Windows Server 2003, Enterprise Edition (64 bit)
-
WIN_NET_STANDARD= GuestOS(string='WIN_NET_STANDARD')¶ Windows Server 2003, Standard Edition
-
WIN_NET_STANDARD_64= GuestOS(string='WIN_NET_STANDARD_64')¶ Windows Server 2003, Standard Edition (64 bit)
-
WIN_NET_WEB= GuestOS(string='WIN_NET_WEB')¶ Windows Server 2003, Web Edition
-
WIN_NT= GuestOS(string='WIN_NT')¶ Windows NT 4
-
WIN_VISTA= GuestOS(string='WIN_VISTA')¶ Windows Vista
-
WIN_VISTA_64= GuestOS(string='WIN_VISTA_64')¶ Windows Vista (64 bit)
-
WIN_XP_HOME= GuestOS(string='WIN_XP_HOME')¶ Windows XP Home Edition
-
WIN_XP_PRO= GuestOS(string='WIN_XP_PRO')¶ Windows XP Professional
-
WIN_XP_PRO_64= GuestOS(string='WIN_XP_PRO_64')¶ Windows XP Professional Edition (64 bit)
-
-
class
com.vmware.vcenter.vm_client.GuestOSFamily(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
GuestOSFamilyclass defines the valid guest operating system family types reported by a virtual machine. This enumeration was added in vSphere API 6.7.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theGuestOSFamilyinstance.-
DARWIN= GuestOSFamily(string='DARWIN')¶ Mac OS operating system. This class attribute was added in vSphere API 6.7.
-
LINUX= GuestOSFamily(string='LINUX')¶ Linux operating system. This class attribute was added in vSphere API 6.7.
-
NETWARE= GuestOSFamily(string='NETWARE')¶ Novell Netware. This class attribute was added in vSphere API 6.7.
-
OTHER= GuestOSFamily(string='OTHER')¶ Other operating systems. This class attribute was added in vSphere API 6.7.
-
SOLARIS= GuestOSFamily(string='SOLARIS')¶ Solaris operating system. This class attribute was added in vSphere API 6.7.
-
WINDOWS= GuestOSFamily(string='WINDOWS')¶ Windows operating system. This class attribute was added in vSphere API 6.7.
-
-
class
com.vmware.vcenter.vm_client.Hardware(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Hardwareclass provides methods for configuring the virtual hardware of a virtual machine.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(version=None, upgrade_policy=None, upgrade_version=None, upgrade_status=None, upgrade_error=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Hardware.Infoclass contains information related to the virtual hardware of a virtual machine.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - version (
Hardware.Version) – Virtual hardware version. - upgrade_policy (
Hardware.UpgradePolicy) – Scheduled upgrade policy. - upgrade_version (
Hardware.Version) – Target hardware version to be used on the next scheduled virtual hardware upgrade. This attribute is optional and it is only relevant when the value ofupgradePolicyis one ofHardware.UpgradePolicy.AFTER_CLEAN_SHUTDOWNorHardware.UpgradePolicy.ALWAYS. - upgrade_status (
Hardware.UpgradeStatus) – Scheduled upgrade status. - upgrade_error (
Exception) – Reason for the scheduled upgrade failure. This attribute is optional and it is only relevant when the value ofupgradeStatusisHardware.UpgradeStatus.FAILED.
- version (
-
class
UpdateSpec(upgrade_policy=None, upgrade_version=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Hardware.UpdateSpecclass describes the updates to virtual hardware settings of a virtual machine.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - upgrade_policy (
Hardware.UpgradePolicyorNone) –Scheduled upgrade policy.
If set to
Hardware.UpgradePolicy.NEVER, theHardware.Info.upgrade_versionattribute will be reset to None. If None, the value is unchanged. - upgrade_version (
Hardware.VersionorNone) –Target hardware version to be used on the next scheduled virtual hardware upgrade.
If specified, this attribute must represent a newer virtual hardware version than the current virtual hardware version reported in
Hardware.Info.version. IfHardware.UpdateSpec.upgrade_policyis set toHardware.UpgradePolicy.NEVER, this attribute must be None. Otherwise, if this attribute is None, default to the most recent virtual hardware version supported by the server.
- upgrade_policy (
-
class
UpgradePolicy(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Hardware.UpgradePolicyclass defines the valid virtual hardware upgrade policies for a virtual machine.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theUpgradePolicyinstance.-
AFTER_CLEAN_SHUTDOWN= UpgradePolicy(string='AFTER_CLEAN_SHUTDOWN')¶ Run scheduled upgrade when the virtual machine is powered on after a clean shutdown of the guest operating system.
-
ALWAYS= UpgradePolicy(string='ALWAYS')¶ Run scheduled upgrade when the virtual machine is powered on.
-
NEVER= UpgradePolicy(string='NEVER')¶ Do not upgrade the virtual machine when it is powered on.
-
-
class
UpgradeStatus(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Hardware.UpgradeStatusclass defines the valid virtual hardware upgrade statuses for a virtual machine.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theUpgradeStatusinstance.-
FAILED= UpgradeStatus(string='FAILED')¶ The most recent scheduled upgrade was not successful.
-
NONE= UpgradeStatus(string='NONE')¶ No scheduled upgrade has been attempted.
-
PENDING= UpgradeStatus(string='PENDING')¶ Upgrade is scheduled but has not yet been run.
-
SUCCESS= UpgradeStatus(string='SUCCESS')¶ The most recent scheduled upgrade was successful.
-
-
class
Version(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Hardware.Versionclass defines the valid virtual hardware versions for a virtual machine.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theVersioninstance.-
VMX_03= Version(string='VMX_03')¶ Hardware version 3.
-
VMX_04= Version(string='VMX_04')¶ Hardware version 4.
-
VMX_06= Version(string='VMX_06')¶ Hardware version 6.
-
VMX_07= Version(string='VMX_07')¶ Hardware version 7.
-
VMX_08= Version(string='VMX_08')¶ Hardware version 8.
-
VMX_09= Version(string='VMX_09')¶ Hardware version 9.
-
VMX_10= Version(string='VMX_10')¶ Hardware version 10.
-
VMX_11= Version(string='VMX_11')¶ Hardware version 11.
-
VMX_12= Version(string='VMX_12')¶ Hardware version 12.
-
VMX_13= Version(string='VMX_13')¶ Hardware version 13.
-
VMX_14= Version(string='VMX_14')¶ Hardware version 14. This class attribute was added in vSphere API 6.7.
-
-
get(vm)¶ Returns the virtual hardware settings of a virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Return type: Hardware.InfoReturns: Virtual hardware settings of the virtual machine. Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif the virtual machine’s configuration state cannot be accessed.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
update(vm, spec)¶ Updates the virtual hardware settings of a virtual machine.
Parameters: - vm (
str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine. - spec (
Hardware.UpdateSpec) – Specification for updating the virtual hardware settings of the virtual machine.
Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif the virtual machine is already configured for the desired hardware version.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentif the requested virtual hardware version is not newer than the current version.Raise: com.vmware.vapi.std.errors_client.Unsupportedif the requested virtual hardware version is not supported by the server.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is busy performing another operation.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif the virtual machine’s configuration state cannot be accessed.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.- vm (
-
upgrade(vm, version=None)¶ Upgrades the virtual machine to a newer virtual hardware version.
Parameters: - vm (
str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine. - version (
Hardware.VersionorNone) – New virtual machine version. If None, defaults to the most recent virtual hardware version supported by the server.
Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the virtual machine is not powered off.Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif the virtual machine is already configured for the desired hardware version.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifversionis older than the current virtual hardware version.Raise: com.vmware.vapi.std.errors_client.Unsupportedifversionis not supported by the server.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is busy performing another operation.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif the virtual machine’s configuration state cannot be accessed.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.- vm (
-
class
-
class
com.vmware.vcenter.vm_client.Power(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
Powerclass provides methods for managing the power state of a virtual machine.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
Info(state=None, clean_power_off=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
Power.Infoclass contains information about the power state of a virtual machine.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - state (
Power.State) – Power state of the virtual machine. - clean_power_off (
bool) – Flag indicating whether the virtual machine was powered off cleanly. This attribute may be used to detect that the virtual machine crashed unexpectedly and should be restarted. This attribute is optional and it is only relevant when the value ofstateisPower.State.POWERED_OFF.
- state (
-
class
State(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
Power.Stateclass defines the valid power states for a virtual machine.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theStateinstance.-
POWERED_OFF= State(string='POWERED_OFF')¶ The virtual machine is powered off.
-
POWERED_ON= State(string='POWERED_ON')¶ The virtual machine is powered on.
-
SUSPENDED= State(string='SUSPENDED')¶ The virtual machine is suspended.
-
-
get(vm)¶ Returns the power state information of a virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Return type: Power.InfoReturns: Power state information for the specified virtual machine. Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif the virtual machine’s configuration or execution state cannot be accessed.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
reset(vm)¶ Resets a powered-on virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the virtual machine is powered off or suspended.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is performing another operationRaise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
start(vm)¶ Powers on a powered-off or suspended virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif the virtual machine is already powered on.Raise: com.vmware.vapi.std.errors_client.Unsupportedif the virtual machine does not support being powered on (e.g. marked as a template, serving as a fault-tolerance secondary virtual machine).Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif resources cannot be allocated for the virtual machine (e.g. physical resource allocation policy cannot be satisfied, insufficient licenses are available to run the virtual machine).Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif resources required by the virtual machine are not accessible (e.g. virtual machine configuration files or virtual disks are on inaccessible storage, no hosts are available to run the virtual machine).Raise: com.vmware.vapi.std.errors_client.ResourceInUseif resources required by the virtual machine are in use (e.g. virtual machine configuration files or virtual disks are locked, host containing the virtual machine is an HA failover host).Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is performing another operation.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
stop(vm)¶ Powers off a powered-on or suspended virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif the virtual machine is already powered off.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is performing another operation.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
suspend(vm)¶ Suspends a powered-on virtual machine.
Parameters: vm ( str) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the virtual machine is not found.Raise: com.vmware.vapi.std.errors_client.AlreadyInDesiredStateif the virtual machine is already suspended.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the virtual machine is powered off.Raise: com.vmware.vapi.std.errors_client.ResourceBusyif the virtual machine is performing another operation.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif the system is unable to communicate with a service to complete the request.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user can not be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user doesn’t have the required privileges.
-
class
-
class
com.vmware.vcenter.vm_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance
com.vmware.vcenter.vm_template_client module¶
The com.vmware.vcenter.vm_template_client module provides classes and
classes that will let its client manage VMTX template in Content Library.
-
class
com.vmware.vcenter.vm_template_client.LibraryItems(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterfaceThe
LibraryItemsclass provides methods to deploy virtual machines from library items containing virtual machine templates, as well as methods to create library items containing virtual machine templates. TheLibraryItemsclass also provides an operation to retrieve information about the template contained in the library item. This class was added in vSphere API 6.7 U1.Parameters: config ( vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.-
class
CpuInfo(count=None, cores_per_socket=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CpuInfoclass contains CPU related information about the virtual machine template. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - count (
long) – Number of CPU cores. This attribute was added in vSphere API 6.7 U1. - cores_per_socket (
long) – Number of CPU cores per socket. This attribute was added in vSphere API 6.7 U1.
- count (
-
class
CpuUpdateSpec(num_cpus=None, num_cores_per_socket=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CpuUpdateSpecclass describes updates to the CPU configuration of the deployed virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - num_cpus (
longorNone) – Number of virtual processors in the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If {\@term.unset}, the deployed virtual machine has the same CPU count as the source virtual machine template contained in the library item. - num_cores_per_socket (
longorNone) – Number of cores among which to distribute CPUs in the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If {\@term.unset}, the deployed virtual machine has the same number of cores per socket as the source virtual machine template contained in the library item.
- num_cpus (
-
class
CreatePlacementSpec(folder=None, resource_pool=None, host=None, cluster=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreatePlacementSpecclass contains information used to place a virtual machine template onto resources within the vCenter inventory. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - folder (
strorNone) – Virtual machine folder into which the virtual machine template should be placed. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder. If None, the virtual machine template will be placed in the same folder as the source virtual machine. - resource_pool (
strorNone) – Resource pool into which the virtual machine template should be placed. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool. If None, the system will attempt to choose a suitable resource pool for the virtual machine template; if a resource pool cannot be chosen, the library item creation operation will fail. - host (
strorNone) – Host onto which the virtual machine template should be placed. IfhostandresourcePoolare both specified,resourcePoolmust belong tohost. Ifhostandclusterare both specified,hostmust be a member ofcluster. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:HostSystem. This attribute may be None ifresourcePoolorclusteris specified. If None, the system will attempt to choose a suitable host for the virtual machine template; if a host cannot be chosen, the library item creation operation will fail. - cluster (
strorNone) – Cluster onto which the virtual machine template should be placed. IfclusterandresourcePoolare both specified,resourcePoolmust belong tocluster. Ifclusterandhostare both specified,hostmust be a member ofcluster. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ClusterComputeResource. IfresourcePoolorhostis specified, it is recommended that this attribute be None.
- folder (
-
class
CreateSpec(source_vm=None, name=None, description=None, library=None, vm_home_storage=None, disk_storage=None, disk_storage_overrides=None, placement=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreateSpecclass defines the information required to create a library item containing a virtual machine template. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - source_vm (
str) – Identifier of the source virtual machine to create the library item from. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine. - name (
str) – Name of the library item. This attribute was added in vSphere API 6.7 U1. - description (
strorNone) – Description of the library item. This attribute was added in vSphere API 6.7 U1. If None, the newly created library item has the same description as the source virtual machine. - library (
str) – Identifier of the library in which the new library item should be created. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.Library. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.Library. - vm_home_storage (
LibraryItems.CreateSpecVmHomeStorageorNone) – Storage location for the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. If None, the virtual machine template’s configuration and log files are placed on the default storage backing associated with the library specified bylibrary. - disk_storage (
LibraryItems.CreateSpecDiskStorageorNone) –Storage specification for the virtual machine template’s disks. This attribute was added in vSphere API 6.7 U1. If both
diskStorageOverridesanddiskStorageare None, the virtual machine template’s disks are placed in the default storage backing associated with the library specified bylibrary.If
diskStorageOverridesis None anddiskStorageis specified, all of the virtual machine template’s disks are created with the storage spec specified bydiskStorage.If
diskStorageOverridesis specified anddiskStorageis None, disks with identifiers that are not indiskStorageOverridesare placed in the default storage backing associated with the library specified bylibrary.If both
diskStorageOverridesanddiskStorageare specified, disks with identifiers that are not indiskStorageOverridesare created with the storage spec specified bydiskStorage. - disk_storage_overrides ((
dictofstrandLibraryItems.CreateSpecDiskStorage) orNone) –Storage specification for individual disks in the virtual machine template. This is specified as a mapping between disk identifiers in the source virtual machine and their respective storage specifications. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attribute
dictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. If bothdiskStorageOverridesanddiskStorageare None, the virtual machine template’s disks are placed in the default storage backing associated with the library specified bylibrary.If
diskStorageOverridesis None anddiskStorageis specified, all of the virtual machine template’s disks are created with the storage spec specified bydiskStorage.If
diskStorageOverridesis specified anddiskStorageis None, disks with identifiers that are not indiskStorageOverridesare placed in the default storage backing associated with the library specified bylibrary.If both
diskStorageOverridesanddiskStorageare specified, disks with identifiers that are not indiskStorageOverridesare created with the storage spec specified bydiskStorage. - placement (
LibraryItems.CreatePlacementSpecorNone) –Information used to place the virtual machine template. This attribute was added in vSphere API 6.7 U1. This attribute is currently required. In the future, if this attribute is None, the system will place the virtual machine template on a suitable resource.
If specified, each attribute will be used for placement. If the attributes result in disjoint placement, the operation will fail. If the attributes along with the placement values of the source virtual machine result in disjoint placement, the operation will fail.
- source_vm (
-
class
CreateSpecDiskStorage(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreateSpecDiskStorageclass defines the storage specification for a virtual machine template’s disks. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
strorNone) –Identifier for the datastore associated with a virtual machine template’s disk. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. This attribute is currently required. If None,storagePolicymust be set. The server picks a datastore that is compatible with the specified storage policy.If both
datastoreandstoragePolicyare specified, and the storage policy is incompatible with thedatastore, then the disk will be flagged as being out of compliance with the specified storage policy. - storage_policy (
LibraryItems.CreateSpecDiskStoragePolicyorNone) – Storage policy for a virtual machine template’s disk. This attribute was added in vSphere API 6.7 U1. If None,datastoremust be specified and the virtual machine template’s disk is created with the default storage policy associated with thedatastore.
- datastore (
-
class
CreateSpecDiskStoragePolicy(type=None, policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreateSpecDiskStoragePolicyclass defines the storage policy specification for a virtual machine template’s disks. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
LibraryItems.CreateSpecDiskStoragePolicy.Type) – Policy type to be used when creating a virtual machine template’s disk. This attribute was added in vSphere API 6.7 U1. - policy (
str) – Identifier for the storage policy to use. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. This attribute is optional and it is only relevant when the value oftypeisLibraryItems.CreateSpecDiskStoragePolicy.Type.USE_SPECIFIED_POLICY.
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumPolicy type for a virtual machine template’s disk. This enumeration was added in vSphere API 6.7 U1.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
USE_SPECIFIED_POLICY= Type(string='USE_SPECIFIED_POLICY')¶ Use the specified policy. This class attribute was added in vSphere API 6.7 U1.
-
- type (
-
class
CreateSpecVmHomeStorage(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreateSpecVmHomeStorageclass defines the storage specification for a virtual machine template’s configuration and log files. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
strorNone) –Identifier of the datastore for the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. This attribute is currently required. If None,storagePolicymust be set. The server picks a datastore that is compatible with the specified storage policy.If both
datastoreandstoragePolicyare specified, and the storage policy is incompatible with thedatastore, then the virtual machine template will be flagged as being out of compliance with the specified storage policy. - storage_policy (
LibraryItems.CreateSpecVmHomeStoragePolicyorNone) – Storage policy for the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. If None,datastoremust be specified and the virtual machine template’s configuration and log files are created with the default storage policy associated with thedatastore.
- datastore (
-
class
CreateSpecVmHomeStoragePolicy(type=None, policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.CreateSpecVmHomeStoragePolicyclass defines the storage policy specification for a virtual machine template’s configuration and log files. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
LibraryItems.CreateSpecVmHomeStoragePolicy.Type) – Policy type to be used when creating the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. - policy (
str) – Identifier for the storage policy to use. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. This attribute is optional and it is only relevant when the value oftypeisLibraryItems.CreateSpecVmHomeStoragePolicy.Type.USE_SPECIFIED_POLICY.
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumPolicy type for the virtual machine template’s configuration and log files. This enumeration was added in vSphere API 6.7 U1.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
USE_SPECIFIED_POLICY= Type(string='USE_SPECIFIED_POLICY')¶ Use the specified policy. This class attribute was added in vSphere API 6.7 U1.
-
- type (
-
class
DeployPlacementSpec(folder=None, resource_pool=None, host=None, cluster=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeployPlacementSpecclass contains information used to place a virtual machine onto resources within the vCenter inventory. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - folder (
strorNone) –Virtual machine folder into which the deployed virtual machine should be placed. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Folder. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder. This attribute is currently required.If None, the system will attempt to choose a suitable folder for the virtual machine; if a folder cannot be chosen, the virtual machine deployment operation will fail.
- resource_pool (
strorNone) – Resource pool into which the deployed virtual machine should be placed. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool. If None, the system will attempt to choose a suitable resource pool for the virtual machine; if a resource pool cannot be chosen, the virtual machine deployment operation will fail. - host (
strorNone) – Host onto which the virtual machine should be placed. IfhostandresourcePoolare both specified,resourcePoolmust belong tohost. Ifhostandclusterare both specified,hostmust be a member ofcluster. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:HostSystem. This attribute may be None ifresourcePoolorclusteris specified. If None, the system will attempt to choose a suitable host for the virtual machine; if a host cannot be chosen, the virtual machine deployment operation will fail. - cluster (
strorNone) – Cluster onto which the deployed virtual machine should be placed. IfclusterandresourcePoolare both specified,resourcePoolmust belong tocluster. Ifclusterandhostare both specified,hostmust be a member ofcluster. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ClusterComputeResource. IfresourcePoolorhostis specified, it is recommended that this attribute be None.
- folder (
-
class
DeploySpec(name=None, description=None, vm_home_storage=None, disk_storage=None, disk_storage_overrides=None, placement=None, powered_on=None, guest_customization=None, hardware_customization=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeploySpecclass defines the deployment parameters that can be specified for thedeploymethod. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - name (
str) – Name of the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. - description (
strorNone) – Description of the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If None, the deployed virtual machine has the same description as the source library item. - vm_home_storage (
LibraryItems.DeploySpecVmHomeStorageorNone) – Storage location for the deployed virtual machine’s configuration and log files. This attribute was added in vSphere API 6.7 U1. If None, the deployed virtual machine’s configuration and log files are created with the same storage spec as the source virtual machine template’s configuration and log files. - disk_storage (
LibraryItems.DeploySpecDiskStorageorNone) –Storage specification for the deployed virtual machine’s disks. This attribute was added in vSphere API 6.7 U1. If both
diskStorageOverridesanddiskStorageare None, the deployed virtual machine’s disks are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.If
diskStorageOverridesis None anddiskStorageis specified, all of the deployed virtual machine’s disks are created with the storage spec specified bydiskStorage.If
diskStorageOverridesis specified anddiskStorageis None, disks with identifiers that are not indiskStorageOverridesare created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.If both
diskStorageOverridesanddiskStorageare specified, disks with identifiers that are not indiskStorageOverridesare created with the storage spec specified bydiskStorage. - disk_storage_overrides ((
dictofstrandLibraryItems.DeploySpecDiskStorage) orNone) –Storage specification for individual disks in the deployed virtual machine. This is specified as a mapping between disk identifiers in the source virtual machine template contained in the library item and their storage specifications. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attribute
dictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. If bothdiskStorageOverridesanddiskStorageare None, the deployed virtual machine’s disks are created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.If
diskStorageOverridesis None anddiskStorageis specified, all of the deployed virtual machine’s disks are created with the storage spec specified bydiskStorage.If
diskStorageOverridesis specified anddiskStorageis None, disks with identifiers that are not indiskStorageOverridesare created with the same storage spec as the corresponding disks in the source virtual machine template contained in the library item.If both
diskStorageOverridesanddiskStorageare specified, disks with identifiers that are not indiskStorageOverridesare created with the storage spec specified bydiskStorage. - placement (
LibraryItems.DeployPlacementSpecorNone) –Information used to place the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. This attribute is currently required. In the future, if this attribute is None, the system will use the values from the source virtual machine template contained in the library item.
If specified, each attribute will be used for placement. If the attributes result in disjoint placement, the operation will fail. If the attributes along with the placement values of the source virtual machine template result in disjoint placement, the operation will fail.
- powered_on (
boolorNone) – Specifies whether the deployed virtual machine should be powered on after deployment. This attribute was added in vSphere API 6.7 U1. If None, the virtual machine will not be powered on after deployment. - guest_customization (
LibraryItems.GuestCustomizationSpecorNone) – Guest customization spec to apply to the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If None, the guest operating system is not customized after deployment. - hardware_customization (
LibraryItems.HardwareCustomizationSpecorNone) – Hardware customization spec which specifies updates to the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If None, the deployed virtual machine has the same hardware configuration as the source virtual machine template contained in the library item.
- name (
-
class
DeploySpecDiskStorage(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeploySpecDiskStorageclass contains the storage specification for disks in the virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
strorNone) –Identifier for the datastore associated the deployed virtual machine’s disk. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. This attribute is currently required. If None,storagePolicymust be set. The server picks a datastore that is compatible with the specified storage policy.If both
datastoreandstoragePolicyare specified, and the storage policy is incompatible with thedatastore, then the disk will be flagged as being out of compliance with the specified storage policy. - storage_policy (
LibraryItems.DeploySpecDiskStoragePolicyorNone) – Storage policy for the deployed virtual machine’s disk. This attribute was added in vSphere API 6.7 U1. If None,datastoremust be specified and the deployed virtual machine’s disk is created with the default storage policy associated with thedatastore.
- datastore (
-
class
DeploySpecDiskStoragePolicy(type=None, policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeploySpecDiskStoragePolicyclass describes the storage policy specification for the deployed virtual machine’s disks. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
LibraryItems.DeploySpecDiskStoragePolicy.Type) – Policy type to be used when creating the deployed virtual machine’s disk. This attribute was added in vSphere API 6.7 U1. - policy (
str) – Identifier of the storage policy to use. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. This attribute is optional and it is only relevant when the value oftypeisLibraryItems.DeploySpecDiskStoragePolicy.Type.USE_SPECIFIED_POLICY.
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumPolicy type for the deployed virtual machine’s disk. This enumeration was added in vSphere API 6.7 U1.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
USE_SOURCE_POLICY= Type(string='USE_SOURCE_POLICY')¶ Use the storage policy that is associated with the corresponding disk in the source virtual machine template. This class attribute was added in vSphere API 6.7 U1.
-
USE_SPECIFIED_POLICY= Type(string='USE_SPECIFIED_POLICY')¶ Use the specified policy. This class attribute was added in vSphere API 6.7 U1.
-
- type (
-
class
DeploySpecVmHomeStorage(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeploySpecVmHomeStorageclass defines the storage specification for a deployed virtual machine’s configuration and log files. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
strorNone) –Identifier of the datastore for the deployed virtual machine’s configuration and log files. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. This attribute is currently required. If None,storagePolicymust be set. The server picks a datastore that is compatible with the specified storage policy.If both
datastoreandstoragePolicyare specified, and the storage policy is incompatible with thedatastore, then the deployed virtual machine will be flagged as being out of compliance with the specified storage policy. - storage_policy (
LibraryItems.DeploySpecVmHomeStoragePolicyorNone) – Storage policy for the deployed virtual machine’s configuration and log files. This attribute was added in vSphere API 6.7 U1. If None,datastoremust be specified and the deployed virtual machine’s configuration and log files are created with the default storage policy associated with thedatastore.
- datastore (
-
class
DeploySpecVmHomeStoragePolicy(type=None, policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DeploySpecVmHomeStoragePolicyclass defines the storage policy specification for the deployed virtual machine’s configuration and log files. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - type (
LibraryItems.DeploySpecVmHomeStoragePolicy.Type) – Policy type to be used when creating the deployed virtual machine’s configuration and log files. This attribute was added in vSphere API 6.7 U1. - policy (
str) – Identifier for the storage policy to use. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. This attribute is optional and it is only relevant when the value oftypeisLibraryItems.DeploySpecVmHomeStoragePolicy.Type.USE_SPECIFIED_POLICY.
-
class
Type(string)¶ Bases:
vmware.vapi.bindings.enum.EnumPolicy type for the deployed virtual machine’s configuration and log files. This enumeration was added in vSphere API 6.7 U1.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theTypeinstance.-
USE_SOURCE_POLICY= Type(string='USE_SOURCE_POLICY')¶ Use the storage policy that is associated with the source virtual machine template’s configuration and log files. This class attribute was added in vSphere API 6.7 U1.
-
USE_SPECIFIED_POLICY= Type(string='USE_SPECIFIED_POLICY')¶ Use the specified policy. This class attribute was added in vSphere API 6.7 U1.
-
- type (
-
class
DiskInfo(capacity=None, disk_storage=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DiskInfoclass contains information about the virtual machine template’s virtual disk. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - capacity (
longorNone) – Capacity of the virtual disk in bytes. This attribute was added in vSphere API 6.7 U1. This attribute will be None if the virtual disk is inaccessible. - disk_storage (
LibraryItems.DiskStorageInfo) – Disk storage related information. This attribute was added in vSphere API 6.7 U1.
- capacity (
-
class
DiskStorageInfo(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DiskStorageInfoclass contains storage related information about a virtual machine template’s virtual disk. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
str) – Identifier of the datastore where the disk is stored. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. - storage_policy (
strorNone) – Identifier of the storage policy associated with the virtual disk. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. If None, the virtual disk does not have a storage policy associated with it.
- datastore (
-
class
DiskUpdateSpec(capacity=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.DiskUpdateSpecclass describes updates to the configuration of a virtual disk in the deployed virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: capacity ( long) – Updated capacity of the virtual disk backing in bytes. This value has to be larger than the original capacity of the disk. This attribute was added in vSphere API 6.7 U1.
-
class
EthernetInfo(backing_type=None, mac_type=None, network=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.EthernetInfoclass contains information about a virtual machine template’s virtual Ethernet adapter. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - backing_type (
LibraryItems.EthernetInfo.NetworkBackingType) – Network backing type for the virtual Ethernet adapter. This attribute was added in vSphere API 6.7 U1. - mac_type (
LibraryItems.EthernetInfo.MacAddressType) – MAC address type of the ethernet adapter. This attribute was added in vSphere API 6.7 U1. - network (
strorNone) – Identifier of the network backing the virtual Ethernet adapter. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network. This attribute will be None if the identifier of the network backing could not be determined.
-
class
MacAddressType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
LibraryItems.EthernetInfo.MacAddressTypeclass defines the valid MAC address origins for a virtual Ethernet adapter. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theMacAddressTypeinstance.-
ASSIGNED= MacAddressType(string='ASSIGNED')¶ MAC address is assigned by vCenter Server. This class attribute was added in vSphere API 6.7 U1.
-
GENERATED= MacAddressType(string='GENERATED')¶ MAC address is generated automatically. This class attribute was added in vSphere API 6.7 U1.
-
MANUAL= MacAddressType(string='MANUAL')¶ MAC address is assigned statically. This class attribute was added in vSphere API 6.7 U1.
-
-
class
NetworkBackingType(string)¶ Bases:
vmware.vapi.bindings.enum.EnumThe
LibraryItems.EthernetInfo.NetworkBackingTypeclass defines valid network backing types for a virtual Ethernet adapter. This enumeration was added in vSphere API 6.7 U1.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: string ( str) – String value for theNetworkBackingTypeinstance.-
DISTRIBUTED_PORTGROUP= NetworkBackingType(string='DISTRIBUTED_PORTGROUP')¶ Distributed virtual switch backing. This class attribute was added in vSphere API 6.7 U1.
-
HOST_DEVICE= NetworkBackingType(string='HOST_DEVICE')¶ Legacy host device network backing. Imported VMs may have virtual Ethernet adapters with this type of backing, but this type of backing cannot be used to create or to update a virtual Ethernet adapter. This class attribute was added in vSphere API 6.7 U1.
-
OPAQUE_NETWORK= NetworkBackingType(string='OPAQUE_NETWORK')¶ Opaque network backing. This class attribute was added in vSphere API 6.7 U1.
-
STANDARD_PORTGROUP= NetworkBackingType(string='STANDARD_PORTGROUP')¶ vSphere standard portgroup network backing. This class attribute was added in vSphere API 6.7 U1.
-
- backing_type (
-
class
EthernetUpdateSpec(network=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.EthernetUpdateSpecclass describes the network that the ethernet adapter of the deployed virtual machine should be connected to. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: network ( strorNone) –Identifier of the network backing the virtual Ethernet adapter. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:
Network. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network. This attribute is currently required.If None, the virtual Ethernet adapter will be connected to same network as it was in the source virtual machine template.
-
class
GuestCustomizationSpec(name=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.GuestCustomizationSpecclass contains information required to customize the deployed virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: name ( strorNone) – Name of the customization specification. This attribute was added in vSphere API 6.7 U1. If None, no guest customization is performed.
-
class
HardwareCustomizationSpec(nics=None, disks_to_remove=None, disks_to_update=None, cpu_update=None, memory_update=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.HardwareCustomizationSpecclass defines the hardware customization options that are applied to the deployed virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - nics ((
dictofstrandLibraryItems.EthernetUpdateSpec) orNone) – Map of Ethernet network adapters to update. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attributedictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet. If None, all Ethernet adapters will remain connected to the same network as they were in the source virtual machine template. An Ethernet adapter with a MacAddressType of MANUAL will not change. An Ethernet adapter with a MacAddressType of GENERATED or ASSIGNED will receive a new address. - disks_to_remove (
setofstrorNone) – Idenfiers of disks to remove from the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vcenter.vm.hardware.Disk. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vcenter.vm.hardware.Disk. If None, all disks will be copied. - disks_to_update ((
dictofstrandLibraryItems.DiskUpdateSpec) orNone) – Disk update specification for individual disks in the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attributedictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. If None, disks in the deployed virtual machine will have the same settings as the corresponding disks in the source virtual machine template contained in the library item. - cpu_update (
LibraryItems.CpuUpdateSpecorNone) – CPU update specification for the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If {\@term.unset}, the deployed virtual machine has the same CPU settings as the source virtual machine template contained in the library item. - memory_update (
LibraryItems.MemoryUpdateSpecorNone) – Memory update specification for the deployed virtual machine. This attribute was added in vSphere API 6.7 U1. If {\@term.unset}, the deployed virtual machine has the same memory settings as the source virtual machine template contained in the library item.
- nics ((
-
class
Info(guest_os=None, cpu=None, memory=None, vm_home_storage=None, disks=None, nics=None, vm_template=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.Infoclass contains information about a virtual machine template item in content library. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - guest_os (
com.vmware.vcenter.vm_client.GuestOS) – Configured guest operating system of the virtual machine template. This attribute was added in vSphere API 6.7 U1. - cpu (
LibraryItems.CpuInfo) – CPU configuration of the virtual machine template. This attribute was added in vSphere API 6.7 U1. - memory (
LibraryItems.MemoryInfo) – Memory configuration of the virtual machine template. This attribute was added in vSphere API 6.7 U1. - vm_home_storage (
LibraryItems.VmHomeStorageInfo) – Storage information about the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. - disks (
dictofstrandLibraryItems.DiskInfo) – Storage information about the virtual machine template’s virtual disks. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attributedictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk. - nics (
dictofstrandLibraryItems.EthernetInfo) – Information about the virtual machine template’s virtual ethernet adapters. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the key in the attributedictmust be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet. When methods return a value of this class as a return value, the key in the attributedictwill be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet. - vm_template (
str) – Identifier of the virtual machine template contained in the library item. This field is used to identify the virtual machine template in legacy APIs. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine.
- guest_os (
-
class
MemoryInfo(size_mib=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.MemoryInfoclass contains memory related information about the virtual machine template. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: size_mib ( long) – Memory size in mebibytes. This attribute was added in vSphere API 6.7 U1.
-
class
MemoryUpdateSpec(memory=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.MemoryUpdateSpecclass describes updates to the memory configuration of the deployed virtual machine. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: memory ( longorNone) – Size of a virtual machine’s memory in MB. This attribute was added in vSphere API 6.7 U1. If {\@term.unset}, the deployed virtual machine has the same memory size as the source virtual machine template.
-
class
VmHomeStorageInfo(datastore=None, storage_policy=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStructThe
LibraryItems.VmHomeStorageInfoclass contains storage information about the virtual machine template’s configuration and log files. This class was added in vSphere API 6.7 U1.Tip
The arguments are used to initialize data attributes with the same names.
Parameters: - datastore (
str) – Identifier of the datastore where the virtual machine template’s configuration and log files are stored. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore. - storage_policy (
strorNone) – Identifier of the storage policy associated with the virtual machine template’s configuration and log files. This attribute was added in vSphere API 6.7 U1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.spbm.StorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.spbm.StorageProfile. If None, the virtual machine template’s configuration and log files do not have a storage policy associated with them.
- datastore (
-
create(spec)¶ Creates a library item in content library from a virtual machine. This method creates a library item in content library whose content is a virtual machine template created from the source virtual machine, using the supplied create specification. The virtual machine template is stored in a newly created library item. This method was added in vSphere API 6.7 U1.
Parameters: spec (
LibraryItems.CreateSpec) – information used to create the library item from the source virtual machine.Return type: strReturns: Identifier of the newly created library item. The return value will be an identifier for the resource type:
com.vmware.content.library.Item.Raise: com.vmware.vapi.std.errors_client.AlreadyExistsif an entity with the name specified byLibraryItems.CreateSpec.namealready exists in the folder specified byLibraryItems.CreatePlacementSpec.folder.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifLibraryItems.CreateSpeccontains invalid arguments.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif the operation cannot be performed because of the source virtual machine’s current state.Raise: com.vmware.vapi.std.errors_client.NotFoundif the source virtual machine specified byLibraryItems.CreateSpec.source_vmdoes not exist.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library specified byLibraryItems.CreateSpec.librarydoes not exist.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there was an error accessing a file from the source virtual machine.Raise: com.vmware.vapi.std.errors_client.ResourceInUseif the source virtual machine is busy.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif any of the services involved in the method are unavailable.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif any of the resources needed to create the virtual machine template could not be allocated.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user that requested the method cannot be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user that requested the method is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
com.vmware.content.Libraryreferenced by the attributeLibraryItems.CreateSpec.libraryrequiresContentLibrary.AddLibraryItem. - The resource
VirtualMachinereferenced by the attributeLibraryItems.CreateSpec.source_vmrequiresSystem.Read. - The resource
Datastorereferenced by the attributeLibraryItems.CreateSpecVmHomeStorage.datastorerequiresSystem.Read. - The resource
com.vmware.spbm.StorageProfilereferenced by the attributeLibraryItems.CreateSpecVmHomeStoragePolicy.policyrequiresSystem.Read. - The resource
Datastorereferenced by the attributeLibraryItems.CreateSpecDiskStorage.datastorerequiresSystem.Read. - The resource
com.vmware.spbm.StorageProfilereferenced by the attributeLibraryItems.CreateSpecDiskStoragePolicy.policyrequiresSystem.Read. - The resource
com.vmware.vcenter.vm.hardware.Diskreferenced by thedictkey of attributeLibraryItems.CreateSpec.disk_storage_overridesrequiresSystem.Read. - The resource
Folderreferenced by the attributeLibraryItems.CreatePlacementSpec.folderrequiresSystem.Read. - The resource
ResourcePoolreferenced by the attributeLibraryItems.CreatePlacementSpec.resource_poolrequiresSystem.Read. - The resource
HostSystemreferenced by the attributeLibraryItems.CreatePlacementSpec.hostrequiresSystem.Read. - The resource
ClusterComputeResourcereferenced by the attributeLibraryItems.CreatePlacementSpec.clusterrequiresSystem.Read.
- Method execution requires
-
deploy(template_library_item, spec)¶ Deploys a virtual machine as a copy of the source virtual machine template contained in the library item specified by
template_library_item. It uses the deployment specification inspec. IfLibraryItems.DeploySpec.powered_onand/orLibraryItems.DeploySpec.guest_customizationare specified, the server triggers the power on and/or guest customization operations, which are executed asynchronously. This method was added in vSphere API 6.7 U1.Parameters: - template_library_item (
str) – identifier of the content library item containing the source virtual machine template to be deployed. The parameter must be an identifier for the resource type:com.vmware.content.library.Item. - spec (
LibraryItems.DeploySpec) – specification of how the virtual machine should be deployed.
Return type: strReturns: Identifier of the deployed virtual machine. The return value will be an identifier for the resource type:
VirtualMachine.Raise: com.vmware.vapi.std.errors_client.AlreadyExistsif a virtual machine with the name specified byLibraryItems.DeploySpec.namealready exists.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.InvalidArgumentifspeccontains invalid arguments.Raise: com.vmware.vapi.std.errors_client.NotAllowedInCurrentStateif either a specified host or a specified datastore is in an invalid state for the deployment, such as maintenance mode.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library item specified bytemplate_library_itemcannot be found.Raise: com.vmware.vapi.std.errors_client.NotFoundif any resource specified by a attribute of theLibraryItems.DeploySpecclass, specified byspeccannot be found.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there was an error accessing the source virtual machine template contained in the library item specified bytemplate_library_item.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif there an error accessing any of the resources specified in thespec.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif any of the services involved in the method are unavailable.Raise: com.vmware.vapi.std.errors_client.UnableToAllocateResourceif there was an error in allocating any of the resources required by the method.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user that requested the method cannot be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user that requested the method is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
com.vmware.content.library.Itemreferenced by the parametertemplate_library_itemrequiresVirtualMachine.Provisioning.DeployTemplate. - The resource
Datastorereferenced by the attributeLibraryItems.DeploySpecVmHomeStorage.datastorerequiresSystem.Read. - The resource
com.vmware.spbm.StorageProfilereferenced by the attributeLibraryItems.DeploySpecVmHomeStoragePolicy.policyrequiresSystem.Read. - The resource
Datastorereferenced by the attributeLibraryItems.DeploySpecDiskStorage.datastorerequiresSystem.Read. - The resource
com.vmware.spbm.StorageProfilereferenced by the attributeLibraryItems.DeploySpecDiskStoragePolicy.policyrequiresSystem.Read. - The resource
com.vmware.vcenter.vm.hardware.Diskreferenced by thedictkey of attributeLibraryItems.DeploySpec.disk_storage_overridesrequiresSystem.Read. - The resource
Folderreferenced by the attributeLibraryItems.DeployPlacementSpec.folderrequiresSystem.Read. - The resource
ResourcePoolreferenced by the attributeLibraryItems.DeployPlacementSpec.resource_poolrequiresSystem.Read. - The resource
HostSystemreferenced by the attributeLibraryItems.DeployPlacementSpec.hostrequiresSystem.Read. - The resource
ClusterComputeResourcereferenced by the attributeLibraryItems.DeployPlacementSpec.clusterrequiresSystem.Read. - The resource
com.vmware.vcenter.vm.hardware.Ethernetreferenced by thedictkey of attributeLibraryItems.HardwareCustomizationSpec.nicsrequiresSystem.Read. - The resource
Networkreferenced by the attributeLibraryItems.EthernetUpdateSpec.networkrequiresSystem.Read. - The resource
com.vmware.vcenter.vm.hardware.Diskreferenced by the attributeLibraryItems.HardwareCustomizationSpec.disks_to_removerequiresSystem.Read. - The resource
com.vmware.vcenter.vm.hardware.Diskreferenced by thedictkey of attributeLibraryItems.HardwareCustomizationSpec.disks_to_updaterequiresSystem.Read.
- template_library_item (
-
get(template_library_item)¶ Returns information about a virtual machine template contained in the library item specified by
template_library_item. This method was added in vSphere API 6.7 U1.Parameters: template_library_item (
str) – identifier of the library item containing the virtual machine template. The parameter must be an identifier for the resource type:com.vmware.content.library.Item.Return type: LibraryItems.InfoorNoneReturns: Information about the virtual machine template item contained in the library item. If None, the library item specified by
template_library_itemdoes not contain a virtual machine template.Raise: com.vmware.vapi.std.errors_client.Errorif the system reports an error while responding to the request.Raise: com.vmware.vapi.std.errors_client.NotFoundif the library item could not be found.Raise: com.vmware.vapi.std.errors_client.ResourceInaccessibleif the virtual machine template’s configuration state cannot be accessed.Raise: com.vmware.vapi.std.errors_client.ServiceUnavailableif any of the services involved in the method are unavailable.Raise: com.vmware.vapi.std.errors_client.Unauthenticatedif the user that requested the method cannot be authenticated.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif the user that requested the method is not authorized to perform the method.Raise: com.vmware.vapi.std.errors_client.Unauthorizedif you do not have all of the privileges described as follows:- Method execution requires
System.Read. - The resource
com.vmware.content.library.Itemreferenced by the parametertemplate_library_itemrequiresSystem.Read.
- Method execution requires
-
class
-
class
com.vmware.vcenter.vm_template_client.StubFactory(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBaseInitialize StubFactoryBase
Parameters: stub_config ( vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance