Re: Monitoring Memcached

2010-05-12 Thread Oren Teich
Just heard back from Northscale.  The stats command does work.

---

The "stats" command works and gives per-bucket stats right now,
provided the memcached connection is authenticated, so users should be
able to get their own real-time stats already if they know how to use
it. There are some limitations in libmemcached (used by fauna) as to
how it collects stats, so they won't see every stat we put in there,
but I suspect the stats they can see should be enough for most people.

Here is an example session:

$ irb
>> require 'Memcached'
=> true
>> mc = Memcached.new('mc2.ec2.northscale.net:11211', :credentials => ['yours', 
>> '***'])
=> #,
@not_found=#,
@default_ttl=604800, @servers=["mc2.ec2.northscale.net:11211:8"],
@options={:poll_timeout=>0.25, :hash_with_prefix_key=>true,
:default_weight=>8, :connect_timeout=>4, :ketama_weighted=>true,
:logger=>nil, :retry_timeout=>30, :auto_eject_hosts=>true,
:verify_key=>true, :support_cas=>false, :buffer_requests=>false,
:show_backtraces=>false, :rcv_timeout=>0.25, :use_udp=>false,
:hash=>:fnv1_32, :sort_hosts=>false, :credentials=>["yours",
"***"], :tcp_nodelay=>false, :prefix_delimiter=>"",
:server_failure_limit=>2, :binary_protocol=>true,
:distribution=>:consistent_ketama, :no_block=>false,
:cache_lookups=>true, :timeout=>0.25, :default_ttl=>604800},
@not_stored=#>
>> mc.stats()
=> {:bytes_written=>[0], :curr_items=>[0], :rusage_system=>[311.73],
:threads=>[4], :limit_maxbytes=>[67108864], :cmd_get=>[0],
:pointer_size=>[64], :total_connections=>[45892], :cmd_set=>[0],
:bytes=>[0], :total_items=>[0], :evictions=>[0], :time=>[1273713737],
:connection_structures=>[231], :version=>["1.4.4_188_g0117a2c"],
:uptime=>[262848], :get_hits=>[0], :pid=>[21691], :bytes_read=>[0],
:curr_connections=>[202], :rusage_user=>[284.26], :get_misses=>[0]}
>>

limit_maxbytes is meaningless with our bucket engine, but cmd_* and
*_hits and total_items and bytes are all meaningful on a per-bucket
basis. The main stat you can't see with fauna is engine_maxbytes,
which shows the actual maximum size of the bucket.


Oren

On Wed, May 12, 2010 at 6:05 PM, Jonathan Dance  wrote:
> I haven't used memcached on Heroku (or in a while), but vanilla
> memcached has a "stats" query you can run, and I think most memcache
> clients support this. Not sure if it would provide what you're looking
> for, and obviously any monitoring you do you would have to do
> yourself. There's some docs for it in the protocol.txt docs for
> memcache:
> http://code.sixapart.com/svn/memcached/trunk/server/doc/protocol.txt
>
> --wuputah
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Heroku" group.
> To post to this group, send email to her...@googlegroups.com.
> To unsubscribe from this group, send email to 
> heroku+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/heroku?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to her...@googlegroups.com.
To unsubscribe from this group, send email to 
heroku+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.



Re: Monitoring Memcached

2010-05-12 Thread Jonathan Dance
I haven't used memcached on Heroku (or in a while), but vanilla
memcached has a "stats" query you can run, and I think most memcache
clients support this. Not sure if it would provide what you're looking
for, and obviously any monitoring you do you would have to do
yourself. There's some docs for it in the protocol.txt docs for
memcache:
http://code.sixapart.com/svn/memcached/trunk/server/doc/protocol.txt

--wuputah

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to her...@googlegroups.com.
To unsubscribe from this group, send email to 
heroku+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.



Re: Monitoring Memcached

2010-05-12 Thread Oren Teich
At this point you can't.  Northscale is working on expanding their
add-on to offer this type of functionality.

Oren

On Tue, May 11, 2010 at 2:21 AM, Neil  wrote:
> I'm just wondering how you would go about monitoring your memcache
> usage/stats for a given application.
>
> Any ideas?
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Heroku" group.
> To post to this group, send email to her...@googlegroups.com.
> To unsubscribe from this group, send email to 
> heroku+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/heroku?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to her...@googlegroups.com.
To unsubscribe from this group, send email to 
heroku+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.



Monitoring Memcached

2010-05-11 Thread Neil
I'm just wondering how you would go about monitoring your memcache
usage/stats for a given application.

Any ideas?

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to her...@googlegroups.com.
To unsubscribe from this group, send email to 
heroku+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.