Run .cmd from action script not working

Looks like a problem inside the start Windows service.cmd script. I suspect it could be related to this line in it

Set MyCurDir=%CD%

Not handling spaces or parenthesis in the working directory path for C:\Program Files (x86)\BigFix Enterprise\...

So, when you ran this manually, did you first ‘cd’ into the \ibm\install directory? That may be the difference.

You may want to use a small ‘createfile’ to first CD into the script’s directory and then run it…

delete __createfile
createfile until EOF
cd /d "D:\ibm\si\install\bin"
startWindowsService.cmd
EOF

delete wrapper.cmd
move __createfile wrapper.cmd

action uses wow64 redirection false

waithidden cmd.exe /c ""wrapper.cmd" > "D:\ibm\logfile.txt" 2>&1"

continue if {exit code of action = 0
2 Likes