I'm working in an mixed mac OS environment that also has mixed versions of the KACE agent installed. KBOX Agent 5.1.31311 and KBOX agent-5.3.53177.dmg. I'm trying to write a script to run Symantec's uninstaller script. The two different agents seem to have two different directories set up on the mac. I tried using the $(KACE_DEPENDENCY_DIR) variable thinking that would solve the differences. The script worked once and now hasn't worked since. I've had to hard code the path to where the dependent file has been dropped but that means it won't work on a mac with a different version of the agent.

Logically I should go ahead and fix the different versions of the agent first (which I probably will do) however, I'm curious if anyone else is having trouble getting the variable to work? Even if I fixed the different agent versions, I'm still having to hard code the path.


Here's part of my script:

/usr/bin/ditto -x -k --rsrc "/Library/Application Support/Dell/KACE/data/scripts/106/SymantecRemovalTool.command.zip" "/Library/Application Support/Dell/KACE/data/scripts/106/SymantecRemovalTool"

sh /Library/Application\ Support/Dell/KACE/data/scripts/106/SymantecRemovalTool/SymantecRemovalTool.command


What i want to use is this so that I can run it on any version of KBOX:

/usr/bin/ditto -x -k --rsrc "$(KACE_DEPENDENCY_DIR)/SymantecRemovalTool.command.zip" "$(KACE_DEPENDENCY_DIR)/SymantecRemovalTool"

sh $(KACE_DEPENDENCY_DIR)/SymantecRemovalTool/SymantecRemovalTool.command

0 Comments   [ + ] Show Comments


Please log in to comment



I don't understand. If the script worked once, then it should work on other machines as well.

Are you saying that script worked on one agent version and didn't on other?

Are there any error(s) that you are getting?


Answered 07/25/2012 by: AbhayR
Fourth Degree Black Belt

  • It worked on version 5.3 once. When I reran the script on another machine also with version 5.3, it wouldn't work until i hard-coded the path.
Please log in to comment
Answer this question or Comment on this question for clarity