CONTEXT : I have many php scripts executing live...
WHAT I DO :
(to get details of the process containing php...) option -ia show the command...
WHAT I GET :
QUESTION :
The php processes that shows the executing file are ..../bin/php
The php processes that don't show the command have ..../bin/php-cgi `/opt/cpanel/ea-php80/root/usr/bin/php-cgi` => How can I digg deeper to understand what php is doing in those processes ? they run for long time, can I kill them without causing problems ? what is they comes back, how can I pinpoint if there is a bad line of code executing ?? (note : I checked error_log file => no error are being reported) but thoses php-cgi tends to come back.... why ?
WHAT I TRIED {1} :
it says this
WHAT I TRIED {2} :
WHAT I TRIED {3} :
WHAT I DO :
Code:
pgrep -ia php
WHAT I GET :
Bash:
112233 /opt/cpanel/ea-php80/root/usr/bin/php /home/stubfeed/public_html/templates/cron/scan/cron_central_sheraday.php cvpsMaster
223355 /opt/cpanel/ea-php80/root/usr/bin/php-cgi
The php processes that shows the executing file are ..../bin/php
The php processes that don't show the command have ..../bin/php-cgi `/opt/cpanel/ea-php80/root/usr/bin/php-cgi` => How can I digg deeper to understand what php is doing in those processes ? they run for long time, can I kill them without causing problems ? what is they comes back, how can I pinpoint if there is a bad line of code executing ?? (note : I checked error_log file => no error are being reported) but thoses php-cgi tends to come back.... why ?
WHAT I TRIED {1} :
Bash:
pidstat -p 112233
Bash:
Linux 4.18.0-305.19.1.el8_4.x86_64 (host.example.com) 2021-10-14 _x86_64_ (8 CPU)
05:08:53 PM UID PID %usr %system %guest %wait %CPU CPU Command
05:08:53 PM 1001 1234277 0.00 0.00 0.00 0.00 0.00 6 php-cgi
Code:
pstree -aps 112233
systemd,1 --switched-root --system --deserialize 17
└─httpd,3515834 -k start
└─httpd,1233812 -k start
└─php-cgi,112233
Bash:
lsof -p 1234277
Code:
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
php-cgi 1234277 stubfeed cwd DIR 252,1 32 62973745 /home/user/public_html/....
php-cgi 1234277 stubfeed rtd DIR 252,1 4096 128 /
php-cgi 1234277 stubfeed txt REG 252,1 6387136 138429576 /opt/cpanel/ea-php80/root/usr/bin/php-cgi
php-cgi 1234277 stubfeed DEL REG 0,1 110106200 /dev/zero
php-cgi 1234277 stubfeed mem REG 252,1 315112 578898832 /opt/cpanel/ea-php80/root/usr/lib64/php/modules/mailparse.so
php-cgi 1234277 stubfeed mem
Last edited: