Bug #71296 [Fbk->NoF]: Opcache Fatal error when enabling opcache.file_cache_only

From: Date: Sun, 01 Jul 2018 04:22:22 +0000
Subject: Bug #71296 [Fbk->NoF]: Opcache Fatal error when enabling opcache.file_cache_only
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-216056@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=71296&edit=1

 ID:               71296
 Updated by:       php-bugs@lists.php.net
 Reported by:      cyberdevil001 at telenet dot be
 Summary:          Opcache Fatal error when enabling
                   opcache.file_cache_only
-Status:           Feedback
+Status:           No Feedback
 Type:             Bug
 Package:          opcache
 Operating System: CentOS
 PHP Version:      7.0.1
 Assigned To:      cmb
 Private report:   N

 New Comment:

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.


Previous Comments:
------------------------------------------------------------------------
[2018-06-18 17:54:12] cmb@php.net

> I think debian uses a virtual /tmp/ directory for each process.
> so if you create .opcache within you ssh's /tmp/ that directory
> does not exists in apache's /tmp dir.

Good catch!

> try simply using /tmp/ then it should work

Does it?

------------------------------------------------------------------------
[2018-06-15 13:00:43] spam2 at rhsoft dot net

in 2018 each service should have it's own /tmp and /var/tmp for obvious security reasons and so
/tmp is pretty fine

https://www.freedesktop.org/software/systemd/man/systemd.exec.html

PrivateTmp=
Takes a boolean argument. If true, sets up a new file system namespace for the executed processes
and mounts private /tmp and /var/tmp directories inside it that is not shared by processes outside
of the namespace. This is useful to secure access to temporary files of the process, but makes
sharing between processes via /tmp or /var/tmp impossible. If this is enabled, all temporary files
created by a service in these directories will be removed after the service is stopped. Defaults to
false. It is possible to run two or more units within the same private /tmp and /var/tmp namespace
by using the JoinsNamespaceOf= directive, see systemd.unit(5) for details. This setting is implied
if DynamicUser= is set. For this setting the same restrictions regarding mount propagation and
privileges apply as for ReadOnlyPaths= and related calls, see above. Enabling this setting has the
side effect of adding Requires= and After= dependencies on all mount units necessary to access /tmp
and /v!
 ar/tmp. Moreover an implicitly After= ordering on systemd-tmpfiles-setup.service(8) is added.

------------------------------------------------------------------------
[2018-06-15 12:56:06] php at 9hz dot de

I know it's an old question, but:
>> Why is it not working with /tmp/.opcache while this folder is set in the open_basedir
>> setting:
>> open_basedir	>>
>> /home/admin/:/tmp:/var/tmp:/usr/local/lib/php/:/usr/local/php70/lib/php/

I think debian uses a virtual /tmp/ directory for each process. so if you create .opcache within you
ssh's /tmp/ that directory does not exists in apache's /tmp dir.
try simply using /tmp/ then it should work

------------------------------------------------------------------------
[2017-04-04 14:51:43] max dot novikov at gmail dot com

I've experienced the same issue and found out that you cannot set absolute path for opcache
directory, only relative, for reasons unknown. I.e.
/var/www/html/.opcache doesn't work
../html/.opcache does

------------------------------------------------------------------------
[2016-12-21 13:44:07] sailormax at inbox dot lv

Same problem on Windows. PHP 7.0.14/7.1.0

display_errors = On
display_startup_errors = On
error_reporting = E_ALL
extension_dir = ".\ext"
zend_extension=php_opcache.dll
opcache.enable = 1
opcache.enable_cli = 1
opcache.huge_code_pages = 1
opcache.file_cache = ".\temp\opcache"
opcache.file_cache_only = 1
opcache.file_cache_consistency_checks = 1
opcache.file_cache_fallback = 1

php --version
=> (13140): Fatal Error opcache.file_cache_only is set without a proper setting of
opcache.file_cache

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=71296


--
Edit this bug report at https://bugs.php.net/bug.php?id=71296&edit=1


Thread (10 messages)

« previous php.bugs (#216056) next »