Dan_F Absent Member.
Absent Member.
401 views

Launching Powershell scripts

We recently updated to Update 4 and it seems to have killed our Powershell script bundles.

We were previously running them with the settings seen in the image linked below. These were found on these forums many years ago I believe.

https://i.imgur.com/KbTGGLH.png

Script file extenstion = .ps1
Path to Script engine = %comspec%
Script engine Parameters = /c C:\Windows\System32\WindowsPowerShell\v1.0\PowerShell.exe -executionpolicy unrestricted

Any device running update 4 now runs the script but no longer displays it, which is a big part of how the script runs as there are things we need to check.

Does anybody know how to launch Powershell scripts via ZENworks so that you can actually see the gui?

Thanks
Labels (1)
0 Likes
5 Replies
Dan_F Absent Member.
Absent Member.

Re: Launching Powershell scripts

Managed to work it out.

Launch executable

Command - ${WINDIR}\System32\WindowsPowerShell\v1.0\powershell.exe
Parameters - -ExecutionPolicy Bypass C:\script.ps1
0 Likes
bbilut Super Contributor.
Super Contributor.

Re: Launching Powershell scripts

I'm in a similar boat having just updated to Update 4 (2017). We have tons of powershell script bundles that are now not working and we define the script inside the bundle. Looks like I'll have to open a ticket.

0 Likes
bbilut Super Contributor.
Super Contributor.

Re: Launching Powershell scripts

Great can't even open a ticket.

explorer_9vElQFEOus.png

0 Likes
bbilut Super Contributor.
Super Contributor.

Re: Launching Powershell scripts

I should clarify too. As soon as we update the client agent from 17.2 to 17.4 or higher (17.4.1.a) our powershell scripts stop working and do not launch.

0 Likes
Micro Focus Expert
Micro Focus Expert

Re: Launching Powershell scripts

The issue is they are running Hidden.

Apparently in the past if "No Wait" was selected they could be visible.

If "wait until complete' was set, they were not visible.

I don't believe they were ever intended to be visible and that was "Fixed".

However, I have a ticket open with Dev to see what we can do to restore this functionality.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.