MemCached 安装笔记

安装步骤:

      1. 下载libevent & memcached 源码包

     分别把memcached和libevent下载回来,放到 /tmp 目录下:

     # cd /tmp
     # wget http://memcached.org/files/memcached-1.4.20.tar.gz

     # wget https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz

      2.安装libevent

      # tar zxvf libevent-2.0.21-stable.tar.gz

      # cd libevent-2.0.21-stable

      # ./configure -prefix=/usr

      # make

      #make install

       如果提示make command not found 请先安装,命令是

       #yum -y install gcc automake autoconf libtool make

       3.测试libevent是否安装成功:
       # ls -al /usr/lib | grep libevent

      4.安装memcached,同时需要安装中指定libevent的安装位置:
      # cd /tmp
      # tar zxvf memcached-1.2.0.tar.gz
      # cd memcached-1.2.0
      # ./configure -with-libevent=/usr
      # make
      # make install

 

      5.测试是否成功安装memcached:

      # ls -al /usr/local/bin/mem

      6启动memcached

      # /usr/local/bin/memcached -p 11211 -m 512m -d -u root

    

    原文作者:memcached
    原文地址: https://www.cnblogs.com/rosanshao/p/3781883.html
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞