MRatWork Forum by Mustafa Ramadhan
Sawo Project - Kloxo-MR Discussions => Kloxo-MR Development => Topic started by: fossxplorer on 2014-03-29, 18:07:43
-
Using the latest update, i'm finally able to start PHP-FPM which config was filled with XML content earlier. But now i can't serve PHP pages:
[Sat Mar 29 18:01:12 2014] [error] [client 192.168.2.150] FastCGI: server "/home/user1/test101.myftp.org/test101.myftp.org.0fake" stderr: Access to the script '/home/user1/test101.myftp.org/index.php/apps/files' has been denied (see security.limit_extensions), referer: http://test101.myftp.org/
Any idea how i can fix it?
[root@kloxo ]# sh /script/sysinfo
A. Kloxo-MR: 6.5.1.b-2014032502
B. OS: CentOS release 6.5 (Final) x86_64
C. Apps:
1. MySQL: mysql-5.5.34-1.el6.x86_64
2. PHP: php55u-5.5.10-1.ius.el6.x86_64
3. Httpd: httpd-2.2.26-2.el6.x86_64
4. Lighttpd: --uninstalled--
5. Hiawatha: hiawatha-9.3.1-1.mr.el6.x86_64
6. Nginx: --uninstalled--
7. Cache: --uninstalled--
8. Dns: bind-9.9.5-1.el6.x86_64
9. Qmail: qmail-toaster-1.03-1.3.38.mr.el6.x86_64
- with: courier-imap-toaster-4.1.2-1.3.16.mr.el6.x86_64
D. Php-type (for Httpd/proxy): php-fpm_event
E. Memory:
total used free shared buffers cached
Mem: 1877 858 1018 0 161 389
-/+ buffers/cache: 308 1568
Swap: 3775 0 3775
-
Find out 'cgi.fix_pathinfo = 0' in /etc/php.ini. By default, value is '1' but for security reason this value set to '0'.
In /home/nginx/conf/globals/php-fpm.conf, disable 'fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;' (use 'customize rule' for change/modified config file).
-
Yes, cgi.fix_pathinfo = 0 inside /etc/php.ini. Now trying to customize the FPM file by having a custom.php53-fpm-pool.conf.tpl inside
/home/php-fpm/tpl and running sh /scripts/fixweb + service php-fpm restart does not change /etc/php-fpm.d/$pool.conf.
How do i customize one specific FPM pool file, e.g /etc/php-fpm.d/user1.conf?
I don't use Nginx, but Hiawatha proxy :)
Find out 'cgi.fix_pathinfo = 0' in /etc/php.ini. By default, value is '1' but for security reason this value set to '0'.
In /home/nginx/conf/globals/php-fpm.conf, disable 'fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;' (use 'customize rule' for change/modified config file).
-
This '/home/user/test.myftp.org/test.myftp.org.0fake' is correct when using php-fpm_worker/_event.
As you can see, this forum using latest 6.5.1.b and nothing problem with php-fpm.
In many situation, nothing problem with 'cgi.fix_pathinfo=0'.
-
Hmm ok.
First of all, after using 2 hours i found a minor issue which is fixed in https://github.com/mustafaramadhan/kloxo/pull/3.
I don't know your policy, but if you merge it, that issue will be fixed.
Secondly, i think you are right that PHP apps are mostly fine with 'cgi.fix_pathinfo=0', but OwnCloud doesn't work it :(
But i can survive by having custom FPM pools, but can you please inform me why the file isn't read when i have a custom.php53-fpm-pool.conf.tpl inside /home/php-fpm/tpl?
Is it possible to have custom rules per FPM pool? E.g one custom conf for /etc/php-fpm.d/user1.conf and another custom conf for /etc/php-fpm.d/user2.conf .
-
Custom file work.
I didn't found any issue to implementing custom file for php-fpm. Only need custom.php53-fpm-pool.conf.tpl for handle all users.
Before latest update of KLoxo-MR 6.5.1 I was using custom file for different allocate of max_children. In latest version, you can set in panel under 'limit' or 'resource plans' for 'Number Of FastCGI Children'. Choose 'Unlimited' will be intrepretate as '6'.
-
I got it working after running sh /scripts/fix-all.
Oh it's great that we can set this in resource plans!
Thank you very much for you help.