NYCPHP Meetup

NYPHP.org

[nycphp-talk] Session problem on virtual host?

Stephen Musgrave stephen at musgrave.org
Thu Jan 20 10:25:47 EST 2005


I did a bit more research and it appears that my use of the simple PHP 
session with a clustered environment is a no-no unless using a local 
session directory.  Thanks for pushing me in the right direction.

On Jan 20, 2005, at 2:55 AM, Rolan Yang wrote:

> Does speakeasy employ clustering or load balancing on their web 
> servers?
> If they run multiple machines (with your home directory NFS mounted), 
> the sessions data could be written to /tmp on one machine and not the 
> other. This would result in your session disappearing if you hit the 
> "second" web server and also cause old data to reappear if you were to 
> hit the "first"/original one again.  Using the MySQL sessions handler 
> would prevent this problem.
>
> ~Rolan
>
>
> Stephen Musgrave wrote:
>
>> List -
>>
>>
>> For the most part, this works really well, but from time to time 
>> something goes wrong and it feels like the session gets wiped out or 
>> a formerly used primary key ID reappears into the session, 
>> overwriting the current primary key ID and causes me to overwrite 
>> that record in the database.
>>
> _______________________________________________
> New York PHP Talk
> Supporting AMP Technology (Apache/MySQL/PHP)
> http://lists.nyphp.org/mailman/listinfo/talk
> http://www.nyphp.org
>
>




More information about the talk mailing list