memcached Monitoring
What is the best way to monitor memcached from a Java application on a Linux machine? I would like information such as: 1) Memory used by each object 2) Number of items evicted for reclaiming memory 3) etc.. ...
What is the best way to monitor memcached from a Java application on a Linux machine? I would like information such as: 1) Memory used by each object 2) Number of items evicted for reclaiming memory 3) etc.. ...
I have a fairly large Rails app, which uses memcached on a seperate server as its cache store. The problem is that I randomly get errors in the production environment which seem to indicate that memcached is returning an incorrect object. Examples: In this example, current_site is a helper method which accesses a method on the Site m...
I'm trying to use Memcached and wondering if there is a way to remove the objects from the cache by key pattern rather than just one key per object. Say, I cache user 1 with key "user1", then user 2 with key "user2" ..., is there a way to remove all objects with a key that starts with "user"? Or is there a way to get an enumerator from ...
Is there a way to collect the memcached stats using this API (spymemcached)? I know there are tools like cacti to collect information on Memcached Server. But I would like to collect, say, memory usage by each item I have put into the server--the total no. of items in the same category, etc... more importantly, the bytes used by individ...
Hi, I've taken a bit of a memcache script that i've used previously without issue, but on the new page, I don't get any response. the memcache is in a function which is included from another page. what I do is put the md5 hash the mysql query and store that as the key for the memcached data. if the key isn't in memcache, then I go, cr...
Is it possible to use two session types simultaneously in Rails? Memcached for speed on reads and say SQL for persistence? I hate the idea of losing all sessions on reboots. MemcacheDB as mentioned below looks promising, but the idea would be to make all writes to disk, and all reads come from memory if possible. ...
I don't mean actually installing it. I currently use LAMP for development and would like to start using memcached for a high traffic site. Which types of db calls should be cached? (all?) and what is a good way to do load testing on a development server? Are there benchmarks that I should be looking at on my production site first? T...
Other than MongoDB and Memcached, what key-value stores run on Windows? Most of the ones I've seen seem to only run on Linux (Hypertable, Redis, Lightcloud). Related links: http://stackoverflow.com/questions/639545/is-there-a-business-proven-cloud-store-keyvalue-database-open-source http://www.metabrew.com/article/anti-rdbms-a-list-of-...
SELECT a.* b.* c.* FROM TOPIC a, BOARD b, MSGS c WHERE c.MessageID = 1 AND a.TopicID = c.MessageID AND b.BoardID = c.BoardID How to memcache this data? - set_cache("MY_WACKY_QUERY_1", data) note: 1 is the message id Now there are lots of places in the code which update these 3 tables (independantly of each other), so we need to del_cac...
I ready this article: http://www.mysqlperformanceblog.com/2006/09/27/apc-or-memcached/ from way back when.. I want to get the best cacheing engine available so that my application is really fast. Of cource I don't want to overcache but I want to at least choose the best thing out there. In that article it says memcached is slow and apc i...
Something I'm curious about.. What would be "most efficient" to cache the generation of, say, an RSS feed? Or an API response (like the response to /api/films/info/a12345). For example, should I cache the entire feed, and try and return that, as psuedo code: id = GET_PARAMS['id'] cached = memcache.get("feed_%s" % id) if cached is not N...
I have a rather small (ca. 4.5k pageviews a day) website running on Django, with PostgreSQL 8.3 as the db. I am using the database as both the cache and the sesssion backend. I've heard a lot of good things about using Memcached for this purpose, and I would definitely like to give it a try. However, I would like to know exactly what w...
I've been working on a complex project using a and distribuited application that requires caching SQL queries: since I've been using iBatis framework, I'd like to use memcached - sysadmin requires it - as caching engine. Is it possible? If yes, does anyone know existing solutions/implementations? I already know OSCACHE works also in clus...
I want to use cache-money but I don't want to start automatically caching everything (I'm working with a large production app, terabytes of data etc). How do I use it for only the models that I specify? Right now I've got: # initializers/cache_money.rb require 'cache_money' config = (cfg = YAML.load(IO.read(File.join(RAILS_ROOT, "con...
I have a model along the lines of: class Account < ActiveRecord::Base has_many :payments has_many :purchases def balance payments.sum(:dollar_amount) - purchases.map{|p| p.dollar_amount}.sum end end I want to memoize the balance method and store it in memcached. The problem, of course, is that the cached value needs to...
Hello everybody, as database transcations in our app are getting more and more time consuming, we have started to use memcached to reduce the amount of queries passed to MySQL. All in all, it works fine and really saves a lot of time. But as caching was "silently appearing" as a workaround to give the app more juice, a lot of our mode...
I'm using Merb::Cache for storing txt/xml and have noticed that the longer I leave my merbs running the larger the amount of open tcp sockets I have open -- I believe this is causing some major performance problems. lsof | grep 11211 | wc -l 494 merb 27206 root 71u IPv4 13759908 TCP localhost.local...
Hi, Need some help about with Memcache. I have created a class and want to store its objects in Memcache, finding trouble doing so please tell me where am I going wrong. Following is my code // Class defined by me class User { public $fname; public $age; /** * @return unknown */ ...
I'm having trouble diagnosing a problem I'm having on my ubuntu scalr/ec2 production environment. The trouble is apparently randomly, database queries and/or memcache queries will take MUCH longer than they should. I've seen a simple select statement take 130ms or a Memcache fetch take 65ms! It can happen a handful of times per request,...
Looking around the web I see a number of plugins and patterns for using memcached in rails. I'm working on a new project and am wondering what the best of breed solutions are. Google turns up a lot of older results, which I'm not sure are the latest and best ways of doing things. ...