Redis 笔记太散?用 Drawnix 串起复习主线
tags: [知识整理, Drawnix, Redis]
Redis 笔记太散?用 Drawnix 串起复习主线
读过事件循环、持久化、复制和分片,复习时却只记得零散术语?把四篇笔记收拢到一张可编辑的 Drawnix 导图,先定位问题,再回原文查证。
一张图找回四条主线
下面整理自公开的《Redis 架构图解》,每条分支用一个问题串起三个关键判断。适合已有基础、希望建立复习索引的读者。
{"children":[{"id":"a9841cbd-c17f-40fe-a1e1-6eacc0816840","type":"mind","data":{"topic":{"type":"paragraph","children":[{"text":"Redis 复习主线"}]}},"children":[{"id":"391c08a9-d329-42c0-b202-2b5ffd8efcb5","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"命令如何执行"}]}},"children":[{"id":"2e8bb0e5-953d-457f-b22c-310387a07e11","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"RESP 解析请求"}]}},"children":[]},{"id":"1807121a-3128-4273-a188-30021dbcbc39","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"命令分发访问键空间"}]}},"children":[]},{"id":"d6b71718-9e94-4b75-96cd-592c0344542d","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"慢命令占住执行路径"}]}},"children":[]}]},{"id":"0910cb64-3c4e-4179-969e-8fd2c8ac5a4d","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"数据如何落盘"}]}},"children":[{"id":"322e57cd-7819-4181-97e5-7b31ed218a68","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"RDB 保存时点快照"}]}},"children":[]},{"id":"ba668cf5-d57c-4488-9fdd-85398c545ef0","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"AOF 记录写入效果"}]}},"children":[]},{"id":"01c2761d-eed1-47ec-aeb1-e3343853f1a4","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"写入文件不等于 fsync"}]}},"children":[]}]},{"id":"acfb1dc2-ee73-460c-91e0-8a921306147b","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"副本如何追赶"}]}},"children":[{"id":"9b35b309-422a-4fe6-9696-38b96322d0e2","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"PSYNC 携带复制 ID 与 offset"}]}},"children":[]},{"id":"18b3afc8-8a90-421d-8eac-14df749d9627","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"backlog 足够时增量续传"}]}},"children":[]},{"id":"33fca1f4-8bdb-4e08-ab17-055c571f4a75","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"历史不足时全量同步"}]}},"children":[]}]},{"id":"0ffa6bbd-2777-4bb4-8aed-96044fe1981f","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"请求如何分片"}]}},"children":[{"id":"d68dda02-3818-4189-879d-e7f99bf25e73","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"键映射到 16384 个槽"}]}},"children":[]},{"id":"e2212252-481a-4e84-a699-bff040a082b1","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"MOVED 更新长期路由"}]}},"children":[]},{"id":"2dd26c8b-8997-404a-a5b5-8922595dd9cc","type":"mind_child","data":{"topic":{"type":"paragraph","children":[{"text":"ASK 只做临时重定向"}]}},"children":[]}]}],"layout":"right","points":[[0,0]]}],"viewport":{"zoom":1,"origination":[0,0]}}
怎么用这张图复习
- 先答问题,再看细节。 遮住子节点,依次讲清命令执行、持久化、复制和分片;讲不清的分支就是下一次复习入口。
- 带着误区回原文。 “Redis 是单线程”“写完 AOF 就不会丢”“副本重连一定全量复制”都过于简化。命令执行路径之外还有网络 I/O 和后台任务;持久化要区分写文件与 fsync;复制能否续传取决于复制 ID 与 backlog 范围。
- 让结构跟着理解调整。 在可编辑页面中打开 Drawnix,选中节点后添加子节点或同级节点,把自己的疑问放到对应分支,修改后保存。公开阅读页用于查看;在自己的笔记中使用可编辑副本继续整理。
这张图是复习索引,分支表示知识分类,不表示执行时序。它不覆盖 Redis 全部能力,也不能代替故障诊断或参数选型。
按问题回到原文
内容依据:上述既有知识库的四篇链路笔记,版本基线为 Redis Open Source 8.10.3(原文核实日期 2026-11-12);本页于 2026-11-14 提炼为复习索引。进一步核对可读 Redis 持久化说明、复制说明 与 Cluster 规范。