Innodb 表空间结构
页类型
- 数据页(B-tree Node)
- undo页(undo Log Page)
- 系统页(System Page)
- 事务数据页(Transaction system Page)
- 插入缓冲位图页(Insert Buffer Page)
- 未压缩的二进制大对象页(Uncompressd BLOB Page)
- 压缩的二进制大对象页(compressd BLOB Page)
页大小
默认16k(若果没有特殊情况,下面介绍的都是默认16k大小为准) 一个页内必须存储2行记录,否则就不是B+tree,而是链表了
page 结构
问题: Row 在上面这张图上为什么长短不一?
row 文件格式
- COMPACT(紧凑的) & REDUNDANT(冗余;过剩的;过多的)
存row里面存一部分(first 768 bytes),多余的存到overflow pages.
- DYNAMIC(动态的) and COMPRESSED(压缩的)
全部存到溢出页中
- Compact row format
overflow pages 溢出页
- 溢出页里面的数据如何存储?
singly-linked lists