前言
最近需要在一台新机器上安装部署redis,遇到了几个问题,这里记录下。
cc:命令未找到
原因是没有安装gcc,使用命令:yum install gcc -y
zmalloc.h:50:31: fatal error: jemalloc/jemalloc.h: No such file or directory
make的时候,加入参数:MALLOC=libc
Selecting a non-default memory allocator when building Redis is done by setting
the MALLOC environment variable. Redis is compiled and linked against libc
malloc by default, with the exception of jemalloc being the default on Linux
systems. This default was picked because jemalloc has proven to have fewer
fragmentation problems than libc malloc.
To force compiling against libc malloc, use:
% make MALLOC=libc
To compile against jemalloc on Mac OS X systems, use:
% make MALLOC=jemalloc


评 说
正在取来评说……