Name
VMEndRecording
Description
$err = VMEndRecording($vmHandle, $options, $propertyListHandle);
This function stops recording a virtual machine's activity.
Parameters
- vmHandle
-
Identifies a virtual machine. Call VMOpen()
to create a virtual machine handle.
- options
-
Must be zero.
- propertyListHandle
-
Must be VIX_INVALID_HANDLE.
Return Value
$err. The error code returned by the operation. For returned values, see Topics > Error Codes.
Remarks
- Record-replay functionality has been deprecated and this function may be removed from future versions of the VIX API.
- This operation only works on a virtual machine that is recording.
- This function is not supported when using the
VIX_SERVICEPROVIDER_VMWARE_PLAYER
host type.
Side Effects
- This function disrupts communication with VMware Tools.
Any outstanding Vix related guest operation may be aborted. Users will
need to call
VMWaitForToolsInGuest
before performing additional operations in the guest.
Requirements
use VMware::Vix::Simple;
use VMware::Vix::API::Constants;
since VMware Workstation 6.5
Example
my $err;
my $snapshotHandle;
my $vmHandle;
($err, $snapshotHandle) = VMBeginRecording($vmHandle, "recording 2",
"description of recording 2",
0, VIX_INVALID_HANDLE);
die "VMBeginRecording() failed, $err ", GetErrorText($err), "\n" if $err != VIX_OK;
# wait for some activity to happen, then stop recording
$err = VMEndRecording($vmHandle, 0, VIX_INVALID_HANDLE);
die "VMEndRecording() failed, $err ", GetErrorText($err), "\n" if $err != VIX_OK;