Behavior of action script

Apology for the long thread.
We’re in the process of migrating 100+ applications into BigFix. To speed up the migration created template action script that can be used for install/uninstall/repair of applications. So far we completed 30 applications and all is working fine.
Recently we have come across issues where the action stays in the running state, even when the underlying vbscript has completed successfully.

Application Name: Junos Pulse secure

the below code is used to start the vbscript which is part of run.bat
// BigFix Action Commands to start run.bat
override wait
hidden=true
completion=job
wait run.bat

the above lines I’ve basically copied from the Software Distribution wizard

when we change to the following the script completes fine
// BigFix Action Commands to start run.bat
waithidden cmd.exe /c run.bat

Reading the documentation on the Action Script

override wait
hidden=true
wait notepad.exe
This example provides the same functionality as waithidden notepad.exe.

My opinion this looks similar but behavior is different so there must be something else that comes into play.

When we run the action we also use code to check if the application is running for that we use HTA Screen that is run under context so it’s visible to the user.
We give the user 15’ time and otherwise application will be closed. that piece also works fine as we use this also for our other applications.

With the Junos Pulse there is something odd, flow is the following

  • Check if application is running (process: pulse.exe)
  • if running we ask user to close it
  • we run the .msi from the vendor that re-installs the application. That piece of code is run under the “SYSTEM” context, and it will also re-start pulse.exe but now running under system context. THe installation completes fine but the action remains in the running state, until I manually kill the pulse.exe process.

That last piece I don’t understand why it’s behaving that way and why the action would not just complete as normal.

Output from the action script
08/06/2020 16:20:54,99 Start batfile
08/06/2020 16:20:55,03 baseFolder: C:\SWSetup\JunosPulseforPC2\
08/06/2020 16:20:55,07 logFolder: C:\SWSetup\JunosPulseforPC2\
08/06/2020 16:20:55,10 Action ID: 1824
08/06/2020 16:20:55,12 Running Command: wscript.exe “C:\SWSetup\JunosPulseforPC2\CustomScripts\install.vbs” “JunosPulseforPC2” "Pulse Secure for PC(formerly Junos Pulse for PC) – v9.0 SCV13"
08/06/2020 16:20:56,87 Return code: 0
08/06/2020 16:20:56,87 End batfile

Output from the client logs
At 16:20:54 +0200 - actionsite (http://bfixhcldev.pg.com:29450/cgi-bin/bfgather.exe/actionsite)
Command succeeded (Exit Code=0) wait c:\windows\system32\mshta.exe “C:\HP\AppStoreBigFix\bin\Popup.hta” “Pulse Secure process is initiated and reqires reboot after it completes. Please close the application if exist on the PC within the next 10 minutes otherwise the application will be closed automatically. WARNING: Closing Pulse Secure could cause that applications such as Outlook, Skype and WebEx can get disconnected.” “PG Apps Center” “#COUNTDOWN:60 #BUTOK:OK #CHECKEXE:pulse.exe” (action:1824)
Command started - wait run.bat (action:1824)
<< The Action would remain in the running state until I kill the pulse.exe >>
At 16:21:24 +0200 - actionsite (http://bfixhcldev.pg.com:29450/cgi-bin/bfgather.exe/actionsite)
Command succeeded (Exit Code=0) wait run.bat (action:1824)
Command succeeded parameter “returnCode” = “0” (action:1824)

Thx for all the help.

You mention that pulse.exe is left left running under “System” when the MSI completes running.

Is there a way in the upgrade to prevent pulse.exe from being left running after the MSI completes? It may be that process is preventing the BES Client from detecting that the MSI has completed?

Have you used the “action may require restart” command? and restarted the targets?