Software Deployment Question

What causes K1000 to deploy dependencies but not run them?

01/20/2015 1731 views
I'm experiencing a failure rate of around 25-100% with a custom script that I'm trying to deploy, however the failure occurs because the script never runs on the local machine after it is deployed.  This occurs on multiple custom scripts, but as there's one that's more important than the others I'll use it as an example.

The script is an online kscript that is deployed to a label and has a singe dependency attached, which is a PowerShell script file that performs the 'meat' of the process.  I use the "Run a batch file..." task option to call the PowerShell executable to run the script.  When I run the kscript, I get a 100% success rate in the Run Now Status log, however I've been previously informed by KACE support that K1000 considers the push a success if the dependencies are copied to the local machine so that number is meaningless.  The kace****.bat and my .ps1 file are being deployed, but neither is being executed.

I suspected a permissions issue, so I inserted a line into the "Run a batch file..." box that simply uses the DOS echo command to write text to a file on the root of C but even that is not occurring.  This tells me that the agent on the local machine isn't even attempting to run the batch file.

I've looked at runkbot.log on a few of the local machines but while I can find entries that begin roughly when the kscript was deployed, I don't see anything that looks like it's trying to execute the batch file.  All I see is that it's refreshing dependencies and then making an upload to the K1000.  I thought there might be something in klaunch.log, but there's nothing corresponding to the date that the kscript is being run.

The most frustrating part is that I cannot recreate the issue in my test VMs and there doesn't seem to be a pattern with the machines that fail to execute the batch file, as I can often do a second deploy and a machine that failed to execute the first time will execute successfully the next time.  On machines where the batch file is executed, then it in turn executes my ps1 script file and everything is peachy.

Where else can I look for information to troubleshoot this issue, or what can I do differently?
0 Comments   [ + ] Show comments


All Answers

You may need to enable Debug mode on a select number of agents where the problem is occuring. That will give you a more verbose log to work from to try and find the problem. Enabling debug mode is a simple enough process, just add "debug=true" to the amp.conf file and restart the service. You can also run the KScript that does essentially the same thing.
Answered 01/20/2015 by: BHC-Austin
4th Degree Black Belt

  • Great info, thanks. I pushed the built-in kscript to the machines that I'll be trying to update tonight, so hopefully I'll have some more information tomorrow morning.
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ