Skip to content

[Cache] Zend OPcache seems to be disabled, can't compile file #20878

@ruudk

Description

@ruudk

I'm running Symfony 3.2 on a PHP 7.1 server with Opcache enabled for FPM but not for CLI.

Every time we deploy, this errors gets logged to Sentry:

Symfony\Component\Debug\Exception\FatalErrorException: Zend OPcache seems to be disabled, can't compile file
#1 /vendor/symfony/symfony/src/Symfony/Component/Cache/Adapter/PhpFilesAdapter.php(118): null
#0 Hautelook\SentryClient\ErrorHandler(null): Hautelook\SentryClient\ErrorHandler::handleFatalError

I think this is due the fact that I have opcache.enable_cli => Off. Since the warmup command runs on CLI, it will never work.

Maybe it would be good if the PHPFilesAdapter checks this configuration first, before trying to save it?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions