PHP 73 (remi) log level - Warings spam logfile - server disc space runs full

UPDATE:
NethServer Version: 7.9.2009
Module: Stephdl Repo (remi) enabled for all Webpages php-fpm 73

Hi together,

my server space constantly runs full due to warning. There is a faulty PHP coding with in my wordpress page, which is running fine.The page runs under PHP 73 (remi).

[root@nethserver ~]# tail -f /var/opt/rh/rh-php73/log/php-fpm/error-avvp.de.log
[22-Jul-2021 09:59:50 UTC] PHP Warning:  next() expects parameter 1 to be array, null given in /var/lib/nethserver/vhost/avvp.de/wp-includes/class-wp-hook.php on line 308
[22-Jul-2021 09:59:50 UTC] PHP Warning:  current() expects parameter 1 to be array, null given in /var/lib/nethserver/vhost/avvp.de/wp-includes/class-wp-hook.php on line 291
[22-Jul-2021 09:59:50 UTC] PHP Warning:  Invalid argument supplied for foreach() in /var/lib/nethserver/vhost/avvp.de/wp-includes/class-wp-hook.php on line 294

This slows down the server. This fills up the diskspace (dozends of GB within minutes!) until the server is not usable any more. I have to manually truncate the file:

[root@nethserver ~]#  truncate --size 500KB /var/opt/rh/rh-php73/log/php-fpm/*.log

So far so good (bad). Until the problem with the code of the page, wordpress-plugin or whatever is fixed, I want to alter the log level in php-fpm.conf

[root@nethserver ~]# vim  /etc/opt/rh/rh-php73/php-fpm.conf +44
; Log level
; Possible Values: alert, error, warning, notice, debug
; Default Value: notice
log_level = error

systemctl restart php73-php-fpm
service httpd restart

But this has no effect. The warnings are still there. Am I missing something? I know the problem sits between the screen and the back of my chair :slight_smile:

Thank you in advance.

Cheers Axel

@Axel_Pospischil

Hi

It would be nice to know at what version your server is running? The latest 7.9 or an older version…

As a Tip: In the newest version of NethServer, 7.9 incl. updates, PHP 73 (remi) is considered deprecated - NethServer now includes the PHP from Epel, if I’m not mistaken. The functionality to choose PHP versions is available under vhosts…

Hope this helps…

My 2 cents
Andy

Updated thread - the usage of standard repos whould be fine …

THX

1 Like

I would give uninstalling remi-repo a try, but how to revert?

https://wiki.nethserver.org/doku.php?id=php-scl just gives information about installation (which I once used to install it).

UPDATE: found it via cli command (nethserver manager interface does NOT work):

[root@nethserver ~]# yum remove nethserver-stephd
#                    ############################
Loaded plugins: changelog, fastestmirror, nethserver_events
Resolving Dependencies
--> Running transaction check
---> Package nethserver-stephdl.noarch 0:1.1.7-1.ns7.sdl will be erased
--> Finished Dependency Resolution

Dependencies Resolved

=================================================================
 Package                               Arch                      Version                             Repository                   Size
=================================================================
Removing:
 nethserver-stephdl                    noarch                    1.1.7-1.ns7.sdl                     @stephdl                     74 k

Transaction Summary
=================================================================
Remove  1 Package

Installed size: 74 k
Is this ok [y/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : nethserver-stephdl-1.1.7-1.ns7.sdl.noarch                                                                           1/1 
  Verifying  : nethserver-stephdl-1.1.7-1.ns7.sdl.noarch                                                                           1/1 

… takes a lot of time … updating in a few miniutes …

Cheers.

1 Like

php73 of remi or rh-php73 of scl are the same, if the error is logged by one you should have the same issue with the others.

For what I read you only removed my repository, not the remi one

I think I need to obsolete and remove the rpm of php-scl of my repository :confused:

Which WordPress version?
Here are some similar cases, but from quite a while (you might find something useful):
https://core.trac.wordpress.org/ticket/39338


1 Like

Thank you Marc. I look into it and report …

stephdlStéphane de Labrusse Dev Team - 11h

php73 of remi or rh-php73 of scl are the same, if the error is logged by one you should have the same issue with the others.

For what I read you only removed my repository, not the remi one

I think I need to obsolete and remove the rpm of php-scl of my repository

Hi Stéphane, yes this is correct. I had no time yesterday to finish the task. Them rpm’s will not be automatically removed. I have to dig into this which packages I have to remove. The wiki is not that clear about it.
Until now I did not have any problems.

Thanks for you reply.
Axel

1 Like