12-02-2021 11:27 AM - edited 12-05-2021 03:26 AM
I am setting up 2 new policies to (1) uninstall and the old Bitdefender Onprem client and then (2) install the new cloud client.
the first works fine and silently uninstalls the old Bitdefender client.
The second policy fails. The error given is related to the download target location of the package.
This is the simple script that worked previously.
installer -target / -pkg /Users/Shared/antivirus_for_mac.pkg
We are running Jamf 10.27 still on macOS Catalina and I think there may have been some changes creep in such as inability to write to system volume which might be what is causing the download failure.
Solved! Go to Solution.
12-05-2021 03:06 AM - edited 12-05-2021 03:08 AM
Thanks but I figured it out, it was my bad.
I had not created the required folder structure in the package “/Users/Shared/“ prior to exporting it (which is the location the script was expecting to find the package), so it was literally trying to save to root which is the default location and was getting denied causing the error.
Interestingly, I also found that if you had previously downloaded a similarily named package to that location (previous version of the installer) and not removed the package, the script could run it and you would end up with the older version reinstalling. So I scripted in a line to remove any package with that name before downloading it to avoid such situations.
12-03-2021 07:19 AM - edited 12-03-2021 07:22 AM
Your package is the issue here not so much the download location of the installer as /Users/Shared isn't a System location.
I suspect your Bit Defender pkg is trying to install a system extension or a kext into /System which isn't kosher anymore. It's either of those two or a launchdaemon. Take a peek at your installer using Suspicious Package and see where things are going.
Posted on 12-03-2021 12:20 PM
try changing the target to /Applications
i.e: installer -target /Applications -pkg /Users/Shared/antivirus_for_mac.pkg
12-05-2021 03:06 AM - edited 12-05-2021 03:08 AM
Thanks but I figured it out, it was my bad.
I had not created the required folder structure in the package “/Users/Shared/“ prior to exporting it (which is the location the script was expecting to find the package), so it was literally trying to save to root which is the default location and was getting denied causing the error.
Interestingly, I also found that if you had previously downloaded a similarily named package to that location (previous version of the installer) and not removed the package, the script could run it and you would end up with the older version reinstalling. So I scripted in a line to remove any package with that name before downloading it to avoid such situations.