Hello guys, I have been trying to make this script run for quite a few hours now and at this point, and after googling and browsing ITninja, I am still a little lost.

Here is a screenshot of the script

w2BCym.png

As you can see this is a pretty simple script that only checks for the software/version not to be present on the pc and in case it is not it runs an msi from the dependencies folder on that pc.
I have isolated the problem to the point where I am almost sure the file is not being copied to the dependencies folder of the pc.
To give more information about this, the targeted pc has a label which points to a replication point and that replication point works ok for managed installations.

A part from this question I have another one, are replication points used to copy dependencies? or is the file always copied from the appliance?

PD: I know this can be done with a managed installation and actually I have one already in place but I have still decided to use scripting for single time installations due to the ammount of technicians using our K1000 server.

Any input will be greatly appreciated.
Answer Summary:
Cancel
8 Comments   [ + ] Show Comments

Comments

  • What does the scripting logs show?
    • Output Log

      Running as: SYSTEM
      File does not exist: C:\Program Files\7-Zip\7zFM.exe
      Creating process returned non-zero: C:\Windows\System32\msiexec.exe /i C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\141\7z920-x64.msi /qn: (0) The operation completed successfully.
      Error Code: 0
      Status Code: 1619



      Status Log

      7-zip 9.20 installation has failed (this is a custom message I added as remediation fail task).




      Activity Log

      Checking if file exists: C:\Program Files\7-Zip\7zFM.exe
      Launching program: 'C:\Windows\System32\msiexec.exe' '/i C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\141\7z920-x64.msi /qn' wait='true'
      • Two questions,
        1. have you verified that the software is in fact not installed after you run this?
        2. if so what happens when you run the following command manually?

        C:\Windows\System32\msiexec.exe /i C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\141\7z920-x64.msi /qn
  • 1. Yeah sure, I checked and the software is not installed.

    2. I also tried to run that command and it didn't work. Basically it had no output so I went to C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\141 and found out that 7z920-x64.msi was not there. Therefore the title of my question, looking at it, it may not be as clear as it sounded when I worte it hehe...
  • go the the C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots and who has what rights there?
  • System has read/write, administrators have read/write and users have read access. The script is being run by System.

    one detail is that folder 141 is created but the msi is not in the folder.
  • I have seen a similar issue when the file to be installed has yet to replicate to a replication share. In that case, the script runs properly but there's simply no file to be copied into the path that got created.
    • Hi, yeah I have seen that too but I checked it and the file is actually present in the replication share.
  • just a simple question: why don't you use a managed install for install software?
    • Hi, we have been using managed installations up to now and it has been working ok. However, since we have 24 technicians all around the world remotely servicing almost 5000 computers and many of the installations are a one time only services we rely on the guys to remember to remove the device from the managed installation deploy list and I have seen them failing to that many times, which in time, becomes pretty messy. I think this happens mainly because of the lack of real time execution and task tracking of MIs.
      So I thought maybe using scripts with run now and real time reporting could do the trick on having the deploy field more organized.
      If you can come up with a good way to keep that tidy using MIs your input will be more than appreciated.
      • If the Software Inventory item has an uninstall string or a custom inventory rule, your managed install would only run once.
  • "Run a batch file" would be a better option if the above does not work. Simply put
    msiexec.exe /i 7z920-x64.msi /qn
    I have noticed in the past that downloaded msi's in scripts get deleted.
  • Thanks for your replies. In the end I had worked it around ziping the MSI. I noticed MSI files didn't copy for whatever reason but zip files do, so I'm copying the zip file as a dependency, have the script unzip it, run it, log a message and then delete the dependency folder. That works kinda like a MI but has the benefits of the Run Now from scripts.
Please log in to comment

Answer Chosen by the Author

0
In the end I had worked it around ziping the MSI. I noticed MSI files didn't copy for whatever reason but zip files do, so I'm copying the zip file as a dependency, have the script unzip it, run it, log a message and then delete the dependency folder. That works kinda like a MI but has the benefits of the Run Now from scripts.
Answered 11/09/2015 by: Glaporte
Senior Yellow Belt

Please log in to comment

Answers

This content is currently hidden from public view.
Reason: Removed by member request
For more information, visit our FAQ's.

Answer this question or Comment on this question for clarity