I want to store information (sessions and a lot of strings) in RAM and I don't know if I should use a tmpfs or a memcached server. Someone did some benchmark and knows which one is faster? It's needed for some ajax scripts that requests informations every 1-5 seconds per user who is logged in, like a webchat in PHP. So PHP has to connect to memcache quite often.
The advantage of using tmpfs whould be that I can create a lot of files and have a structur (dirs), while I only have a key-value system in memcached, but there i could use arrays or objects to store information. CPU load whould be interesting, too, if there is any difference.
Thanks.
Just a couple points
If you don't expect you data to our grow the memory on your server use tmpfs.
If you must share the data between servers or want to store more data that whats fits into the RAM on your local server use memcahed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With