Liunx 操作redis

1,到Liunx的redis的安装目录下/home/redis/redis-7.2.3/src 执行命令

powershell 复制代码
./redis-cli

2,执行命令后,出现以下

powershell 复制代码
127.0.0.1:6379>

3,输入密码

powershell 复制代码
127.0.0.1:6379> AUTH 你的密码

4,切换db库

powershell 复制代码
127.0.0.1:6379> SELECT 5

5,操作命令

查看当前 db库的缓存

powershell 复制代码
127.0.0.1:6379[5]> keys *

6,获取key的值

powershell 复制代码
127.0.0.1:6379[5]>GET 你的KEY

6,删除key的值

powershell 复制代码
127.0.0.1:6379[5]>del 你的KEY
相关推荐
用户095367515838 小时前
在系统的学习 redis 前的疑惑
redis·go
吴声子夜歌11 小时前
Redis 3.x——集群故障转移
java·数据库·redis·集群
明豆12 小时前
Redis 分布式缓存生产实战
redis·分布式·缓存
海兰13 小时前
【高速缓存】RedisVL 指南:从向量搜索到 AI 应用落地
人工智能·redis
weixin_7275356213 小时前
双Token认证体系深度拆解:Spring Security + JWT + Redis
redis·spring·wpf
William Dawson14 小时前
【华为云 MRS Redis 安全集群 Kerberos 认证接入实战(Spring Boot \+ Jedis)】
redis·安全·华为云
zhouhui00115 小时前
AI帮我写了个Spring Boot校验,线上漏掉了这组边界条件
java·spring boot·redis·ai编程
吃饱了得干活15 小时前
扫码登录如何实现?从原理到实战
java·spring boot·redis
熊猫钓鱼>_>1 天前
Redis 突发缓存穿透:一次完整的定位复盘
数据库·人工智能·redis·缓存·ai·agent·智能
Ethan01071 天前
redis 热key问题如何解决+场景
redis