Quantcast
Channel: VMware Communities : Popular Discussions - VIX API
Viewing all articles
Browse latest Browse all 34639

VMware ACE Power-on script

$
0
0

I am not sure this is the right forum for my question, but I hope that somebody can help.

 

I am attempting to implement a power-on script in ACE, but up to now I was unable to get a script work...

 

I created a simple VBscript file that makes a file copy and returns 0 (FALSE) but it does not work.

 

The script body is:

 

Set objFSO = CreateObject("Scripting.FileSystemObject")

Set objFile = objFSO.CreateTextFile("C:\mio105.txt")

wscript.quit 0

 

and I run it as cscript //B script001.vbs

 

While starting up my ACE VM I get the following error: Error running your ACE's power on hook policy script: An internal error was encountered while running and the log says:

 

Sep 19 14:31:53.298: vmx| Policy_RunPowerOnHook: bad script output, expected either TRUE or FALSE.

Sep 19 14:31:53.298: vmx| PolicyVMX_PowerOn: failed call to run power on hook: 7.

Sep 19 14:31:53.298: vmx| Msg_Post: Error

Sep 19 14:31:53.298: vmx| http://msg.vmx.poweronHookError Error running your ACE's power on hook policy script: An internal error was encountered while running

 

I can see that the script did run because I find file c:\mio105.txt, so the problem is the return code: how can I set it?

 

I made a different test with a .bat file whose body is:

 

@echo off

copy c:\mio100.txt c:\mio102.txt

exit /B FALSE

 

and I get the same error and the same entries in the log.

 

Is it available aniwhere even a single sample of a working power-on startup script in either VBscript or as a DOS .bat file?

 

Can anybody please help?

 

Regards

 

Marius


Viewing all articles
Browse latest Browse all 34639

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>