PHP-FPM State "Reading headers"

255 views
Skip to first unread message

Florian Götz

unread,
Nov 27, 2018, 6:36:05 PM11/27/18
to highload-php-en
Hi folks,
I'm using php-fpm (7.2.5) with an Apache (2.4.33) to get a rather big Typo3 instance running.
When checking the status of the php-fpm processes (https://address.de/status?full) I see most of the processes in state "Reading headers" like the one below:

pid:                  7871
state:                Reading headers
start time:           27/Nov/2018:14:37:42 +0100
start since:          271
requests:             3
request duration:     168800509
request method:       -
request URI:          -
content length:       0
user:                 -
script:               -
last request cpu:     0.00
last request memory:  0


If I restart php-fpm, I get the usual count of requests I'm used to, but after some time most of the processes are in state "Reading headers" and php-fpm get stuck. 
After that the apache starts struggeling, because his php handler won't answer anymore and he sometimes also get stuck.

I have absolutely no clue what causes the state "Reading headers". And if I watch the connections in the apache log, there are just "valid" page calls, nothing serious or suspicious.
The php-fpm pool is configured in dynamic mode like this:

pm = dynamic
pm.max_children = 150
pm.start_servers = 50
pm.min_spare_servers = 20
pm.max_spare_servers = 50
pm.process_idle_timeout = 10s;
pm.max_requests = 100

Maybe someone of you has a clue what mistake I made.

Best regards
Florian

Anoop Alias

unread,
Nov 28, 2018, 1:05:09 AM11/28/18
to Highload Php En
Try swapping httpd with nginx . That way you can rule out an issue with mod_proxy_fcgi

--

---
You received this message because you are subscribed to the Google Groups "highload-php-en" group.
To unsubscribe from this group and stop receiving emails from it, send an email to highload-php-...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
Anoop P Alias 

Florian Götz

unread,
Nov 28, 2018, 4:01:18 AM11/28/18
to highload-php-en

That's a rather difficult approach.
There are about 35 subdomains involved an a lot of different interest groups.....aka a lot of trouble. :(
I was searching about an issue with mod_proxy_fcgi, but didn't find something appropriate.
Reply all
Reply to author
Forward
0 new messages