Hello,
We have recurring problems in our Mautic test system. Whenever these occur I have to call a fix script from my developer to correct cache and directory permissions.
We don’t know what causes these problems.
There are errors in the logs like:
[2024-01-13 04:43:29] mautic.WARNING: PHP Warning - Undefined variable $inline - in file /var/www/mautic-testsystem.de/offline.php - at line 77 [] {"hostname":"mautic-staging","pid":355937}
[2024-01-13 04:43:29] mautic.ERROR: Symfony\Component\Filesystem\Exception\IOException: Cannot rename "/tmp/catalogue.en_US.l8NCL8I.phpUf139v" to "/var/www/mautic-testsystem.de/var/cache/prod/translations/catalogue.en_US.l8NCL8I.php". - in file /var/www/mautic-testsystem.de/vendor/symfony/filesystem/Filesystem.php - at line 290 [] {"hostname":"mautic-staging","pid":355937}
[2024-01-13 04:43:42] mautic.CRITICAL: Uncaught PHP Exception Symfony\Component\Filesystem\Exception\IOException: "Cannot rename "/tmp/catalogue.en_GB.l8NCL8I.phpDpEV5X" to "/var/www/mautic-testsystem.de/var/cache/prod/translations/catalogue.en_GB.l8NCL8I.php"." at /var/www/mautic-testsystem.de/vendor/symfony/filesystem/Filesystem.php line 290 {"exception":"[object] (Symfony\\Component\\Filesystem\\Exception\\IOException(code: 0): Cannot rename \"/tmp/catalogue.en_GB.l8NCL8I.phpDpEV5X\" to \"/var/www/mautic-testsystem.de/var/cache/prod/translations/catalogue.en_GB.l8NCL8I.php\". at /var/www/mautic-testsystem.de/vendor/symfony/filesystem/Filesystem.php:290)"} {"hostname":"mautic-staging","pid":342758}
[2024-01-13 04:44:30] mautic.WARNING: PHP Warning - require(/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php): Failed to open stream: No such file or directory - in file /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php - at line 197 [] {"hostname":"mautic-staging","pid":342758}
[2024-01-13 04:44:30] mautic.CRITICAL: Uncaught PHP Exception Symfony\Component\Debug\Exception\FatalThrowableError: "Failed opening required '/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php' (include_path='.:/usr/share/php')" at /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php line 197 {"exception":"[object] (Symfony\\Component\\Debug\\Exception\\FatalThrowableError(code: 0): Failed opening required '/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php' (include_path='.:/usr/share/php') at /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php:197)"} {"hostname":"mautic-staging","pid":342758}
[2024-01-13 05:00:09] mautic.WARNING: PHP Warning - require(/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php): Failed to open stream: No such file or directory - in file /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php - at line 197 [] {"hostname":"mautic-staging","pid":355937}
[2024-01-13 05:00:09] mautic.CRITICAL: Uncaught PHP Exception Symfony\Component\Debug\Exception\FatalThrowableError: "Failed opening required '/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php' (include_path='.:/usr/share/php')" at /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php line 197 {"exception":"[object] (Symfony\\Component\\Debug\\Exception\\FatalThrowableError(code: 0): Failed opening required '/var/www/mautic-testsystem.de/var/cache/prod/doctrine/orm/Proxies/__CG__MauticPluginBundleEntityPlugin.php' (include_path='.:/usr/share/php') at /var/www/mautic-testsystem.de/vendor/doctrine/common/lib/Doctrine/Common/Proxy/AbstractProxyFactory.php:197)"} {"hostname":"mautic-staging","pid":355937}
The server runs Mautic version v4.4.10 with PHP version 8.0.28 and MySQL 8.0.18-google.
Do you have an idea why this could be and how this problem can be solved sustainably?
Best regards
Timo