安装RedisBloom
温馨提示:本文中涉及到的路径为redis的安装目录和配置文件路径,在Redis安装步骤一文中有详细教程。
-
下载 wget https://github.com/RedisBloom/RedisBloom/archive/refs/heads/2.2.zip
-
安装unzip yum install unzip zip
-
解压 unzip 2.2.zip
-
编译 cd RedisBloom-2.2/
make
-
移动到操作系统中redis目录 cp redisbloom.so /opt/soft/redis/
-
停止Redis service redis_6379 stop
-
用redis-server启动挂载RedisBloom库
-
再次进入Redis命令行时就会多出布隆过滤器相关命令了 127.0.0.1:6379> help BF.EXISTS
BF.EXISTS key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.LOADCHUNK
BF.LOADCHUNK key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.RESERVE
BF.RESERVE key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.INFO
BF.INFO key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.DEBUG
BF.DEBUG key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.ADD
BF.ADD key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.MEXISTS
BF.MEXISTS key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.INSERT
BF.INSERT key ...options...
summary: Help not available
since: not known
group: generic
127.0.0.1:6379> help BF.MADD
BF.MADD key ...options...
summary: Help not available
since: not known
group: generic
|