How can I fix permissions for files in the /var/folders/zz? How can I fix permissions for files in the /var/folders/zz?

There are a lot of file under /var/folders/zz that seem to be application caches or some sort. 

I am interested in this because, it appears that if the permissions of these folders get set incorrectly (and there is a lot of "help" out there that suggests changing these at one time or another) it can easily break the applications that use them, like Apple Software Update, Apple Setup Assistant, Adobe Flash Installer, and many others.

Note: This asks a different (although similar) question to the one found in Can I delete files or folders from /private/var/folders/?, and provides a correct &amp; concise answer to this specific question. It is also not about clearing space, but about fixing permissions on these files, which when incorrect WILL break applications.
These application cache directories can be deleted and will be re-created with proper permissions, after a reboot and the various parent applications are re-launched.

There is a lot of confusing half-responses to this question online, but it is safe to delete these folders, and this is a foolproof way to correct permissions. However, it is important that you only delete the underlying folders and do not delete the /var/folders/zz folder itself. There has been at least one bug reported that the OS will not automatically re-create the zz directory (although this may be fixed now).

It is very likely that the system will prevent some of the folders from being deleted. This is usually fine as well.

After deleting the folders, you should reboot immediately.

sudo rm -rf /var/folders/zz/zy*
sudo shutdown -r now


When the system boots and related application start up, the required directories will automatically be re-created with the proper permissions.



Some things that this fix can solve, include:


The Adobe Flash Installer always failing to install.


see: https://forums.adobe.com/message/9192807#9192807

Apple Software Update failing to install anything.


see: Software Update Permissions error

Apple Setup Assistant or the login screen showing question marks for all font characters.


see: https://discussions.apple.com/thread/7696662?start=0&amp;tstart=0

and likely many other things.




More Details:

see: http://www.magnusviri.com/OS_X_Admin/what-is-var-folders.html

see: https://osxbytes.wordpress.com/2015/03/19/boot-hang-after-deleting-var-folders/comment-page-1/