Mailing List Archive

Mythweb with php 7.2
Can anyone confirm if mythweb works with php 7.2? Apache child process
crash hard with mythweb and php 7.2. I have not been able to find any
reported issue in the git repo. When I remove mythweb, the apache server
works correctly with basic phpinfo page.

Running mythtv 29.1 with the latest mythweb.
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: Mythweb with php 7.2 [ In reply to ]
On Thu, 2018-02-01 at 21:08 -0500, Kevon wrote:
> Can anyone confirm if mythweb works with php 7.2? Apache child process
> crash hard with mythweb and php 7.2. I have not been able to find any
> reported issue in the git repo. When I remove mythweb, the apache server
> works correctly with basic phpinfo page.
>
> Running mythtv 29.1 with the latest mythweb.
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org

mine is working on 7.2, i am on arch linux all current packages. but
since 7.2 i get this message only in recorded programs listing page:

> Warning at /srv/http/mythweb/modules/tv/recorded.php, line 189:
> !!NoTrans: Use of undefined constant disk_used - assumed 'disk_used'
> (this will throw an Error in a future version of PHP)!!

at the top of that page but the normal output is under that message.
otherwise it is the same. but i remember having a problem until i
realized there was a whole new php.ini under 7.2 and i had to go in and
enable the correct settings (modules) in that file. again this is under
arch linux, so maybe check your php.ini settings.
Re: Mythweb with php 7.2 [ In reply to ]
On 02/01/18 21:21, glen wrote:
> On Thu, 2018-02-01 at 21:08 -0500, Kevon wrote:
>> Can anyone confirm if mythweb works with php 7.2? Apache child process
>> crash hard with mythweb and php 7.2. I have not been able to find any
>> reported issue in the git repo. When I remove mythweb, the apache server
>> works correctly with basic phpinfo page.
>>
>> Running mythtv 29.1 with the latest mythweb.
>> _______________________________________________
>> mythtv-users mailing list
>> mythtv-users@mythtv.org
>> http://lists.mythtv.org/mailman/listinfo/mythtv-users
>> http://wiki.mythtv.org/Mailing_List_etiquette
>> MythTV Forums: https://forum.mythtv.org
>
> mine is working on 7.2, i am on arch linux all current packages. but
> since 7.2 i get this message only in recorded programs listing page:
>
>> Warning at /srv/http/mythweb/modules/tv/recorded.php, line 189:
>> !!NoTrans: Use of undefined constant disk_used - assumed 'disk_used'
>> (this will throw an Error in a future version of PHP)!!
>
> at the top of that page but the normal output is under that message.
> otherwise it is the same. but i remember having a problem until i
> realized there was a whole new php.ini under 7.2 and i had to go in and
> enable the correct settings (modules) in that file. again this is under
> arch linux, so maybe check your php.ini settings.
>
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org
>

Thanks for the info. I am on a different distro, but the php.ini is the
standard vanilla version. IIRC, I only had mysqli enabled in my pass
configs. Do you mind posting your php.ini on pastebin so I can compare?
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: Mythweb with php 7.2 [ In reply to ]
>>
>> Thanks for the info. I am on a different distro, but the php.ini is
>> the
>> standard vanilla version. IIRC, I only had mysqli enabled in my pass
>> configs. Do you mind posting your php.ini on pastebin so I can
>> compare?
>
> i just took them from the wiki on arch : https://wiki.archlinux.org/ind
> ex.php/MythWeb and adjusted the open_basedir
>

Glen,
Thanks for the pointers. Turns out mod_mpm_event.so was causing my http
process to crash. Switching to mpm_prefork_module prevented the crash,
and started generating some meaningful php errors. Enabling the
mod_deflate.so and updating "open_basedir =" in the php.in file restored
full functionality.
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: Mythweb with php 7.2 [ In reply to ]
On Fri, Feb 2, 2018 at 10:02 PM Kevon <mythtv@reidsresidence.com> wrote:

> Glen,
> Thanks for the pointers. Turns out mod_mpm_event.so was causing my http
> process to crash. Switching to mpm_prefork_module prevented the crash,
> and started generating some meaningful php errors. Enabling the
> mod_deflate.so and updating "open_basedir =" in the php.in file restored
> full functionality.
>

Can you elaborate a bit more on your "fix"? I have previously corrected the
mpm_event -> mpm_prefork and I now have an official bug report[1] at RPM
Fusion.

I need to fix this from a packaging perspective so I may need to add a
config file to the package to put in /etc/php.d...

Thanks,
Richard
Re: Mythweb with php 7.2 [ In reply to ]
Let me know if you don't get a response. I have a look and see how we do
it. We both Ubuntu and Redhat at work serving huge web loads. Its a
while since i set one up, but php being not thread safe is a pain.


On 13/06/2018 1:38 AM, Richard Shaw wrote:
> On Fri, Feb 2, 2018 at 10:02 PM Kevon <mythtv@reidsresidence.com
> <mailto:mythtv@reidsresidence.com>> wrote:
>
> Glen,
> Thanks for the pointers. Turns out mod_mpm_event.so was causing my
> http
> process to crash. Switching to mpm_prefork_module prevented the crash,
> and started generating some meaningful php errors. Enabling the
> mod_deflate.so and updating "open_basedir =" in the php.in
> <http://php.in> file restored
> full functionality.
>
>
> Can you elaborate a bit more on your "fix"? I have previously
> corrected the mpm_event -> mpm_prefork and I now have an official bug
> report[1] at RPM Fusion.
>
> I need to fix this from a packaging perspective so I may need to add a
> config file to the package to put in /etc/php.d...
>
> Thanks,
> Richard
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org
Re: Mythweb with php 7.2 [ In reply to ]
On Wed, Jun 13, 2018 at 12:11 AM, Stephen Collier <stephenbcollier@gmail.com
> wrote:

> Let me know if you don't get a response. I have a look and see how we do
> it. We both Ubuntu and Redhat at work serving huge web loads. Its a while
> since i set one up, but php being not thread safe is a pain.
>
Kevon, I'm not quite sure how you have your webserver setup, but usually
one uses PHP-FPM and proxy_fcgi (Apache 2.4, if you have 2.2 then you
probably should upgrade) ; you don't leave PHP compiled as a DSO to be
linked into Apache at runtime.

This separation allows for better front-end static file scaling, and PHP in
the FastCGI Process Manager mode is basically a queue of multiple PHP
runners available to take a php request from the webserver each as a
separate process. Since no processes are spawned, simply some inter-process
communication, there is very low latency and far less memory thrashing than
with prefork/CGI and performance pretty much on-par with prefork+DSO.

You could even put the PHP process manager on a wholly different computer
or cluster, and only have a web front-end serving content. The FPM
connects to Apache with a simple TCP socket.

The other, far less used (but required in very old cases of multithreaded
webservers before FastCGI was a thing, such as Roxen 2....from 2001...yes
I'm old) was to enable the ZTS Zend Thread Safety option upon compiling
PHP. This would allow you to link the DSO into Apache Event-MPM without it
crashing; but you suffer in performance, because PHP's code was initially
designed to be stateless, and keeping a threaded state while 1 web process
may be handling a ton of requests at a given time, incurs a performance
penalty.

So you can toss out mpm-prefork if you really want to use Event, as long as
you use the PHP-FPM / proxy_fcgi method. It should stand to be noted that
the vast majority of Distribution-provided PHP installs are NON-threadsafe,
which implies prefork+dso OR CGI OR FPM; to get thread safety you'd need to
very likely compile PHP manually.

Mike