There are four options you can use to change virtual machine logging and log rotation behaviors:
The logging setting allows you to turn logging on or off.
To configure log rotation based on file size, include this option in the virtual machines .vmx file:
log.rotateSize = 186368
Note: log.rotateSize is not available for vmx use in certain versions of ESXi 5.1 and 5.5. Adding this option in the virtual machine configuration file (.vmx) file does not have any effect.
The log.keepOld setting
By default, ESX and ESXi from 3.0 through 7.0 keep 6 rotations of the
vmware.log file
vmware.log,
vmware-1.log,
vmware-2.log, ... etc. (8.0 or later version this has been changed to keep 10 rotations.)
To change the level of rotation, use the log.keepOld option in the virtual machines .vmx file.
This example specifies the level of rotation to be 10:
log.keepOld = 10
The log.fileName setting
To specify an alternative location or filename for virtual machine logging, use the
log.fileName option in the virtual machines
.vmx file.
This example specifies myVMlog as the new file for logs instead of the default vmware.log:
log.fileName = myVMlog
This example directs logs to be written to an alternate directory called myVM in a different VMFS volume, vol1:
log.fileName = /vmfs/volumes/vol1/myVM/myVM.log