Edit C:\Program Files (x86)\VMware\VMware VIX\doc\lang\c\functions\VixVM_PowerOn.html
<html> <head> <meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"> <meta HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> <link rel="stylesheet" href="../../../foundrydoc.css" type="text/css" charset="ISO-8859-1"> <link rel="stylesheet" href="foundrydoc.css" type="text/css" charset="ISO-8859-1"> </head> <body> <h1>Name</h1> <b>VixVM_PowerOn</b> <h1>Description</h1> <pre> VixHandle VixVM_PowerOn(VixHandle vmHandle, VixVMPowerOpOptions powerOnOptions, VixHandle propertyListHandle, VixEventProc *callbackProc, void *clientData); </pre> <p> Powers on a virtual machine. <h1>Parameters</h1> <dl> <dt><i>vmHandle</i></dt> <dd> Identifies a virtual machine. Call VixVM_Open() to create a virtual machine handle. </dd> <dt><i>powerOnOptions</i></dt> <dd> VIX_VMPOWEROP_NORMAL or VIX_VMPOWEROP_LAUNCH_GUI. </dd> <dt><i>propertyListHandle</i></dt> <dd> Must be VIX_INVALID_HANDLE. </dd> <dt><i>callbackProc</i></dt> <dd> A callback function that will be invoked when the power operation is complete. </dd> <dt><i>clientData</i></dt> <dd> A parameter that will be passed to the callbackProc function. </dd> </dl> <h1>Return Value</h1> VixHandle. A job handle that describes the state of this asynchronous operation. <h1>Remarks</h1> <ul> <li> This function powers on a virtual machine. It is an asynchronous operation, and the job will be signalled when the operation completes. <li> This operation completes when the virtual machine has started to boot. If the VMware Tools have been installed on this guest operating system, you can call VixVM_WaitForToolsInGuest to determine when the guest has finished booting. <li> After powering on, you must call VixVM_WaitForToolsInGuest before executing guest operations or querying guest properties. <li> In Server 1.0, when you power on a virtual machine, the virtual machine is powered on independent of a console window. If a console window is open, it remains open. Otherwise, the virtual machine is powered on without a console window. <li> To display a virtual machine with a Workstation user interface, powerOnOptions must have the VIX_VMPOWEROP_LAUNCH_GUI flag, and you must be connected to the host with the VIX_SERVICEPROVIDER_VMWARE_WORKSTATION flag. If there is an existing instance of the Workstation user interface, the virtual machine will power on in a new tab within that instance. Otherwise, a new instance of Workstation will open, and the virtual machine will power on there. <li> To display a virtual machine with a Player user interface, powerOnOptions must have the VIX_VMPOWEROP_LAUNCH_GUI flag, and you must be connected to the host with the VIX_SERVICEPROVIDER_VMWARE_PLAYER flag. A new instance of Player will always open, and the virtual machine will power on there. <li> This function can also be used to resume execution of a suspended virtual machine. <li> The VIX_VMPOWEROP_LAUNCH_GUI option is not supported for encrypted virtual machines; attempting to power on with this option results in VIX_E_NOT_SUPPORTED. </ul> <h1>Side Effects</h1> None. <h1>Requirements</h1> vix.h, since VMware Server 1.0 <h1>Example</h1> <pre> VixError err = VIX_OK; VixHandle hostHandle = VIX_INVALID_HANDLE; VixHandle jobHandle = VIX_INVALID_HANDLE; VixHandle vmHandle = VIX_INVALID_HANDLE; jobHandle = VixHost_Connect(VIX_API_VERSION, VIX_SERVICEPROVIDER_VMWARE_WORKSTATION, NULL, // hostName 0, // hostPort NULL, // userName NULL, // password 0, // options VIX_INVALID_HANDLE, // propertyListHandle NULL, // callbackProc NULL); // clientData err = VixJob_Wait(jobHandle, VIX_PROPERTY_JOB_RESULT_HANDLE, &hostHandle, VIX_PROPERTY_NONE); if (VIX_OK != err) { // Handle the error... goto abort; } Vix_ReleaseHandle(jobHandle); jobHandle = VixVM_Open(hostHandle, "c:\\Virtual Machines\\vm1\\win2000.vmx", NULL, // callbackProc NULL); // clientData err = VixJob_Wait(jobHandle, VIX_PROPERTY_JOB_RESULT_HANDLE, &vmHandle, VIX_PROPERTY_NONE); if (VIX_OK != err) { // Handle the error... goto abort; } Vix_ReleaseHandle(jobHandle); jobHandle = VixVM_PowerOn(vmHandle, VIX_VMPOWEROP_NORMAL, // powerOnOptions, VIX_INVALID_HANDLE, // propertyListHandle, NULL, // callbackProc, NULL); // clientData err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE); abort: Vix_ReleaseHandle(jobHandle); Vix_ReleaseHandle(vmHandle); VixHost_Disconnect(hostHandle); </pre> </body> </html> <hr>Copyright (C) 2007-2017 VMware, Inc. All rights reserved.
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de