Magento – Difference between Refresh All Cache , Flush Magento Cache and Flush Cache Storage

cachemagento2permissions

We are seeing this options from Magento1, but we are not clear what types of cache will be flushed from the system/magento. What needs needs to cleaned or run at what time.

In magento 2 we refresh the cache and also flushed Magento cache, is that mean we have to once again deploy the static content here again.

After Cache clean we are unable to login in Magento admin, after checking the logs file found that var/cache folder don't have the proper write permissions. But before removing cache it has the right permissions.

Can anybody provide insights of handling the Magento cache especially the Magento2 part? As we are seeing the issues after flushing the cache from admin side.

Best Answer

Sometimes the cache location (like "/tmp/") or service (like Memcache) is shared with other applications. "Flush Magento Cache" removes only those entries that Magento reliably tracks as it's own. "Flush Cache Storage" clears everything but might affect other applications if they're using it.

Normally the location is "var/cache/" in Magento's folder so is not shared after all. It is safe to use either button. Sometimes (rarely) entries are not clearly tagged or Magento loses track of them and only the second button has an effect on them. I tend to use the second button when I'm having difficulty tracking down the cause of a problem.