memcached Startup parameters and stats command descriptions

Source: Internet
Author: User
Tags cas memcached
How to start/End the memcached under Linux in the current project
By default, memcached is installed under/usr/local/bin.
Go to the installation directory, start memcached:/usr/local/memcached/bin/memcached-d-c 10240-m 1024-u root get running status: Echo Stats | NC localhost 11211 (can view the PID) or use Ps-ef|grep memcached  stop memcached:kill-9 pid   (-9 for forced kill, PID for process identifier)-D option is Move a daemon,-M is allocated to memcache use of memory, the unit is MB, here is 1024MB, the default is 64mb-u is running memcache user, here is the root-l is the server IP address of the listener, the default should be native-p is set Memcache listening port, the default is 11211, preferably more than 1024 of the port-C option is the maximum number of concurrent connections, the default is 1024, here set 10240, according to the load of your server set-P is set to save memcache PID file Location- H Print Help information-V Output warning and error message-VV Print client request and return information   ps-ef|grep memcached (command description)   grep: Function Description: Find a string in the file that matches the criteria. |: Pipe command operator PS (pro Cess status): Function Description: Report the status of the program.   Another example: Start/End memcached-d-M 10-u root-l 192.168.0.122-p 11200-c 256-p/tmp/memcached.pid-d option is to start a daemon,-m Is the amount of memory allocated to Memcache, in megabytes, where 10mb-u is the user running memcache, where root-l is the server IP address of the listener, and if there are multiple addresses, the IP address of the server is specified 192.168.0.122-p is set Memcache listening port, here set 12000, preferably more than 1024 port-C option is the maximum number of concurrent connections, the default is 1024, here set 256, according to the load of your server set-P is set to save memcache PID file Kill ' Cat/tmp/memcached.pid '----------------------------------------------Connect to memcached:telnet IP ports, such as Telnet 192.168.100.11 11211 stats View status, Flush_all: Clear Cache To view the basic commands for the memcached status, you can see the following information in this command: STAT pid 22459                     &N Bsp       Process ID STAT uptime 1027046                         Server run seconds STAT time 1273043062                       Server current Unix Timestamp stat version 1.4.4                         Server version stat Poin Ter_size                       operating system word size (this server is 64-bit) STAT Rusage_u Ser 0.040000                   Process Cumulative user Time STAT Rusage_system 0.260000   &NB Sp             Process cumulative system time STAT curr_connections             &NBSP ;     Current open connections STAT totAl_connections                   The total number of connections that have been opened STAT Connection_structures &NB Sp             server-assigned connection structure STAT cmd_get  ,             &NBS P             Execute get command total STAT cmd_set,                             Execute SET command count STAT Cmd_flush 3             &NBS P           point to Flush_all total number of commands STAT get_hits 9                          get hit count STAT get_misses               &NBS P       Get misses STAT delete_misses 5                   nbsp   Delete misses STAT delete_hits 1                         DeletE hit count STAT incr_misses 0                         INCR misses STA T incr_hits 0                           INCR number of hits STAT Dec R_misses 0                         DECR number of misses STAT decr_hits 0                           DECR hit count STAT cas_misses 0 &nbs P                        cas number of misses STAT cas_hits 0                            cas hit count STAT cas_badval 0                           Use wipe count stat Auth_cmds 0 Stat auth_errors 0 ST At Bytes_read 15785                       Read Bytes total STAT bytes_written 15222     &nbsp             Write bytes total STAT limit_maxbytes 1048576           &NB Sp   Allocated memory (bytes) STAT Accepting_conns 1                     Current number of links received STA T Listen_disabled_num 0                 STAT Threads 4                             Number of threads stat conn_yields 0 Stat bytes 0     & nbsp                         Store Item bytes STAT curr_items 0   &NB Sp                      item number STAT total_items     &NBSP ;                  item Total STAT evictions 0           & nbsp               to get the total amount of space deleted item    get running status echo stats | NC 192.168.1.123 11200 Watch "Echo stats | NC 192.168.1.123 11200 "(real-time status)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.