Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Help me to find the Best Opcache Configuration
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Help me to find the Best Opcache Configuration

Hello,

Please help me, to find the best opcache configuration for performance. Got too many memory in the server... :)

Here is my current configuration:

opcache.memory_consumption=512
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=4000
opcache.revalidate_freq=60
opcache.fast_shutdown=1
opcache.enable_cli=1

Comments

  • ZweiTiger said: find the best opcache configuration

    I don't think there is a best configuration for opcache it's depend of what kind of site's your hosting.

    Is this for your shared hosting offering or just personal sites.

  • @Razza said:

    ZweiTiger said: find the best opcache configuration

    I don't think there is a best configuration for opcache it's depend of what kind of site's your hosting.

    Is this for your shared hosting offering or just personal sites.

    shared

  • opcache.enable=1
    opcache.enable_cli=1
    opcache.memory_consumption=512
    opcache.interned_strings_buffer=8
    opcache.max_accelerated_files=50000
    opcache.max_wasted_percentage=15
    opcache.use_cwd=1
    opcache.validate_timestamps=1200
    opcache.revalidate_freq=0
    opcache.revalidate_path=1
    opcache.save_comments=1
    opcache.fast_shutdown=1
    opcache.consistency_checks=1
    

    This is my current settings in a shared environment. I didn't thoroughly test it though it's running and looks like it's more than enough for my current needs as I am not hosting hundreds of domains, let alone thousands...

  • ZweiTiger said: shared

    If it's shared hosting is setting opcache.validate_timestamps to 60 sec could cause a issue as that control how offen Opcache will check the file timestamps for updates.

    Let's say a user edit's a php file, it could take up-to 60 sec for the change to be effective if the file is already cached, that would probably confuse the user.

  • @Nomad said:
    opcache.enable=1
    opcache.enable_cli=1
    opcache.memory_consumption=512
    opcache.interned_strings_buffer=8
    opcache.max_accelerated_files=50000
    opcache.max_wasted_percentage=15
    opcache.use_cwd=1
    opcache.validate_timestamps=1200
    opcache.revalidate_freq=0
    opcache.revalidate_path=1
    opcache.save_comments=1
    opcache.fast_shutdown=1
    opcache.consistency_checks=1

    This is my current settings in a shared environment. I didn't thoroughly test it though it's running and looks like it's more than enough for my current needs as I am not hosting hundreds of domains, let alone thousands...

    Thank you very much, i will try!

    @Razza said:

    ZweiTiger said: shared

    If it's shared hosting is setting opcache.validate_timestamps to 60 sec could cause a issue as that control how offen Opcache will check the file timestamps for updates.

    Let's say a user edit's a php file, it could take up-to 60 sec for the change to be effective if the file is already cached, that would probably confuse the user.

    Yes you are right.. :)

    Thank you very much!

Sign In or Register to comment.