eSolutions & marketingeSolutions & marketing
  • Home
  • Website Solutions
    • eCommerce Solutions
    • Website Design / Development
    • Shopping Cart Software
    • Content Management Systems
    • Shopfront to WooCommerce
    • Website Sale
    • Web Development Quotation
  • Website Services
    • Website Support & Maintenance
    • Fraud Protection Software
    • Google Merchant Feeds
    • Project Management
  • Internet Marketing
    • Google Maps / Google Business Profile
    • Search Engine Marketing
    • Search Engine Optimisation
  • Our Work
  • Post a Project
  • Contact
  • Home
  • Website Solutions
    • eCommerce Solutions
    • Website Design / Development
    • Shopping Cart Software
    • Content Management Systems
    • Shopfront to WooCommerce
    • Website Sale
    • Web Development Quotation
  • Website Services
    • Website Support & Maintenance
    • Fraud Protection Software
    • Google Merchant Feeds
    • Project Management
  • Internet Marketing
    • Google Maps / Google Business Profile
    • Search Engine Marketing
    • Search Engine Optimisation
  • Our Work
  • Post a Project
  • Contact

  • Home
  • Our Insights
  • Magento invalidated cache can slow down the website

Magento invalidated cache can slow down the website

Category: Development

esolutions-and-marketing2021-07-27T09:53:15+10:00

Magento invalidated cache can slow down the website

By esolutions

Last week, one of our client’s website which is running on Magento became noticeably slow. Using Chrome developer’s tool it shows the page load took 14+ seconds and even longer. So we started to investigate the issue and we were a little surprised to find out the cause of the slowness.

Luckily we run all our own servers so it didn’t take long to track the problem down.

  • First thing we checked was the server it was hosted on, to see if it was a resource issue. The server load was average and MySQL didn’t seem to have any problems. Also no resources were limited on that domain so we concluded that it wasn’t a resource problem on the account or globally on the server.
  • Next we had a discussion between our developers and confirmed there were programming done on the website. This means this must be caused by the Magento core or some plugins this website is using.
  • At this stage, we suspected maybe the caching was turned off, so we went into cache management to check.
    Magento Cache Management
    Caching was on but we discovered that there was an invalided cache.
    Magento Invalided Cache
  • So we selected the invalided cache and refreshed it.
    Magento Refresh Invalided Cache
  • After this we tested the website again. To our surprise, this resolved the websites’s slow loading issue. Now we need to find a way to detect this and fix it automatically.
  • To do this, we created a file called cache-check.php in the root of the Mangeto directory. In our case, it is the public_html. This file consist of the following codes:<?php
    require ‘app/Mage.php’;
    $invalidCache = Mage::app()->getCacheInstance()->getInvalidatedTypes();
    foreach($invalidCache as $i)
    {
    Mage::app()->getCacheInstance()->cleanType($i[“id”]);
    }
  • Next we added a cron in cpanel to run this every hour. Now the system will check for invalided cache and refresh it every hour. We can set this to a smaller interval if we want, but hourly check should be sufficient.

Hope this may help someone out with a similar problem.


Related Posts

Startup businesses – what’s the best way to start?

Over the years we have developed websites for many startup businesses and one thing that stands out as a... read more

How to develop an eCommerce website from scratch

There are many ways that you can go about this and many different budgets involved. Step 1. Find a domain... read more

What is the best website platform?

Before we get into analysing the platforms, ask yourself a couple of questions: Do I have good experience with... read more

Using social media to market your business

Social media are internet services that let you interact with others and share and create content through online communities. Social... read more

Enable Paypal API Credentials

Many of our clients often ask us how they can obtain their Paypal API Credentials from their account. This... read more

eCommerce Websites and the Cost of Ownership

We have been recently reviewing all of the options for developing an eCommerce store and ways that this can... read more

What is the best design for my website?

This is an interesting question that we face each day and the way that we look at it is... read more

WooCommerce product search not showing results

We have been working on a client's WooCommerce store and for some unknown reasons the Product Search wasn't working correctly.... read more

Recent Posts

  • We asked ChatGPT “Where Do You See AI Helping Business in the Future?” October 10, 2024
  • Unveiling the Benefits of Professional Website Design for Your E-commerce Venture in Sydney April 15, 2024
  • The Vital Importance of Keeping WordPress Plugins Up to Date April 2, 2024

Categories

  • Blog
  • Develop
    • Design
  • Development

Let’s Get in Touch

We’re interested in talking
about your business.

Let's Talk!

  • Castle Hill, Norwest & The Hills
  • Parramatta
  • Hornsby & Sydney’s North West
  • Silverwater & Sydney Olympic Park
  • West Ryde & Macquarie Park
  • Blacktown & Seven Hills

Useful Links

  • Website Design Sydney
  • About
  • Sitemap
  • Terms
  • Contact
esolutions and marketing
Facebook Twitter Linkedin
© 2025. All Rights Reserved