Caching for Webserver

**Operating system: Debian
**OS version: 10

Hi community,

I’m running Virtualmin on an Apache Webserver.
What I want to do is to activate caching for it, since the TTFB is pretty long, more than 3 seconds.
I’ve red something about the Disk Caching feature of Apache and also Varnish cache.
Which of those are better?
I’ve on my server 3 WordPress sites and one Moodle instance.

Thanks a lot

You need to figure out why your app is so slow. Caching can only help with a small subset of requests (static assets, primarily, though there are some app caches that can make other kinds of requests faster…but it won’t be Apache or Varnish), and it won’t solve your problem.

What execution mode are you using? Are you sure you have sufficient resources (memory and CPU) to adequately serve your app?

Just want to add to that - opcache is enabled by default when Virtualmin is installed, so it will cache maybe 10,000 PHP files on your system. You already have a cache, @fabi.

It’s Wordpress doing it. That app has become a black hole of performance robbing garbage. It’s code and apps have become so inundated with performance sucking scripts it’s beyond belief.

Caching isn’t really going to help a whole lot because odds are it’s the plugins you’re using and the poorly written code therein that causes the delays.

About the best caching tool for Wordpress is W3 Total Cache. It will help if you have a lot of images on the site, but if you’re running bloated plugins there’s only one way to speed up Wordpress: get rid of every plugin you can.

Unlikely. Probably one or more of the WordPress plugins in use. WordPress itself is pretty good.

Yes. But that’s Wordpress’ fault. They no longer regulate or test the apps like they used to. They’ve allowed it to get so bad that you simply can’t have any plugins at all, which is my entire point in that post.

The only way for Wordpress to not suck is to have no apps, which sort of removes the entire point of having Wordpress to begin with as that is why it was designed - to use apps for specific features.

I run 5 Wordpress sites. They all are slow and they run on minimum apps. This is one of them:

That one was so slow I put it on it on Greengeeks by itself on a plus service account and it’s still slow. It runs only 6 plugins due to Woocommerce. That’s it.

Hi there @ all,

I appreciate a lot your answers and thank you very much.
Is there maybe a option to test if OPcache is working?
I’m using the Divi theme, I know it’s not perfect for WordPress. At the moment no other plugin is activated. The website is about 2M big.
My problem is actually, that the server response time is pretty high, between 2-3 seconds.
Any idea where I can have a look to get this more down?

Thanks a lot @ all

Divi is awful. It’s one of THE slowest themes you can get, especially on a shared hosting plan.

Try an experiment: Switch the theme to the stock Twenty Nineteen or Twenty Twenty template or something like that and see how your speed is. If the site jumps to life and moves along just fine, then it’s just Divi that’s screwing you up.

Hi @ everyone,

Thanks a lot for all your answer.
Yeah I know that Divi is not pretty well for it, but I don’t have any experience in programming a website.
I’ll try to do some testing, maybe I’ll have some success to optimise it.

You can try Hummingbird. It does a pretty decent job. Also, if you haven’t bought Divi and are using a free version, you might try switching to OceanWP. It’s still pretty resource hungry but it’s not nearly as bad as Divi.