The problem I was facing – session variables not getting passed from page to page. On page1.php I set some session variables and then on going to page2.php all I was getting was Array() ! The problem drove me crazy as everything settings and permissions were fine.
I have ISPConfig 3 on Ubuntu 18.04 and PHP 7.2.
Session path, folder ownership, folder permission, cookie path everything was fine. On checking the Session folder found that the session file is getting created properly and the session variables also got saved in files properly. Also had session_start() at the beginning of every page. And there was no error or warnings. But when going to next page – nothing in session!
Then on further analysis found the issue is all about the PHPSESSID cookie being set by ISPConfig control panel. After logging out of ISPConfig panel when I opened my pages the SESSION variables got passed fine.
I spent a whole day trying to find issues with the setup or server configuration. Hope this saves someone else’s time.