Clear your Magento cache without using your admin pages

on July 28th, 2016 by Hades | No Comments »

While moving Magento installs or working on an existing clients install you might need to clean the cache, but you might not have access to the installs admin. With the code below you can easily clean the installs cache.


getCache();
if($cache != null) {
$cache->clean();
}
}


Just copy it to a newly created document then run. Your installs cache has now been cleaned.

Alternately if you have shell access you can clear cache simply by using the command below:


rm -rf var/cache/*

Session cache can be cleared by SSH using the line below:


rm -rf var/session/*

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.