A user is having trouble executing a PowerShell script in ControlUp on a VDI with an agent installed. They receive an error message and are unable to run the script from the console. Other users suggest checking permissions and removing unnecessary lines from the script. It is also suggested to import the ps1 file instead of copying and pasting. The option to target machines in the console is discussed.
Read the entire ‘Troubleshooting Script Execution in ControlUp’ thread below:
Hi, I am trying to execute a script that I added and I am getting the below message. The VDI has the agent installed. Has anyone got this before?

can you please share the screenshots of the script configuration?
This is a powershell script that I imported. I was able to use this same script for the physical devices.




the script will never finish successfully with cu4vdi as an upgrade have reboots involved and will make the script fail
that one, more things:
• import the ps1 file as the current is too large for copy/paste
• I don’t know if the script even works on system level
• remove that first line of the script as its purely for cu4d and is not needed for cu4vdi
• change the timeout to not kill the process otherwise the upgrade might fail
Also, I just found this from the ControlUp Console. It says "You dont have the necessary permission to run this script."

yeah that would be my next thing to check permissions and have you try from the console
Its grayed out from the Console
and did you target the machine from agents view or something else as I think the error could have been related to it being targeted on vm level
I targeted the script to machines
yes but dex has various machine options

When I created the script, it did not specify the different machine options.

because in the console its always against a machine with agent that’s added to the console
Im trying to execute the script on a VDI with an agent installed
Continue reading and comment on the thread ‘Troubleshooting Script Execution in ControlUp’. Not a member? Join Here!
Categories: All Archives, ControlUp for VDI, ControlUp Scripts & Triggers
