Like yo, do you fellas see what I do on your machines? $ find /tmp -name sess* 2>&-|wc -l 95853 $ find /tmp -name sess* ! -empty 2>&-|wc -l 42637 $ find /tmp -name sess* ! -empty 2>&-|xargs more 2>&-|less /tmp/sess_d4espd7ur01k7rq75f83ff7t45 :::::::::::::: wsUserID|i:3;wsUserName|s:4:"Jini";wsToken|s:32:"... /tmp/sess_rqc4ufi3ev1g8on3novneb9dc7 :::::::::::::: wsUserID|i:2;wsUserName|s:9:"WikiSysop";wsToken|s:32:"...;wsEditToken|s:32:"-...
Any better way than "leaving all those candy bar wrappers on the floor"?
jidanni@jidanni.org wrote:
Like yo, do you fellas see what I do on your machines? $ find /tmp -name sess* 2>&-|wc -l 95853 $ find /tmp -name sess* ! -empty 2>&-|wc -l 42637 $ find /tmp -name sess* ! -empty 2>&-|xargs more 2>&-|less /tmp/sess_d4espd7ur01k7rq75f83ff7t45 :::::::::::::: wsUserID|i:3;wsUserName|s:4:"Jini";wsToken|s:32:"... /tmp/sess_rqc4ufi3ev1g8on3novneb9dc7 :::::::::::::: wsUserID|i:2;wsUserName|s:9:"WikiSysop";wsToken|s:32:"...;wsEditToken|s:32:"-...
Any better way than "leaving all those candy bar wrappers on the floor"?
Configure your php to use another folder, store the sessions in memcached....
jidanni@jidanni.org wrote:
Like yo, do you fellas see what I do on your machines? $ find /tmp -name sess* 2>&-|wc -l 95853
*snip*
Any better way than "leaving all those candy bar wrappers on the floor"?
The session file save path and garbage collection frequency are configurable in PHP's settings:
http://de3.php.net/manual/en/session.configuration.php
Additionally you might consider using memcached for storage of session data, if you are using memcached. You can enable this by setting $wgSessionsInMemcached = true; in your LocalSettings.php.
-- brion
On Fri, Apr 3, 2009 at 8:19 AM, jidanni@jidanni.org wrote:
Any better way than "leaving all those candy bar wrappers on the floor"?
Every PHP program ever does this. This is what /tmp is *for*. If you are sensible and put your /tmp on a ramdisk then it get clears per restart anyway. A non-issue.
If you really dislike it, look at storing sessions in memcached, which *also* stores data in RAM, but the data goes away if memcached crashes, and you don't have any 'ls /memcached' output to clutter up. The advantage to memcached is that you can access the sessions from multiple machines.
Like yo, do you fellas see what I do on your machines?
mediawiki-l? http://php.net/mailing-lists.php?
Domas
wikitech-l@lists.wikimedia.org