I have a VPS running a few independent Drupal sites (not multi-site). What considerations do I need to make (if any) when installing memcache?
2 Answers
Make sure your settings.php file has a unique prefix for each site that has memcache enabled. I got tripped up by this, and everything went berserk. This thread fixed it for me. Basically, this is the only issue you would have as far as conflicts.
http://drupal.org/node/1416102
Like APC, memcache works indepedently of your sites. Make sure you have enough memory for it to function correctly. You can get a rough idea idea by seeing how much disk space all of your drupal databases take up. Not all tables in each database will be cached of course, but so long as you have that much memory to dedicate to memcache, you are good to go.
Said differently, as an example I have 12 sites on my VPS 4 gigs of RAM total with 1 Gig dedicated to memcache. I have never had a problem. Total size of databases on disk is around 400 mb.
Then important thing is that you give each site a different prefix, see http://drupal.org/node/1131468.
Of course, it's the same about memory as with APC. Depending on how much memory you have, you might want to use memcache only for sites which have a high(er) load than others and keep cache of the less used ones in the database or use another cache backend that doesn't sit in memory.