memcached running status monitoring

1. Run memcached in verbose mode 

Add the -v or -vv option when starting memcached 
quote
# /usr/local/bin/memcached -d -m 2048  -u root -l 192.168.1.20 -p 12111 -c 1024 -P /tmp/memcached.pid -vv 

-v will display error and warning information 
-vv will display error warning information and commands and responses of each client 

2.telnet access memcached 
quote
# telnet 192.168.1.20 12111

stats: The server will return each line of status information starting with STAT, including 20 lines and about 20 items of information, including the pid, version, number of saved items, memory usage, and maximum memory limit of the daemon process. 

3. memcached tool memcached-tool 
download address: http://code.sixapart.com/svn/memcached/trunk/server/scripts/memcached-tool 
quote
# perl memcache-tool 192.168.1.20:12111 
  #  Item_Size   Max_age  1MB_pages Count   Full? 
  1      88 B      275 s       1    2000      no 
  2     112 B      275 s       2   18000      no 
  5     232 B      127 s       1      11      no 
  6     296 B      127 s       1      64      no 
  7     376 B      127 s       1      79      no 
  8     472 B      127 s       1      96      no 
  9     592 B      127 s       1     120      no 
10     744 B      127 s       1     152      no 
11     936 B      127 s       1     192      no 
12     1.1 kB     126 s       1     239      no 
13     1.4 kB     126 s       1     295      no 
14     1.8 kB     126 s       1     368      no 
15     2.2 kB     125 s       1     455     yes 
16     2.8 kB     125 s       1     364     yes 
17     3.5 kB     125 s       1     291     yes 
18     4.4 kB     125 s       1     232     yes 


4. Graphical interface monitoring memcached 
download address: http://livebookmark.net/memcachephp/memcachephp.zip 
Program file: memcache.php 
Modify the memcached server settings at the beginning of the file 
Html code   Favorite code
  1. $MEMCACHE_SERVERS[] = '192.168.1.20:12111'; // add more as an array  

Deploy memcache.php to the PHP server and access 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326945641&siteId=291194637