Search code examples
batch-filevmwarestartupvmware-workstationvmware-tools

VMWare Tools StartUp Script


I am on the latest version of VMWare Workstation. In my VMWareTools I have configrued an individual script file (start.bat) to be started when the (guest) OS is booted. Unfortuantely it does not run when starting the guest system as intended.

  1. When pressing "run now" it works
  2. Running the script from CMD works as well
  3. I have changed the service (VMWareTools service) to run under different users - no success
  4. All Users (of the service) have had Administrator privileges

I have no idea what is going wrong. Maybe someone is having an idea ....


Solution

  • I had the power section of the VM mis-configured. From the documentation.

    Power Off/Shut Down Guest — If set to Power Off, it turns off the active virtual machine like the power button on a hardware PC. The virtual machine is abruptly powered off, with no consideration for work in progress.

    Similar scenario applies when Starting up. With the correct setting the script start. Once you know the answer -as always - it is so obvious. However, the other comment remains an interesting alternative.

    Just a hint: When running the script, VMWare reported the script did not successfully run, which it did. Setting ERRORLEVEL = 0 at the end of the script avoids this issue.