Install memcached under Linux

Source: Internet
Author: User

Prerequisite Preparation:


1. Memcached is currently the latest version: 1.4.22, can be downloaded from the official website.


2. memcached relies on libevent, so you need to install libevent before installing memcached.


2.1 Run the following command to see if the system has libevent installed.


[Email protected] ~]# Rpm-qa|grep libeventlibevent-headers-1.4.13-4.el6.noarchlibevent-1.4.13-4.el6.x86_ 64libevent-doc-1.4.13-4.el6.noarchlibevent-devel-1.4.13-4.el6.x86_64


Installation process:

3. Upload the downloaded file to/opt/favccxx and run the following command to unzip it.


[Email protected] favccxx]# TAR-ZXVF memcached-1.4.22.tar.gz


4. Run [[email protected]ck favccxx]# cd memcached-1.4.22 and switch to the memcached directory.


5. Run [[email protected] memcached-1.4.22]# ./configure && make && make test &am p;& sudo make install , one click to complete the installation.


6. Running[email protected]bin]# ./memcached-u Root,start memcached. memcached Default boot port is: 11211. You can also pass[[email protected]bin]# ./memcached-p 12306-u Root , change the default port number to start. If you want the memcache process to still run when the window is closed, you need to add-D to the command to indicate that it starts with the daemon.


7. memcached commands can be viewed by [[email protected] bin]# ./memcached-h . Here are some common commands.


-D: Start a daemon,-M: The amount of memory allocated to Memcache, in megabytes, by default 64mb,-u: The user running Memcache-L: The server IP address of the listener-P: Set the port for Memcache listening, default is 11211 Note:-P (p is lowercase)-C: Sets the maximum number of concurrent connections, default is 1024


8. At this point, memcached installation is complete, then you can experience memcached.

This article is from the "This person's IT World" blog, be sure to keep this source http://favccxx.blog.51cto.com/2890523/1626776

Install memcached under Linux

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.