redis安装中的报错

报错1

ps:提示上图报错说明缺少gcc gcc-c++ libstdc++-devel

解决方法:

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

报错2


PS:查看README.md这样一段

Allocator

---------

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

Redis是根据libc编译和链接的默认情况下是malloc,但是jemalloc是Linux上的默认值系统。选择此默认值是因为jemalloc的比libc malloc更容易出现碎片问题。我们需要强制编译libc malloc

[root@redis redis-5.0.8]# make MALLOC=libc

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。