note 43508 deleted from ref.session by danbrown
| From: | danbrown@php.net | Date: | Sun, 20 Jul 2008 18:41:05 +0000 |
| Subject: | note 43508 deleted from ref.session by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-142245@lists.php.net to get a copy of this message | ||
Note Submitter: bcage at tecdigital dot net
----
[Quote]
Someone posted a message here saying you should just all use the MM shared memory management for
sessions. I'd like to CAUTION EVERYONE against using it!
I run a few webservers for a webhosting company, and we quickly ran in to PHP pages segfaulting
Apache for unknown reasons, until we did a test with sessions. It turns out that the sessions,
while using the mm stuff, couldn't keep the data right. I guess it was to do with the file
locking issue mentioned in the documentation here (I didn't notice this until now!).
Anyways, if you run a Unix machine that can map virtual memory to a mount point (like tmpfs or shm
or whatever it may be called), use this instead. It's volatile like mm, but works. Only thing
you don't get is hidden session info so that other people don't know how to open it easily
- but it's better than trying to use mm and having the webserver crash all the time!
[EndQuote]
You're totally right, in my server (FreeBSD 5.2) when using mm to handle sessions, dotProject
wouldn't even start, it crashed when accessing index.php. This was solved by creating a
swap-backed memory disk with the following options
rw,-s60000,,-b=4096,-f=512,-i=560,-c=3,-m=0,nosuid,nodev,nosymfollow