/build/static/layout/Breadcrumb_cap_w.png

Unable to run simple batch file in KACE script

Hello,

I'm having some issues running a simple batch file in the KACE scripting. I'm fairly new to KACE and still learning to use this software. Below is a screenshot of the batch file I'm trying to run. It shows as running successfully in the logs, but nothing actually deletes. When I look at the log I get the following message:

Running as: Administrator
Error creating process: C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\131\kace7499.bat : (2) The system cannot find the file specified.
Error Code: 2
Status Code: 0

Any ideas why this would be? Thanks!

 

 

 


4 Comments   [ + ] Show comments
  • Under script name make sure to change it from .sh to .bat - Jbr32 10 years ago
  • That would only be if they were running a Online Shell Script.

    Try removing the quotes around your pathway. Also being that this is a Unix system you might want to try rm c:\test - nshah 10 years ago
  • it is probaly running, it is looking for a file named test at c:\. use del c:\test\*.*
    the best thing to do is "launch a program" and use cmd.exe for the program with del ... as the parameters - SMal.tmcc 10 years ago
  • Thanks for the replies! I figured this out. The user was on a replication server and the settings weren't setup correctly. We're all good now! - rorylee 10 years ago

Answers (2)

Posted by: SMal.tmcc 5 years ago
Red Belt
1

need different command

like already state name the script text.bat

and use this command

if exist c:\test rd c:\test /q /s


Comments:
Posted by: bmontooth 5 years ago
Senior White Belt
-1

Try putting .bat after the file name in the Script Name box.  This fixed a similar issue for me. 


You also may want to put a verify command in there like Verify the folder exists c:\test

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

View more:

Share

 
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