【发布时间】:2016-01-19 11:21:38
【问题描述】:
我有我的innodb_buffer_pool_size =1G
innodb_old_blocks_time = 5000
innodb_old_blocks_pct = 37
innodb 引擎的初始状态
BUFFER POOL AND MEMORY
Total memory allocated 1098907648; in additional pool allocated 0
Dictionary memory allocated 58256
Buffer pool size 65536
Free buffers 64932
Database pages 603
Old database pages 242
Modified db pages 0
Pending reads 0
Pending writes: LRU 0, flush list 0, single page 0
Pages made young 0, not young 0
0.00 youngs/s, 0.00 non-youngs/s
Pages read 603, created 0, written 2
6.00 reads/s, 0.00 creates/s, 0.50 writes/s
Buffer pool hit rate 995 / 1000, young-making rate 0 / 1000 not 0 / 1000
Pages read ahead 0.00/s, evicted without access 0.00/s, Random read ahead 0.00/s
LRU len: 603, unzip_LRU len: 0
I/O sum[0]:cur[0], unzip sum[0]:cur[0]
之后
select count(*) from tenMillion;
BUFFER POOL AND MEMORY
Total memory allocated 1098907648; in additional pool allocated 0
Dictionary memory allocated 404498
Buffer pool size 65536
Free buffers 873
Database pages 64660
Old database pages 23888
Modified db pages 3
Pending reads 0
Pending writes: LRU 0, flush list 0, single page 0
Pages made young 0, not young 0
0.00 youngs/s, 0.00 non-youngs/s
Pages read 64660, created 0, written 20
1085.69 reads/s, 0.00 creates/s, 0.31 writes/s
Buffer pool hit rate 955 / 1000, young-making rate 0 / 1000 not 0 / 1000
Pages read ahead 1081.34/s, evicted without access 0.00/s, Random read ahead 0.00/s
LRU len: 64660, unzip_LRU len: 0
I/O sum[0]:cur[0], unzip sum[0]:cur[0]
这是正确的行为..? 因为我希望它只占用 37% 的数据库页面,因为整个缓存应该在旧块中
当我的 innodb _old_blocks_time 为 5000 毫秒并且表大小超过 37(我的 innodb_old_blocks_pct)百分比时,如何最初填充 innodb 空闲缓冲区(重新启动服务器后)被填满,或者因为没有年轻人,也不需要驱逐,所以如果它被填满超过我的 innodb 缓冲池的 37%?
请解释
【问题讨论】:
-
如果您还用文字解释实际行为是什么以及从您发布的输出中可以看到的位置会更好
-
输出来自mysql 5.5
-
您写的只是预期的 37%。但是我在哪里看到它占用更多?它实际上是多少?
-
在show engine innodb status的输出中;数据库页面最初在查询后大约 65000 个,它的 jst 700 什么是我所期望的是它最初应该只占用 37% 的空闲缓冲区