Clearing the Munki client download cache

This rarely happens (in fact, in the year I've been using Munki so far, this has happened only once), but you may once in a blue moon get a corrupted download (especially for a large installer). Here is an example of what that looks like:

Mounting disk image ExtremelyLargePackage-1.2.dmg...
ERROR: Error: "hdiutil: attach failed - image data corrupted" while mounting ExtremelyLargePackage-1.2.dmg.
ERROR: No mountable filesystems on ExtremelyLargePackage-1.2.dmg
Unfortunately, once a corrupt package makes its way into the cache, checking again doesn't seem to clear it out and re-download.

So go to /Library/Managed Installs/Cache, where you should find the corrupt download. Re-do your managedsoftwareupdate check and a new, uncorrupted download should start.

Note: as far as I can tell, Munki will clear out the cache once downloads are successfully installed, so you shouldn't have to manually clear out the cache unless you run into this unlikely situation.

Leave a Reply

Your email address will not be published. Required fields are marked *