安裝redis 及常見問題

來源:互聯網
上載者:User

### Install ####

yum -y install gcc gcc-c++ libstdc++-devel

sudo yum install tcl

tar xzf  redis-2.8.8.tar.gz

cd redis-2.8.8.tar.gz

make MALLOC=libc

make test

Q: cc: command not found

yum -y install gcc gcc-c++ libstdc++-devel


Q: 安裝redis 報錯

#make
cd src && make all
make[1]: Entering directory `/software/redis-2.8.8/src'
    CC adlist.o
In file included from adlist.c:34:
zmalloc.h:50:31: error: jemalloc/jemalloc.h: No such file or directory
zmalloc.h:55:2: error: #error "Newer version of jemalloc required"
make[1]: *** [adlist.o] Error 1
make[1]: Leaving directory `/software/redis-2.8.8/src'
make: *** [all] Error 2

A:

make MALLOC=libc (不知道為什麼這麼用。)


References:

http://www.klfy.net/linux-centos64-redis26-error.shtml

http://www.cnblogs.com/la-isla-bonita/p/3582751.html


Q:

# make test
cd src && make test
make[1]: Entering directory `/software/redis-2.8.8/src'
You need tcl 8.5 or newer in order to run the Redis test
make[1]: *** [test] Error 1
make[1]: Leaving directory `/software/redis-2.8.8/src'
make: *** [test] Error 2

A.修改設定檔目錄

mkdir /etc/redis
cp redis.conf /etc/redis


A: 啟動redis

redis-server /etc/redis/redis.conf


A.寫入開機自啟動 echo "redis-server /etc/redis/redis.conf" >>/etc/rc.local


相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.