Memcached vs Redis vs Varnish vs APC vs Opcache vs XCache cache?

Chris Worner

Well-known member
Registered
Joined
Apr 15, 2016
Messages
612
Points
28
I read more on this forum about these caching solutions as Memcached, Redis, Varnish, APC, Opcache, XCache cache and saw them in my hosting panels. I would know your opinion which is better for caching static and dynamic web site content and helping speeding up my web hosting?
 

VirtuBox

Well-known member
Registered
Joined
May 3, 2016
Messages
1,622
Points
83
Hello Chris,
There are two categories of caching system.
1) PHP code caching
Xcache, OpCache, APC are php extensions which allow to cache the php process to not have to reprocess a file each time.

2) Advanced Caching system
Redis, Memcached, Varnish are advanced caching system. Redis is often use for object caching, because it's a kind of optimized mysql and you can use it to process the long queries instead of mysql. Memcached is a memory caching system and Varnish is a proxy for static files caching.

Currently for WordPress Redis is the most powerful solution because it doesn't make the website static and can speed up any wordpress. Memcached is less efficient. And Varnish is harder to setup and require somes tricks to be used properly and with SSL.
 

Polymath

Member
Registered
Joined
Jan 13, 2017
Messages
25
Points
0
Do some of these caching solutions work better with others or are they all compatible with one another as long as you use only one caching solution for each type of caching that is needed?

I'm trying to figure out all aspects of setting up a VPS since I will be setting up my first one soon (I hope) and don't want to run into problems.
 

Chris Worner

Well-known member
Registered
Joined
Apr 15, 2016
Messages
612
Points
28
Do some of these caching solutions work better with others or are they all compatible with one another as long as you use only one caching solution for each type of caching that is needed?

I'm trying to figure out all aspects of setting up a VPS since I will be setting up my first one soon (I hope) and don't want to run into problems.
I think it depends on OS, hosting panel or PHP supported it or not.

APC are php extensions
What about APCu? is it the same as APC?

2) Advanced Caching system
Redis, Memcached, Varnish are advanced caching system. Redis is often use for object caching, because it's a kind of optimized mysql and you can use it to process the long queries instead of mysql. Memcached is a memory caching system and Varnish is a proxy for static files caching.

Currently for WordPress Redis is the most powerful solution because it doesn't make the website static and can speed up any wordpress. Memcached is less efficient. And Varnish is harder to setup and require somes tricks to be used properly and with SSL.
Can I install both Redis, Memcached on a server? or I don't use Wordpress site, I still can install Redis?
I think if using Wordpress, install wp total cache or wp super cache plugin will speed up wordpress sites without using a caching system as Redis or Memcached.
 

Harry P

Well-known member
Registered
Joined
Feb 3, 2015
Messages
447
Points
28
I used memcached and redis and in my experience, redis has more advantages over memcached as some features redis offered then memcached doesn't. In other words, it depends on your systems, if it require to have memcached for better performance then you should install memcached or vice versa.
 

hostproton

Member
Registered
Joined
Jun 19, 2017
Messages
50
Points
6
Hello,

It's true that Varnish is a great caching system, as well as being very powerful. But for shared hosting is a real problem.

It is difficult to explain to the end customer that they should disable the cache (for example with Cachewall for cPanel) because if you do not, you will not see the changes instantly while you are developing your website.

I'll stick with LiteSpeed + LsCache
 

Harry P

Well-known member
Registered
Joined
Feb 3, 2015
Messages
447
Points
28
Harry P
Just wondering why it has problem on shared hosting?
Honestly I tried to install this caching on a VPS but it failed or very difficult to install it as some tutorials on the net.
 

VirtuBox

Well-known member
Registered
Joined
May 3, 2016
Messages
1,622
Points
83
No, LsCache is the cache system of LiteSpeed.
But all applications are not compatible with all cache systems, and you can use several caching solutions on the same server.
It's not related at all to cpanel, you can do the same on cPanel than on Plesk or directadmin
 
Newer Threads
Recommended Threads
Replies
5
Views
3,390
Replies
0
Views
2,356
Replies
8
Views
3,417
Replies
4
Views
3,430

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top