in reply to SOLVED: How to create sessions via FastCGI?
I wanted to add a comment here as this article helped point me in the right direction.
Issues we were seeing:
1) Sometimes the session ID in the code was not that of the cookie we saw on the client side.
2) We isolated this down to having more than one instance of FastCGI running as failure rates increased the more instances one had going.
3) Even with a single instance, we still had failure.
4) Restarting apache also trashed our session for end clients.
After much review... I found success in doing the following:
1) DONT create your session within the FastCGI loop.
2) DO create your session inside an area that is called by your fast CGI app. In our case it was something like "ProcessRequest".
By us change the where we created sessions... We were able to:
1) Constantly read a cookie. Even after an apache restart.
2) Handle multiple instances of FastCGI 1-???.
3) Timeouts from FastCGI also no longer had negative impacts on our sessions.
Good luck... Glad I could share our resolution. And thanks for the original post as this is what helped me find our issues.