Checking write permissions for PHP session data

I stumbled on information like the following while I would like to try another application example out also together with the software “Symfony 6.0”.

Markus_Elfring@…> symfony server:start
…
 [OK] Web server listening                                                                                              
      The Web server is using PHP FPM 8.0.13                                                                            
…
[Web Server ] Dec 13 10:03:52 |DEBUG  | PHP    Using PHP version 8.0.13 (from default version in $PATH) 
[Application] Dec 10 11:09:51 |DEBUG  | SECURI Checking for authenticator support. authenticators=0 firewall_name="main"
[Application] Dec 10 11:09:52 |CRITICA| REQUES Uncaught PHP Exception ErrorException: "Warning: SessionHandler::read(): open(/var/lib/php8/sess_cse9o2tj2021tmp3qo3baijokm, O_RDWR) failed: Permission denied (13)" at /home/…/vendor/symfony/http-foundation/Session/Storage/Handler/StrictSessionHandler.php line 45 
[Application] Dec 10 11:09:52 |ERROR  | APP    error while trying to collect executed migrations 
[Application] Dec 10 15:09:14 |INFO   | REQUES Matched route "main". method="GET" request_uri="http://127.0.0.1:8000/start" route="main" route_parameters={"_controller":"App\\Controller\\IndexController::display_document","_route":"main"}
[Application] Dec 10 15:09:14 |DEBUG  | SECURI Checking for authenticator support. authenticators=0 firewall_name="main"
[Application] Dec 10 15:09:14 |CRITICA| REQUES Uncaught PHP Exception ErrorException: "Warning: SessionHandler::read(): open(/var/lib/php8/sess_jl9aljcsh2h8obb9g3l7k7k264, O_RDWR) failed: Permission denied (13)" at /home/…/vendor/symfony/http-foundation/Session/Storage/Handler/StrictSessionHandler.php line 45 
…

:\ Would you like to add any solution ideas?

I suggest to take another look at a corresponding software test approach.

<?php
$handle = fopen('/var/lib/php8/sessions/test-data.txt', 'w+');
if ($handle) {
    fwrite($handle, "session test data
");
}
?>

Which packages do influence the system settings under which circumstances selected user groups may write data into mentioned directories?

Would you expect a permission configuration like the following? :\

Markus_Elfring@…:~> ls -l -d /var/lib/php8/sessions 
drwxrwxr-x 2 wwwrun wwwrun 4096 16. Dez 08:45 **/var/lib/php8/sessions**

:\ I am curious how the clarification will evolve further also for the issue “Checking the application of the configured session storage directory”.