Compile and install memcached under Linux

Source: Internet
Author: User
Tags memcached

First, install the relevant library files required by the system before compiling the installation.

#yum-y install gcc gcc-c++ make cmake libtool autoconf Libaio


Two. Download the corresponding dependent library and memcached source package

1. Download the stable version of Libevent from http://libevent.org/


#wget https://github.com/libevent/libevent/releases/download/release-2.1.8-stable/libevent-2.1.8-stable.tar.gz

#wget http://www.memcached.org/files/memcached-1.5.0.tar.gz


2. Compile and install Libevent

#tar-ZXVF libevent-2.1.8-stable.tar.gz

#cd libevent-2.1.8-stable

#./configure--prefix=/usr/local/libevent

#make && make Install


Note: In the virtual machine under the practice of compiling, an easy-to-encounter problem, the virtual machine time is not right, resulting in the GCC compilation process detection time is not correct, has been in the process of compiling.

The workaround:

#date-S "Yyyy-mm-dd h:i:s"

#clock-W #把时间写入cmos


3. Compile and install Memcache

#tar-ZXVF memcached-1.5.0.tar.gz

#cd memcached-1.5.0

#./configure--prefix=/usr/local/memcached--with-libevent=/usr/local/libevent/#指定libevent的安装目录

#make && make Install


4. Start memched

#cd/usr/local/memcached/bin

#./memcached-m 64-p 11211-u nobody-d


This article is from the "Marks" blog, make sure to keep this source http://2477785.blog.51cto.com/2467785/1954329

Compile and 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.