Bug #72050 [Fbk->NoF]: Problems loading XSLT style sheets from some, but not all, PHP-FPM workers

From: Date: Sun, 08 Aug 2021 04:22:14 +0000
Subject: Bug #72050 [Fbk->NoF]: Problems loading XSLT style sheets from some, but not all, PHP-FPM workers
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-235672@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=72050&edit=1 ID: 72050 Updated by: php-bugs@lists.php.net Reported by: dirkjan at ochtman dot nl Summary: Problems loading XSLT style sheets from some, but not all, PHP-FPM workers -Status: Feedback +Status: No Feedback Type: Bug Package: FPM related Operating System: Linux PHP Version: 5.6.20 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: ------------------------------------------------------------------------ [2021-07-28 12:11:00] cmb@php.net Do you still experience this issue with any of the actively supported PHP versions[1]? [1] <https://www.php.net/supported-versions.php> ------------------------------------------------------------------------ [2016-04-18 14:23:33] dirkjan at ochtman dot nl Some further info: PHP-FPM worker running as apache:apache. File permissions: djc@enrai http $ ls -l total 14 drwxr-xr-x 14 djc users 600 Oct 31 2012 assets (...) djc@enrai http $ ls -l assets/ total 185 (...) drwxrwxr-x 2 djc users 168 Nov 2 2012 xsl djc@enrai http $ ls -l assets/xsl/ total 44 -rw-r--r-- 1 djc users 8910 Oct 4 2015 basic.xsl (...) So, there should not be any permission problems. ------------------------------------------------------------------------ [2016-04-18 14:18:54] dirkjan at ochtman dot nl Description: ------------ In one of my legacy websites, I'm using XSLT using the XSLTProcessor class from the xslt extension: function process() { $xslt = new XSLTProcessor(); $xslt->importStylesheet($this->xsl); foreach ($this->params as $name => $value) { $xslt->setParameter('', $name, $value); } return $xslt->transformToXML($this->xml); } The XSLT stylesheet I'm using also does some includes, with paths relative to the executed PHP script: <xsl:include href="assets/xsl/basic.xsl" /> However, since migrating to PHP-FPM, I've found that sometimes, the worker processes get into a state where some workers work correctly, however some workers fail to find the included XSL sheets, resulting in errors: Warning: XSLTProcessor::importStylesheet(): I/O warning : failed to load external entity "/var/www/hebe.nl/http/assets/xsl/basic.xsl" in /var/www/hebe.nl/http/include/classes.sys.php on line 315 Warning: XSLTProcessor::importStylesheet(): compilation error: file /var/www/hebe.nl/http/ line 14 element include in /var/www/hebe.nl/http/include/classes.sys.php on line 315 Warning: XSLTProcessor::importStylesheet(): xsl:include : unable to load /var/www/hebe.nl/http/assets/xsl/basic.xsl in /var/www/hebe.nl/http/include/classes.sys.php on line 315 When restarting PHP-FPM, the problem fixes itself, but that's not a very nice way to solve it. :) Expected result: ---------------- XSLT includes should work (or not) consistently. Actual result: -------------- Reloading the page sometimes results in the correct HTML, sometimes has errors. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=72050&edit=1

« previous php.bugs (#235672) next »