Jump to content
View in the app

A better way to browse. Learn more.

Froxlor Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (โ‹ฎ) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Hello,

I was searching for a best practice to setup OPcache in combination with PHP-FPM, Apache and Froxlor, but found none.

I tried to read many posts from different forums, but unfortunately I'm not getting anywhere. Also asking AI did not really help.

This is my PHP-FPM pool config:

php_admin_flag[opcache.enable]=1
php_admin_flag[opcache.enable_cli]=1
php_admin_value[opcache.restrict_api]="{DOCUMENT_ROOT}"
php_admin_value[opcache.memory_consumption]=4096
php_admin_value[opcache.interned_strings_buffer]=128
php_admin_value[opcache.max_accelerated_files]=131071
php_admin_flag[opcache.validate_timestamps]=1
php_admin_value[opcache.revalidate_freq]=60
php_admin_flag[opcache.save_comments]=1
php_admin_flag[opcache.fast_shutdown]=1
php_admin_value[opcache.max_wasted_percentage]=5

Somehow the memory usage is immediately full. It does not matter, if I set the memory size to 1024 MB, 4096 MB, 8192 MB, 32768 MB or even 102400 MB. Also the memory usage of the OPcache is not matching with the RAM usage of the server. The server has 12 vCPU and 64 GB of RAM running Debian 12.4.

I'm running about 25 small Wordpress sites, each has about 2-3 visitors per hour, so nearly no traffic and load. If I get the cached scripts with opcache_get_status(true) and sum the memory consumption of each script, I'm reaching about 110 MB.

In the overview the hits count and cached script count should be much higher, since only two out of 25 Wordpress sites are partially cached.

In attachment the OPcache overview page of Froxlor and phpinfo OPcache settings. I'm using PHP-FPM 8.4.12.

Is this an OPcache issue, misconfiguration or know behavior? Does anyone have an idea on how to solve that or maybe I should use another caching mechanism?

Thanks!

screenshot.png

opcache.jpg

there is no real "best practice" as it highly depends on the application, its usage of opcache and what you want that application to be allowed to use. Also as this is simply php.ini and php-related configs, froxlor itself does not really have anything to do with that - best is what is best for your/your website/your application

In attachment the OPcache overview page of Froxlor and phpinfo OPcache settings. I'm using PHP-FPM 8.4.12.

notice that the opcache info page in froxlor only shows opcache info about the fpm-version used in froxlor, it does not and cannot know about potential other fpm-versions your websites might run on

You may also use apcu and/or redis (not without plugin in wordpress) - there are many forms of caching, simply google, check them all out, test, see what fits best for you

  • Author

Ok, thanks. I will also try apcu then.

I know, that is shows only the fpm-version used by Froxlor. I only have one fpm-version and that is used for all sites.

What do you think is the right place to get help with the OPcache config? I'm trying to understand, why not more than about 4.000 files are cached. There are more then enough resources available. I made multiple attemps to understand this in the last months and now I'm here ๐Ÿ˜…

  • Author

I know the manual page, but unfortunately it did not help me. I thought this forum was the right one to ask such questions, but it seems not.

So to formulate it in another way, can you recommend me a forum/community where skilled people discuss thinks like that?

Well sorry I did not meet your expectations of free help...and excuse me if that sounds rough but...there are pages like google that help with finding things you look for on the internet.

  • Author

No problem, I was not expecting you to help me, but thought there were maybe also other users that faced one this problem.

And if you can't find anything that helps you with a search engine like Google you go to a forum and ask community LOL

well you are asking the froxlor community, not the php/opcache community...

No problem, I was not expecting you to help me

wow thanks...

Create an account or sign in to comment

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions โ†’ Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.