日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Cent OS 7安装redis

發布時間:2023/12/14 编程问答 22 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Cent OS 7安装redis 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

在Cent OS 7安裝redis時

1、出現錯誤:make[3]: 進入目錄“/usr/enc/redis-4.0.6/deps/hiredis”

gcc -std=c99 -pedantic -c -O3 -fPIC? -Wall -W -Wstrict-prototypes -Wwrite-strings -g -ggdb? net.c
make[3]: gcc:命令未找到

原因是gcc未安裝

執行命令:yum install gcc?

???yum install gcc-c++



2、出現錯誤:make[1]: 進入目錄“/usr/enc/redis-4.0.6/src”
? ? CC adlist.o
In file included from adlist.c:34:0:
zmalloc.h:50:31: 致命錯誤:jemalloc/jemalloc.h:沒有那個文件或目錄
?#include <jemalloc/jemalloc.h>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?^
編譯中斷。

執行命令:make MALLOC=libc

3:$make test出現問題:

cd src && make test
make[1]: 進入目錄“/usr/enc/redis-4.0.6/src”
? ? CC Makefile.dep
make[1]: 離開目錄“/usr/enc/redis-4.0.6/src”
make[1]: 進入目錄“/usr/enc/redis-4.0.6/src”
You need tcl 8.5 or newer in order to run the Redis test
make[1]: *** [test] 錯誤 1
make[1]: 離開目錄“/usr/enc/redis-4.0.6/src”
make: *** [test] 錯誤 2

解決:wget http://downloads.sourceforge.net/tcl/tcl8.6.1-src.tar.gz

sudo tar xzvf tcl8.6.1-src.tar.gz -C /usr/local/

cd /usr/local/tcl8.6.1/unix/

sudo ./configure

sudo make sudo make install


4、權限問題

出現錯誤:

Can't open the log file: Is a directory

如:[root@10-19-147-112 bin]# ls -l /usr/enc/redis-4.0.6/log/redis.log
-rw-r--r--. 1 root root 0 2月? ?2 18:52 /usr/enc/redis-4.0.6/log/redis.log

執行命令:chmod 777 /usr/enc/redis-4.0.6/log/redis.log

結果變成:-rwxrwxrwx. 1 root root 0 2月? ?2 18:52 /usr/enc/redis-4.0.6/log/redis.log


5、查看redis是否啟動

ps -ef | grep redis







總結

以上是生活随笔為你收集整理的Cent OS 7安装redis的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。