I'm facing a strange problem on Symfony: basically sometimes, without any apparent reason, the user is unable to load web pages until I restart php-fpm or until he changes its PHPSESSID
loading a new session. Anyway his session is still working properly after fpm is restarted.
At the same time, I got 2 warnings from PHP:
PHP Warning: session_start(): Session object destruction failed in /home/unix/releases/1/vendor/symfony/symfony/src/Symfony/Component/HttpFoundation/Session/Storage/NativeSessionStorage.php on line 145
PHP Warning: session_start(): Failed to decode session object. Session has been destroyed in /home/unix/releases/1/vendor/symfony/symfony/src/Symfony/Component/HttpFoundation/Session/Storage/NativeSessionStorage.php on line 145
Consider that we are talking about a private website used maximum from 2-3 users concurrently, but it might also happen if just 1 user is navigating on it.
Current setup is
- Debian 9.4 stretch 4.14.0-0.bpo.3-amd64
- php-fpm 7.1.15
- Symfony 3.4.4
I'm able to reproduce the issue using apache ab calling different URLs concurrently using the same session id. Of course after N requests I got timeout:
Completed 100 requests
Completed 200 requests
Completed 300 requests
Completed 400 requests
Completed 500 requests
Completed 600 requests
Completed 700 requests
Completed 800 requests
apr_pollset_poll: The timeout specified has expired (70007)
Total of 872 requests completed
Now I'm trying to check php configuration but actually is quite "normal" without special settings so I don't know what should I try or check. Any thoughts?