Is memcached a good way to store session share ammong web servers?

howard chen howachen at gmail.com
Mon Nov 13 04:37:48 UTC 2006


On 11/13/06, Evert | Rooftop <evertpot at gmail.com> wrote:
> The best possible situation is:
>
> * don't let sessions expire
> * only update memcached and the database when session information is
> updated (so record what the sessiondata was on the beginning of the script)
> * read session data from memcached.. if it isn't there, use the database
>
> But yea.. this will only work for non-expiring sessions. If you need
> your sessions to timeout in a while, its harder because you need to keep
> updating the databaseserver with the last request time..
>
> Evert
>
> howard chen wrote:
> > Anyone used memcached to store sessions?
> >
> > Are there any special thing need to take care of? e.g. session expire?
> >
> > Thanks.
> >
>

why need to store the session on the database?

why not just use memcached as a shared drive for session?

howard


More information about the memcached mailing list