↑ Return to W50 Cache

W52 CDN


Page no: W52

 

 

Explanation

Video

CDN Cache

CDN typically media files from the local WordPress installation into CDN servers all over the world. When a user from the U.S. is accessing our site then he receives the media files from a CDN server in the United States.

In the WordPress Installation this is done via “CDN caching”.

 

We do not use CDN any more because we have a very quick server now.

 

CSS on CDN

CSS cannot be loaded

When SNBCHF was still at Hostgator, the following appear far often than it does today.

CDN without money

In this case, the account at KeyCDN did not have money any more.

SNBCHF Broken
 

When I was in Bulgaria, we had a similar issue on mobile SNBCHF. There was some old code from the advert plugin. Was it CSS code?

No Cache Refresh

My idea is that the implementation does not need a cache refresh (manual or automatic after some time).

But that we use a completely new form/ a new CSS class, but not reuse the old popup form (aka CSS object).

 

Reason:

Probably the cdn cached the CSS file. It was perfect on my computer, I forced the cache right after I was done with development and it was perfect as you see on the screen. I will disable cdn for css, so it is fine. I disabled to cache the css files on ecoblogs, but I didn’t want to disable for snbchf

 

They cache the css and change the css url the same they do with the images.

CDN urls

CDN urls - Click to enlarge

Exclude CSS from getting cached in the CDN.

Same for Javascript and PHP.

CDN Enabler exclusions

CDN Enabler exclusions

CDN Enabler

How to disable CDN and what is the effect?

CDN is disabled via CDN Enabler plugin. Just need to be deactivated.

CDN plugin still enabled.

CDN was disabled everywhere. Now I disabled it on SNBCHF, too. I was wanting to see first the page speed statistic from ecoblogs, before I implement on SNBCHF.

 

CDN problems

Image Loading problems

Images not loaded with CDN on a slow network

Here the problem is not in the CDN. It is somewhere in the browser, browser (security) restrictions on SNBCHF and in the computer. Any of the images are not loading including backgrounds. So it is definitely other problem.

It was a browser or security restriction about the images, not CDN related problem.

Again the same  problem with not loading images.

CDN: huge traffic after purging

 

Our server problem on 07/20 was caused by our CDN. We purged the whole cdn cache and their crawlers start caching all our static content again. The problem was that they started too many connections to the our server.

The traffic was almost 800% higher than the usual traffic. This is problem of the CDN, they must send regular queries for fetching our content. This traffic is not seen by the Google Analytics, because it is directly to our CSS files. Nothing related with the site. So Google Analytics can track only when the code is installed on that page. It can’t track the traffic to our static files.

We fixed that issue changing the apache and nginx limits to higher. Now we can handle MaxCDN traffic. But it is good idea to purge only some files, not the whole cache. It will save us so many unnecessary queries.

Server load at that time on 07/20

 

 

 

Explanation
Video and Pics

 

 

See more for Webdesign