Portal Home > Knowledgebase > Articles Database > anyone use memcached on shared servers?


anyone use memcached on shared servers?




Posted by jon-f, 11-19-2007, 08:02 PM
I have been looking into memcached and would like to make it available to all clients who want to use it. I cant really find an ideal on how to allocate the memory in such situations so I figured Id ask and see if anyone else uses memcached on their shared servers. So who uses memcache on their shared servers and whats an ideal memory percentage to start it with? For example if I have a server with 2gb ram, what would be good to start the daemon with?

Posted by wKkaY, 11-20-2007, 12:08 AM
Bear in mind that you should run a separate instance for each customer, as there may be key conflicts otherwise.

Posted by jon-f, 11-20-2007, 06:40 PM
Yeah thats what I was wondering. Ill try to find some more info on that. Thanks

Posted by mpjetta, 11-20-2007, 08:04 PM
You should also bear in mind that the memcached daemon doesn't have any authentication built in so if you were to run multiple instances on the local interface, any user would be able to connect to any local memcached instance and read/write into other user's cache. So long as they can guess the other client's port numbers.

Posted by jon-f, 11-20-2007, 09:45 PM
yeah thats a real good point. Doesnt look like the best idea to use in shared hosting just for that. Thanks

Posted by wKkaY, 11-21-2007, 01:53 AM
That is solvable though if the scripts execute as their owner - apply a user-matching iptables rule to restrict the connections to memcached.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
Setting webmail (Views: 688)
php news page (Views: 654)