[phpa] Re: phpa.cache_dir = /dev/shm?
- From: "Nick Lindridge" <nick@xxxxxxxxxxxxxxxxxxxxx>
- To: <phpa@xxxxxxxxxxxxx>
- Date: Sun, 19 May 2002 22:57:02 -0000 ()
> Would there be any issues specifying the cache directory as /dev/shm?
> I don't think I quite understand the difference between 'shared
memory'
> and /dev/shm. Can someone explain?
> I was thinking that I could increase performance even more by
> specifying /dev/shm as the cached directory, rather than an actual
> directory on a physical disk. Any thoughts?
Hi James,
Nice idea, but not necessary for phpa. PHPA has two caches - the file
cache and the shm cache. The file cache provdes an unlimited size
secondary cache, but the main cache is in shared memory, and is highly
optimised to be about as fast as is technically possible. So, given
empty caches, the first access reads the script in the normal way, its
compiled, optimised by phpa, cached to disc, and remembered as needing
to be cached in shm. At the end of the request it gets cached in shm.
The next access will accesses will access the script from the shm. If
you restart the server then the script will be accessed from the file
cache and recached in shm again.
So, no, leave it as a file cache.
You might take a look at my short paper on phpa internals that's
available on my site.
nick
------------------------------------------------------------------------
www.php-accelerator.co.uk Home of the free PHP Accelerator
To post, send email to phpa@xxxxxxxxxxxxx
To unsubscribe, email phpa-request@xxxxxxxxxxxxx with subject unsubscribe
- References:
- [phpa] phpa.cache_dir = /dev/shm?
- From: James Simmons
Other related posts:
- » [phpa] phpa.cache_dir = /dev/shm?
- » [phpa] Re: phpa.cache_dir = /dev/shm?
- [phpa] phpa.cache_dir = /dev/shm?
- From: James Simmons